From 13af413a2239179a334fe95286328ef32a8fc55a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 May 2024 06:20:17 +0000 Subject: [PATCH] Bump google.golang.org/api from 0.176.1 to 0.177.0 (#3028) * Bump google.golang.org/api from 0.176.1 to 0.177.0 Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client) from 0.176.1 to 0.177.0. - [Release notes](https://github.com/googleapis/google-api-go-client/releases) - [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md) - [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.176.1...v0.177.0) --- updated-dependencies: - dependency-name: google.golang.org/api dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * Run ./hack/update-codegen.sh --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- go.mod | 8 +- go.sum | 16 +- .../go/internal/.repo-metadata-full.json | 62 +- .../api/container/v1beta1/container-api.json | 16 +- .../api/container/v1beta1/container-gen.go | 15615 +++++----------- .../iamcredentials/v1/iamcredentials-gen.go | 687 +- .../api/internal/gensupport/params.go | 16 + .../google.golang.org/api/internal/version.go | 2 +- .../api/storage/v1/storage-gen.go | 11026 +++-------- .../protobuf/encoding/protojson/encode.go | 20 +- .../protobuf/encoding/prototext/encode.go | 20 +- .../protobuf/internal/descfmt/stringer.go | 1 + .../editiondefaults/editions_defaults.binpb | Bin 63 -> 78 bytes .../internal/editionssupport/editions.go | 13 + .../protobuf/internal/encoding/tag/tag.go | 4 +- .../protobuf/internal/errors/errors.go | 15 + .../protobuf/internal/filedesc/desc.go | 84 +- .../protobuf/internal/filedesc/desc_init.go | 41 +- .../protobuf/internal/filedesc/desc_lazy.go | 44 +- .../protobuf/internal/filedesc/editions.go | 18 +- .../protobuf/internal/filedesc/placeholder.go | 1 + .../internal/genid/go_features_gen.go | 2 +- .../protobuf/internal/impl/codec_field.go | 64 +- .../protobuf/internal/impl/codec_map.go | 15 +- .../protobuf/internal/impl/legacy_enum.go | 1 + .../internal/impl/legacy_extension.go | 2 +- .../protobuf/internal/impl/legacy_file.go | 4 +- .../protobuf/internal/impl/legacy_message.go | 10 +- .../protobuf/internal/impl/message_reflect.go | 31 +- .../internal/impl/message_reflect_gen.go | 142 +- .../protobuf/internal/version/version.go | 2 +- .../protobuf/proto/decode.go | 2 + .../protobuf/proto/encode.go | 44 +- .../protobuf/proto/extension.go | 11 +- .../protobuf/proto/messageset.go | 7 +- .../google.golang.org/protobuf/proto/size.go | 2 + .../protobuf/reflect/protodesc/desc.go | 13 +- .../protobuf/reflect/protodesc/desc_init.go | 49 +- .../reflect/protodesc/desc_validate.go | 61 +- .../protobuf/reflect/protodesc/editions.go | 5 - .../protobuf/reflect/protodesc/proto.go | 22 + .../protobuf/reflect/protoreflect/proto.go | 2 +- .../protobuf/reflect/protoreflect/type.go | 6 + .../types/gofeaturespb/go_features.pb.go | 116 +- .../types/gofeaturespb/go_features.proto | 28 - vendor/modules.txt | 9 +- 46 files changed, 8672 insertions(+), 19687 deletions(-) create mode 100644 vendor/google.golang.org/protobuf/internal/editionssupport/editions.go delete mode 100644 vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.proto diff --git a/go.mod b/go.mod index c9dcd8a417..a2264573b2 100644 --- a/go.mod +++ b/go.mod @@ -36,9 +36,9 @@ require ( golang.org/x/sync v0.7.0 golang.org/x/tools v0.20.0 gomodules.xyz/jsonpatch/v2 v2.4.0 - google.golang.org/api v0.176.1 + google.golang.org/api v0.177.0 google.golang.org/grpc v1.63.2 - google.golang.org/protobuf v1.33.0 + google.golang.org/protobuf v1.34.0 gopkg.in/yaml.v3 v3.0.1 k8s.io/api v0.29.2 k8s.io/apiextensions-apiserver v0.29.2 @@ -53,7 +53,7 @@ require ( ) require ( - cloud.google.com/go v0.112.1 // indirect + cloud.google.com/go v0.112.2 // indirect cloud.google.com/go/auth v0.3.0 // indirect cloud.google.com/go/auth/oauth2adapt v0.2.2 // indirect cloud.google.com/go/iam v1.1.7 // indirect @@ -105,7 +105,7 @@ require ( golang.org/x/time v0.5.0 // indirect google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de // indirect google.golang.org/genproto/googleapis/api v0.0.0-20240314234333-6e1732d8331c // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240415180920-8c6c420018be // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240429193739-8cf5692501f6 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect k8s.io/kube-openapi v0.0.0-20231010175941-2dd684a91f00 // indirect diff --git a/go.sum b/go.sum index 07653bfea9..d176aaa49f 100644 --- a/go.sum +++ b/go.sum @@ -13,8 +13,8 @@ cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKV cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs= cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOYc= cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY= -cloud.google.com/go v0.112.1 h1:uJSeirPke5UNZHIb4SxfZklVSiWWVqW4oXlETwZziwM= -cloud.google.com/go v0.112.1/go.mod h1:+Vbu+Y1UU+I1rjmzeMOb/8RfkKJK2Gyxi1X6jJCZLo4= +cloud.google.com/go v0.112.2 h1:ZaGT6LiG7dBzi6zNOvVZwacaXlmf3lRqnC4DQzqyRQw= +cloud.google.com/go v0.112.2/go.mod h1:iEqjp//KquGIJV/m+Pk3xecgKNhV+ry+vVTsy4TbDms= cloud.google.com/go/auth v0.3.0 h1:PRyzEpGfx/Z9e8+lHsbkoUVXD0gnu4MNmm7Gp8TQNIs= cloud.google.com/go/auth v0.3.0/go.mod h1:lBv6NKTWp8E3LPzmO1TbiiRKc4drLOfHsgmlH9ogv5w= cloud.google.com/go/auth/oauth2adapt v0.2.2 h1:+TTV8aXpjeChS9M+aTtN/TjdQnzJvmzKFt//oWu7HX4= @@ -650,8 +650,8 @@ google.golang.org/api v0.25.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0M google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM= google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc= -google.golang.org/api v0.176.1 h1:DJSXnV6An+NhJ1J+GWtoF2nHEuqB1VNoTfnIbjNvwD4= -google.golang.org/api v0.176.1/go.mod h1:j2MaSDYcvYV1lkZ1+SMW4IeF90SrEyFA+tluDYWRrFg= +google.golang.org/api v0.177.0 h1:8a0p/BbPa65GlqGWtUKxot4p0TV8OGOfyTjtmkXNXmk= +google.golang.org/api v0.177.0/go.mod h1:srbhue4MLjkjbkux5p3dw/ocYOSZTaIEvf7bCOnFQDw= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -693,8 +693,8 @@ google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de h1:F6qOa9AZTYJXOUE google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:VUhTRKeHn9wwcdrk73nvdC9gF178Tzhmt/qyaFcPLSo= google.golang.org/genproto/googleapis/api v0.0.0-20240314234333-6e1732d8331c h1:kaI7oewGK5YnVwj+Y+EJBO/YN1ht8iTL9XkFHtVZLsc= google.golang.org/genproto/googleapis/api v0.0.0-20240314234333-6e1732d8331c/go.mod h1:VQW3tUculP/D4B+xVCo+VgSq8As6wA9ZjHl//pmk+6s= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240415180920-8c6c420018be h1:LG9vZxsWGOmUKieR8wPAUR3u3MpnYFQZROPIMaXh7/A= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240415180920-8c6c420018be/go.mod h1:WtryC6hu0hhx87FDGxWCDptyssuo68sk10vYjF+T9fY= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240429193739-8cf5692501f6 h1:DujSIu+2tC9Ht0aPNA7jgj23Iq8Ewi5sgkQ++wdvonE= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240429193739-8cf5692501f6/go.mod h1:WtryC6hu0hhx87FDGxWCDptyssuo68sk10vYjF+T9fY= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= @@ -725,8 +725,8 @@ google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp0 google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= -google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +google.golang.org/protobuf v1.34.0 h1:Qo/qEd2RZPCf2nKuorzksSknv0d3ERwp1vFG38gSmH4= +google.golang.org/protobuf v1.34.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= diff --git a/vendor/cloud.google.com/go/internal/.repo-metadata-full.json b/vendor/cloud.google.com/go/internal/.repo-metadata-full.json index c9a57ccddb..9905b164f2 100644 --- a/vendor/cloud.google.com/go/internal/.repo-metadata-full.json +++ b/vendor/cloud.google.com/go/internal/.repo-metadata-full.json @@ -199,6 +199,16 @@ "release_level": "stable", "library_type": "GAPIC_AUTO" }, + "cloud.google.com/go/apphub/apiv1": { + "api_shortname": "apphub", + "distribution_name": "cloud.google.com/go/apphub/apiv1", + "description": "App Hub API", + "language": "go", + "client_library_type": "generated", + "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/apphub/latest/apiv1", + "release_level": "preview", + "library_type": "GAPIC_AUTO" + }, "cloud.google.com/go/apps/events/subscriptions/apiv1": { "api_shortname": "workspaceevents", "distribution_name": "cloud.google.com/go/apps/events/subscriptions/apiv1", @@ -659,6 +669,26 @@ "release_level": "stable", "library_type": "GAPIC_AUTO" }, + "cloud.google.com/go/cloudcontrolspartner/apiv1": { + "api_shortname": "cloudcontrolspartner", + "distribution_name": "cloud.google.com/go/cloudcontrolspartner/apiv1", + "description": "Cloud Controls Partner API", + "language": "go", + "client_library_type": "generated", + "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/cloudcontrolspartner/latest/apiv1", + "release_level": "preview", + "library_type": "GAPIC_AUTO" + }, + "cloud.google.com/go/cloudcontrolspartner/apiv1beta": { + "api_shortname": "cloudcontrolspartner", + "distribution_name": "cloud.google.com/go/cloudcontrolspartner/apiv1beta", + "description": "Cloud Controls Partner API", + "language": "go", + "client_library_type": "generated", + "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/cloudcontrolspartner/latest/apiv1beta", + "release_level": "preview", + "library_type": "GAPIC_AUTO" + }, "cloud.google.com/go/clouddms/apiv1": { "api_shortname": "datamigration", "distribution_name": "cloud.google.com/go/clouddms/apiv1", @@ -1052,7 +1082,7 @@ "cloud.google.com/go/dlp/apiv2": { "api_shortname": "dlp", "distribution_name": "cloud.google.com/go/dlp/apiv2", - "description": "Cloud Data Loss Prevention (DLP)", + "description": "Sensitive Data Protection (DLP)", "language": "go", "client_library_type": "generated", "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/dlp/latest/apiv2", @@ -2109,6 +2139,16 @@ "release_level": "stable", "library_type": "GAPIC_AUTO" }, + "cloud.google.com/go/secretmanager/apiv1beta2": { + "api_shortname": "secretmanager", + "distribution_name": "cloud.google.com/go/secretmanager/apiv1beta2", + "description": "Secret Manager API", + "language": "go", + "client_library_type": "generated", + "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/secretmanager/latest/apiv1beta2", + "release_level": "preview", + "library_type": "GAPIC_AUTO" + }, "cloud.google.com/go/securesourcemanager/apiv1": { "api_shortname": "securesourcemanager", "distribution_name": "cloud.google.com/go/securesourcemanager/apiv1", @@ -2169,6 +2209,16 @@ "release_level": "preview", "library_type": "GAPIC_AUTO" }, + "cloud.google.com/go/securitycenter/apiv2": { + "api_shortname": "securitycenter", + "distribution_name": "cloud.google.com/go/securitycenter/apiv2", + "description": "Security Command Center API", + "language": "go", + "client_library_type": "generated", + "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/securitycenter/latest/apiv2", + "release_level": "preview", + "library_type": "GAPIC_AUTO" + }, "cloud.google.com/go/securitycenter/settings/apiv1beta1": { "api_shortname": "securitycenter", "distribution_name": "cloud.google.com/go/securitycenter/settings/apiv1beta1", @@ -2379,6 +2429,16 @@ "release_level": "stable", "library_type": "GAPIC_MANUAL" }, + "cloud.google.com/go/storage/control/apiv2": { + "api_shortname": "storage", + "distribution_name": "cloud.google.com/go/storage/control/apiv2", + "description": "Cloud Storage API", + "language": "go", + "client_library_type": "generated", + "client_documentation": "https://cloud.google.com/go/docs/reference/cloud.google.com/go/storage/latest/control/apiv2", + "release_level": "preview", + "library_type": "GAPIC_AUTO" + }, "cloud.google.com/go/storage/internal/apiv2": { "api_shortname": "storage", "distribution_name": "cloud.google.com/go/storage/internal/apiv2", diff --git a/vendor/google.golang.org/api/container/v1beta1/container-api.json b/vendor/google.golang.org/api/container/v1beta1/container-api.json index c17f4fdb6a..868abb5360 100644 --- a/vendor/google.golang.org/api/container/v1beta1/container-api.json +++ b/vendor/google.golang.org/api/container/v1beta1/container-api.json @@ -2565,7 +2565,7 @@ } } }, - "revision": "20240327", + "revision": "20240409", "rootUrl": "https://container.googleapis.com/", "schemas": { "AcceleratorConfig": { @@ -2759,6 +2759,10 @@ "description": "Specifies options for controlling advanced machine features.", "id": "AdvancedMachineFeatures", "properties": { + "enableNestedVirtualization": { + "description": "Whether or not to enable nested virtualization (defaults to false).", + "type": "boolean" + }, "threadsPerCore": { "description": "The number of threads per physical core. To disable simultaneous multithreading (SMT) set this to 1. If unset, the maximum number of threads supported per core by the underlying processor is assumed.", "format": "int64", @@ -3776,7 +3780,7 @@ "type": "string" }, "desiredInTransitEncryptionConfig": { - "description": "Specify the details of in-transit encryption.", + "description": "Specify the details of in-transit encryption. Now named inter-node transparent encryption.", "enum": [ "IN_TRANSIT_ENCRYPTION_CONFIG_UNSPECIFIED", "IN_TRANSIT_ENCRYPTION_DISABLED", @@ -6600,7 +6604,7 @@ "id": "PolicyBinding", "properties": { "name": { - "description": "The relative resource name of the binauthz platform policy to audit. GKE platform policies have the following format: `projects/{project_number}/platforms/gke/policies/{policy_id}`.", + "description": "The relative resource name of the binauthz platform policy to evaluate. GKE platform policies have the following format: `projects/{project_number}/platforms/gke/policies/{policy_id}`.", "type": "string" } }, @@ -7093,12 +7097,14 @@ "enum": [ "MODE_UNSPECIFIED", "DISABLED", - "BASIC" + "BASIC", + "ENTERPRISE" ], "enumDescriptions": [ "Default value not specified.", "Disables Security Posture features on the cluster.", - "Applies Security Posture features on the cluster." + "Applies Security Posture features on the cluster.", + "Applies the Security Posture off cluster Enterprise level features." ], "type": "string" }, diff --git a/vendor/google.golang.org/api/container/v1beta1/container-gen.go b/vendor/google.golang.org/api/container/v1beta1/container-gen.go index 4dd19287ce..3f6d36ac02 100644 --- a/vendor/google.golang.org/api/container/v1beta1/container-gen.go +++ b/vendor/google.golang.org/api/container/v1beta1/container-gen.go @@ -96,8 +96,8 @@ const defaultUniverseDomain = "googleapis.com" // OAuth2 scopes used by this API. const ( - // See, edit, configure, and delete your Google Cloud data and see the - // email address for your Google Account. + // See, edit, configure, and delete your Google Cloud data and see the email + // address for your Google Account. CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" ) @@ -296,268 +296,201 @@ type ProjectsZonesOperationsService struct { s *Service } -// AcceleratorConfig: AcceleratorConfig represents a Hardware -// Accelerator request. +// AcceleratorConfig: AcceleratorConfig represents a Hardware Accelerator +// request. type AcceleratorConfig struct { // AcceleratorCount: The number of the accelerator cards exposed to an // instance. AcceleratorCount int64 `json:"acceleratorCount,omitempty,string"` - - // AcceleratorType: The accelerator type resource name. List of - // supported accelerators here - // (https://cloud.google.com/compute/docs/gpus) + // AcceleratorType: The accelerator type resource name. List of supported + // accelerators here (https://cloud.google.com/compute/docs/gpus) AcceleratorType string `json:"acceleratorType,omitempty"` - - // GpuDriverInstallationConfig: The configuration for auto installation - // of GPU driver. + // GpuDriverInstallationConfig: The configuration for auto installation of GPU + // driver. GpuDriverInstallationConfig *GPUDriverInstallationConfig `json:"gpuDriverInstallationConfig,omitempty"` - - // GpuPartitionSize: Size of partitions to create on the GPU. Valid - // values are described in the NVIDIA mig user guide + // GpuPartitionSize: Size of partitions to create on the GPU. Valid values are + // described in the NVIDIA mig user guide // (https://docs.nvidia.com/datacenter/tesla/mig-user-guide/#partitioning). GpuPartitionSize string `json:"gpuPartitionSize,omitempty"` - // GpuSharingConfig: The configuration for GPU sharing options. GpuSharingConfig *GPUSharingConfig `json:"gpuSharingConfig,omitempty"` - - // MaxTimeSharedClientsPerGpu: The number of time-shared GPU resources - // to expose for each physical GPU. + // MaxTimeSharedClientsPerGpu: The number of time-shared GPU resources to + // expose for each physical GPU. MaxTimeSharedClientsPerGpu int64 `json:"maxTimeSharedClientsPerGpu,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "AcceleratorCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AcceleratorCount") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AcceleratorCount") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AcceleratorConfig) MarshalJSON() ([]byte, error) { type NoMethod AcceleratorConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // AdditionalNodeNetworkConfig: AdditionalNodeNetworkConfig is the -// configuration for additional node networks within the -// NodeNetworkConfig message +// configuration for additional node networks within the NodeNetworkConfig +// message type AdditionalNodeNetworkConfig struct { // Network: Name of the VPC where the additional interface belongs Network string `json:"network,omitempty"` - - // Subnetwork: Name of the subnetwork where the additional interface - // belongs + // Subnetwork: Name of the subnetwork where the additional interface belongs Subnetwork string `json:"subnetwork,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Network") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Network") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Network") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Network") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AdditionalNodeNetworkConfig) MarshalJSON() ([]byte, error) { type NoMethod AdditionalNodeNetworkConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AdditionalPodNetworkConfig: AdditionalPodNetworkConfig is the -// configuration for additional pod networks within the -// NodeNetworkConfig message +// AdditionalPodNetworkConfig: AdditionalPodNetworkConfig is the configuration +// for additional pod networks within the NodeNetworkConfig message type AdditionalPodNetworkConfig struct { - // MaxPodsPerNode: The maximum number of pods per node which use this - // pod network + // MaxPodsPerNode: The maximum number of pods per node which use this pod + // network MaxPodsPerNode *MaxPodsConstraint `json:"maxPodsPerNode,omitempty"` - - // SecondaryPodRange: The name of the secondary range on the subnet - // which provides IP address for this pod range + // SecondaryPodRange: The name of the secondary range on the subnet which + // provides IP address for this pod range SecondaryPodRange string `json:"secondaryPodRange,omitempty"` - - // Subnetwork: Name of the subnetwork where the additional pod network - // belongs + // Subnetwork: Name of the subnetwork where the additional pod network belongs Subnetwork string `json:"subnetwork,omitempty"` - // ForceSendFields is a list of field names (e.g. "MaxPodsPerNode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MaxPodsPerNode") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "MaxPodsPerNode") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AdditionalPodNetworkConfig) MarshalJSON() ([]byte, error) { type NoMethod AdditionalPodNetworkConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AdditionalPodRangesConfig: AdditionalPodRangesConfig is the -// configuration for additional pod secondary ranges supporting the -// ClusterUpdate message. +// AdditionalPodRangesConfig: AdditionalPodRangesConfig is the configuration +// for additional pod secondary ranges supporting the ClusterUpdate message. type AdditionalPodRangesConfig struct { - // PodRangeInfo: Output only. [Output only] Information for additional - // pod range. + // PodRangeInfo: Output only. [Output only] Information for additional pod + // range. PodRangeInfo []*RangeInfo `json:"podRangeInfo,omitempty"` - - // PodRangeNames: Name for pod secondary ipv4 range which has the actual - // range defined ahead. + // PodRangeNames: Name for pod secondary ipv4 range which has the actual range + // defined ahead. PodRangeNames []string `json:"podRangeNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "PodRangeInfo") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "PodRangeInfo") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "PodRangeInfo") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AdditionalPodRangesConfig) MarshalJSON() ([]byte, error) { type NoMethod AdditionalPodRangesConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AddonsConfig: Configuration for the addons that can be automatically -// spun up in the cluster, enabling additional functionality. +// AddonsConfig: Configuration for the addons that can be automatically spun up +// in the cluster, enabling additional functionality. type AddonsConfig struct { - // CloudRunConfig: Configuration for the Cloud Run addon. The - // `IstioConfig` addon must be enabled in order to enable Cloud Run - // addon. This option can only be enabled at cluster creation time. + // CloudRunConfig: Configuration for the Cloud Run addon. The `IstioConfig` + // addon must be enabled in order to enable Cloud Run addon. This option can + // only be enabled at cluster creation time. CloudRunConfig *CloudRunConfig `json:"cloudRunConfig,omitempty"` - - // ConfigConnectorConfig: Configuration for the ConfigConnector add-on, - // a Kubernetes extension to manage hosted GCP services through the - // Kubernetes API + // ConfigConnectorConfig: Configuration for the ConfigConnector add-on, a + // Kubernetes extension to manage hosted GCP services through the Kubernetes + // API ConfigConnectorConfig *ConfigConnectorConfig `json:"configConnectorConfig,omitempty"` - - // DnsCacheConfig: Configuration for NodeLocalDNS, a dns cache running - // on cluster nodes + // DnsCacheConfig: Configuration for NodeLocalDNS, a dns cache running on + // cluster nodes DnsCacheConfig *DnsCacheConfig `json:"dnsCacheConfig,omitempty"` - - // GcePersistentDiskCsiDriverConfig: Configuration for the Compute - // Engine Persistent Disk CSI driver. + // GcePersistentDiskCsiDriverConfig: Configuration for the Compute Engine + // Persistent Disk CSI driver. GcePersistentDiskCsiDriverConfig *GcePersistentDiskCsiDriverConfig `json:"gcePersistentDiskCsiDriverConfig,omitempty"` - - // GcpFilestoreCsiDriverConfig: Configuration for the GCP Filestore CSI - // driver. + // GcpFilestoreCsiDriverConfig: Configuration for the GCP Filestore CSI driver. GcpFilestoreCsiDriverConfig *GcpFilestoreCsiDriverConfig `json:"gcpFilestoreCsiDriverConfig,omitempty"` - - // GcsFuseCsiDriverConfig: Configuration for the Cloud Storage Fuse CSI - // driver. + // GcsFuseCsiDriverConfig: Configuration for the Cloud Storage Fuse CSI driver. GcsFuseCsiDriverConfig *GcsFuseCsiDriverConfig `json:"gcsFuseCsiDriverConfig,omitempty"` - - // GkeBackupAgentConfig: Configuration for the Backup for GKE agent - // addon. + // GkeBackupAgentConfig: Configuration for the Backup for GKE agent addon. GkeBackupAgentConfig *GkeBackupAgentConfig `json:"gkeBackupAgentConfig,omitempty"` - - // HorizontalPodAutoscaling: Configuration for the horizontal pod - // autoscaling feature, which increases or decreases the number of - // replica pods a replication controller has based on the resource usage - // of the existing pods. + // HorizontalPodAutoscaling: Configuration for the horizontal pod autoscaling + // feature, which increases or decreases the number of replica pods a + // replication controller has based on the resource usage of the existing pods. HorizontalPodAutoscaling *HorizontalPodAutoscaling `json:"horizontalPodAutoscaling,omitempty"` - - // HttpLoadBalancing: Configuration for the HTTP (L7) load balancing - // controller addon, which makes it easy to set up HTTP load balancers - // for services in a cluster. + // HttpLoadBalancing: Configuration for the HTTP (L7) load balancing controller + // addon, which makes it easy to set up HTTP load balancers for services in a + // cluster. HttpLoadBalancing *HttpLoadBalancing `json:"httpLoadBalancing,omitempty"` - - // IstioConfig: Configuration for Istio, an open platform to connect, - // manage, and secure microservices. + // IstioConfig: Configuration for Istio, an open platform to connect, manage, + // and secure microservices. IstioConfig *IstioConfig `json:"istioConfig,omitempty"` - - // KalmConfig: Configuration for the KALM addon, which manages the - // lifecycle of k8s applications. + // KalmConfig: Configuration for the KALM addon, which manages the lifecycle of + // k8s applications. KalmConfig *KalmConfig `json:"kalmConfig,omitempty"` - - // KubernetesDashboard: Configuration for the Kubernetes Dashboard. This - // addon is deprecated, and will be disabled in 1.15. It is recommended - // to use the Cloud Console to manage and monitor your Kubernetes - // clusters, workloads and applications. For more information, see: + // KubernetesDashboard: Configuration for the Kubernetes Dashboard. This addon + // is deprecated, and will be disabled in 1.15. It is recommended to use the + // Cloud Console to manage and monitor your Kubernetes clusters, workloads and + // applications. For more information, see: // https://cloud.google.com/kubernetes-engine/docs/concepts/dashboards KubernetesDashboard *KubernetesDashboard `json:"kubernetesDashboard,omitempty"` - - // NetworkPolicyConfig: Configuration for NetworkPolicy. This only - // tracks whether the addon is enabled or not on the Master, it does not - // track whether network policy is enabled for the nodes. + // NetworkPolicyConfig: Configuration for NetworkPolicy. This only tracks + // whether the addon is enabled or not on the Master, it does not track whether + // network policy is enabled for the nodes. NetworkPolicyConfig *NetworkPolicyConfig `json:"networkPolicyConfig,omitempty"` - // StatefulHaConfig: Optional. Configuration for the StatefulHA add-on. StatefulHaConfig *StatefulHAConfig `json:"statefulHaConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "CloudRunConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CloudRunConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "CloudRunConfig") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AddonsConfig) MarshalJSON() ([]byte, error) { type NoMethod AddonsConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AdvancedDatapathObservabilityConfig: -// AdvancedDatapathObservabilityConfig specifies configuration of -// observability features of advanced datapath. +// AdvancedDatapathObservabilityConfig: AdvancedDatapathObservabilityConfig +// specifies configuration of observability features of advanced datapath. type AdvancedDatapathObservabilityConfig struct { // EnableMetrics: Expose flow metrics on nodes EnableMetrics bool `json:"enableMetrics,omitempty"` - // EnableRelay: Enable Relay component EnableRelay bool `json:"enableRelay,omitempty"` - // RelayMode: Method used to make Relay available // // Possible values: @@ -566,170 +499,132 @@ type AdvancedDatapathObservabilityConfig struct { // "INTERNAL_VPC_LB" - exposed via internal load balancer // "EXTERNAL_LB" - exposed via external load balancer RelayMode string `json:"relayMode,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnableMetrics") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnableMetrics") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EnableMetrics") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AdvancedDatapathObservabilityConfig) MarshalJSON() ([]byte, error) { type NoMethod AdvancedDatapathObservabilityConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AdvancedMachineFeatures: Specifies options for controlling advanced -// machine features. +// AdvancedMachineFeatures: Specifies options for controlling advanced machine +// features. type AdvancedMachineFeatures struct { + // EnableNestedVirtualization: Whether or not to enable nested virtualization + // (defaults to false). + EnableNestedVirtualization bool `json:"enableNestedVirtualization,omitempty"` // ThreadsPerCore: The number of threads per physical core. To disable - // simultaneous multithreading (SMT) set this to 1. If unset, the - // maximum number of threads supported per core by the underlying - // processor is assumed. + // simultaneous multithreading (SMT) set this to 1. If unset, the maximum + // number of threads supported per core by the underlying processor is assumed. ThreadsPerCore int64 `json:"threadsPerCore,omitempty,string"` - - // ForceSendFields is a list of field names (e.g. "ThreadsPerCore") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "EnableNestedVirtualization") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ThreadsPerCore") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EnableNestedVirtualization") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AdvancedMachineFeatures) MarshalJSON() ([]byte, error) { type NoMethod AdvancedMachineFeatures - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AuthenticatorGroupsConfig: Configuration for returning group -// information from authenticators. +// AuthenticatorGroupsConfig: Configuration for returning group information +// from authenticators. type AuthenticatorGroupsConfig struct { - // Enabled: Whether this cluster should return group membership lookups - // during authentication using a group of security groups. + // Enabled: Whether this cluster should return group membership lookups during + // authentication using a group of security groups. Enabled bool `json:"enabled,omitempty"` - - // SecurityGroup: The name of the security group-of-groups to be used. - // Only relevant if enabled = true. + // SecurityGroup: The name of the security group-of-groups to be used. Only + // relevant if enabled = true. SecurityGroup string `json:"securityGroup,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AuthenticatorGroupsConfig) MarshalJSON() ([]byte, error) { type NoMethod AuthenticatorGroupsConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AutoUpgradeOptions: AutoUpgradeOptions defines the set of options for -// the user to control how the Auto Upgrades will proceed. +// AutoUpgradeOptions: AutoUpgradeOptions defines the set of options for the +// user to control how the Auto Upgrades will proceed. type AutoUpgradeOptions struct { - // AutoUpgradeStartTime: [Output only] This field is set when upgrades - // are about to commence with the approximate start time for the - // upgrades, in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text - // format. + // AutoUpgradeStartTime: [Output only] This field is set when upgrades are + // about to commence with the approximate start time for the upgrades, in + // RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text format. AutoUpgradeStartTime string `json:"autoUpgradeStartTime,omitempty"` - - // Description: [Output only] This field is set when upgrades are about - // to commence with the description of the upgrade. + // Description: [Output only] This field is set when upgrades are about to + // commence with the description of the upgrade. Description string `json:"description,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AutoUpgradeStartTime") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "AutoUpgradeStartTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AutoUpgradeStartTime") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AutoUpgradeStartTime") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AutoUpgradeOptions) MarshalJSON() ([]byte, error) { type NoMethod AutoUpgradeOptions - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// Autopilot: Autopilot is the configuration for Autopilot settings on -// the cluster. +// Autopilot: Autopilot is the configuration for Autopilot settings on the +// cluster. type Autopilot struct { - // ConversionStatus: Output only. ConversionStatus shows conversion - // status. + // ConversionStatus: Output only. ConversionStatus shows conversion status. ConversionStatus *AutopilotConversionStatus `json:"conversionStatus,omitempty"` - // Enabled: Enable Autopilot Enabled bool `json:"enabled,omitempty"` - // WorkloadPolicyConfig: Workload policy configuration for Autopilot. WorkloadPolicyConfig *WorkloadPolicyConfig `json:"workloadPolicyConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConversionStatus") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ConversionStatus") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ConversionStatus") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Autopilot) MarshalJSON() ([]byte, error) { type NoMethod Autopilot - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // AutopilotCompatibilityIssue: AutopilotCompatibilityIssue contains @@ -737,191 +632,151 @@ func (s *Autopilot) MarshalJSON() ([]byte, error) { type AutopilotCompatibilityIssue struct { // ConstraintType: The constraint type of the issue. ConstraintType string `json:"constraintType,omitempty"` - // Description: The description of the issue. Description string `json:"description,omitempty"` - - // DocumentationUrl: A URL to a public documnetation, which addresses - // resolving this issue. + // DocumentationUrl: A URL to a public documnetation, which addresses resolving + // this issue. DocumentationUrl string `json:"documentationUrl,omitempty"` - // IncompatibilityType: The incompatibility type of this issue. // // Possible values: // "UNSPECIFIED" - Default value, should not be used. - // "INCOMPATIBILITY" - Indicates that the issue is a known - // incompatibility between the cluster and Autopilot mode. - // "ADDITIONAL_CONFIG_REQUIRED" - Indicates the issue is an - // incompatibility if customers take no further action to resolve. + // "INCOMPATIBILITY" - Indicates that the issue is a known incompatibility + // between the cluster and Autopilot mode. + // "ADDITIONAL_CONFIG_REQUIRED" - Indicates the issue is an incompatibility + // if customers take no further action to resolve. // "PASSED_WITH_OPTIONAL_CONFIG" - Indicates the issue is not an - // incompatibility, but depending on the workloads business logic, there - // is a potential that they won't work on Autopilot. + // incompatibility, but depending on the workloads business logic, there is a + // potential that they won't work on Autopilot. IncompatibilityType string `json:"incompatibilityType,omitempty"` - // LastObservation: The last time when this issue was observed. LastObservation string `json:"lastObservation,omitempty"` - // Subjects: The name of the resources which are subject to this issue. Subjects []string `json:"subjects,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConstraintType") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ConstraintType") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ConstraintType") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AutopilotCompatibilityIssue) MarshalJSON() ([]byte, error) { type NoMethod AutopilotCompatibilityIssue - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AutopilotConversionStatus: AutopilotConversionStatus represents -// conversion status. +// AutopilotConversionStatus: AutopilotConversionStatus represents conversion +// status. type AutopilotConversionStatus struct { // State: Output only. The current state of the conversion. // // Possible values: // "STATE_UNSPECIFIED" - STATE_UNSPECIFIED indicates the state is // unspecified. - // "DONE" - DONE indicates the conversion has been completed. Old node - // pools will continue being deleted in the background. + // "DONE" - DONE indicates the conversion has been completed. Old node pools + // will continue being deleted in the background. State string `json:"state,omitempty"` - - // ForceSendFields is a list of field names (e.g. "State") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "State") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "State") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AutopilotConversionStatus) MarshalJSON() ([]byte, error) { type NoMethod AutopilotConversionStatus - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AutoprovisioningNodePoolDefaults: AutoprovisioningNodePoolDefaults -// contains defaults for a node pool created by NAP. +// AutoprovisioningNodePoolDefaults: AutoprovisioningNodePoolDefaults contains +// defaults for a node pool created by NAP. type AutoprovisioningNodePoolDefaults struct { - // BootDiskKmsKey: The Customer Managed Encryption Key used to encrypt - // the boot disk attached to each node in the node pool. This should be - // of the form - // projects/[KEY_PROJECT_ID]/locations/[LOCATION]/keyRings/[RING_NAME]/cr - // yptoKeys/[KEY_NAME]. For more information about protecting resources - // with Cloud KMS Keys please see: + // BootDiskKmsKey: The Customer Managed Encryption Key used to encrypt the + // boot disk attached to each node in the node pool. This should be of the form + // projects/[KEY_PROJECT_ID]/locations/[LOCATION]/keyRings/[RING_NAME]/cryptoKey + // s/[KEY_NAME]. For more information about protecting resources with Cloud KMS + // Keys please see: // https://cloud.google.com/compute/docs/disks/customer-managed-encryption BootDiskKmsKey string `json:"bootDiskKmsKey,omitempty"` - - // DiskSizeGb: Size of the disk attached to each node, specified in GB. - // The smallest allowed disk size is 10GB. If unspecified, the default - // disk size is 100GB. + // DiskSizeGb: Size of the disk attached to each node, specified in GB. The + // smallest allowed disk size is 10GB. If unspecified, the default disk size is + // 100GB. DiskSizeGb int64 `json:"diskSizeGb,omitempty"` - // DiskType: Type of the disk attached to each node (e.g. 'pd-standard', // 'pd-ssd' or 'pd-balanced') If unspecified, the default disk type is // 'pd-standard' DiskType string `json:"diskType,omitempty"` - // ImageType: The image type to use for NAP created node. Please see - // https://cloud.google.com/kubernetes-engine/docs/concepts/node-images - // for available image types. + // https://cloud.google.com/kubernetes-engine/docs/concepts/node-images for + // available image types. ImageType string `json:"imageType,omitempty"` - - // InsecureKubeletReadonlyPortEnabled: Enable or disable Kubelet read - // only port. + // InsecureKubeletReadonlyPortEnabled: Enable or disable Kubelet read only + // port. InsecureKubeletReadonlyPortEnabled bool `json:"insecureKubeletReadonlyPortEnabled,omitempty"` - // Management: NodeManagement configuration for this NodePool. Management *NodeManagement `json:"management,omitempty"` - - // MinCpuPlatform: Deprecated. Minimum CPU platform to be used for NAP - // created node pools. The instance may be scheduled on the specified or - // newer CPU platform. Applicable values are the friendly names of CPU - // platforms, such as minCpuPlatform: Intel Haswell or minCpuPlatform: - // Intel Sandy Bridge. For more information, read how to specify min CPU - // platform + // MinCpuPlatform: Deprecated. Minimum CPU platform to be used for NAP created + // node pools. The instance may be scheduled on the specified or newer CPU + // platform. Applicable values are the friendly names of CPU platforms, such as + // minCpuPlatform: Intel Haswell or minCpuPlatform: Intel Sandy Bridge. For + // more information, read how to specify min CPU platform // (https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform). // This field is deprecated, min_cpu_platform should be specified using - // `cloud.google.com/requested-min-cpu-platform` label selector on the - // pod. To unset the min cpu platform field pass "automatic" as field - // value. + // `cloud.google.com/requested-min-cpu-platform` label selector on the pod. To + // unset the min cpu platform field pass "automatic" as field value. MinCpuPlatform string `json:"minCpuPlatform,omitempty"` - - // OauthScopes: The set of Google API scopes to be made available on all - // of the node VMs under the "default" service account. The following - // scopes are recommended, but not required, and by default are not - // included: * `https://www.googleapis.com/auth/compute` is required for - // mounting persistent storage on your nodes. * - // `https://www.googleapis.com/auth/devstorage.read_only` is required - // for communicating with **gcr.io** (the Google Container Registry - // (https://cloud.google.com/container-registry/)). If unspecified, no - // scopes are added, unless Cloud Logging or Cloud Monitoring are - // enabled, in which case their required scopes will be added. + // OauthScopes: The set of Google API scopes to be made available on all of the + // node VMs under the "default" service account. The following scopes are + // recommended, but not required, and by default are not included: * + // `https://www.googleapis.com/auth/compute` is required for mounting + // persistent storage on your nodes. * + // `https://www.googleapis.com/auth/devstorage.read_only` is required for + // communicating with **gcr.io** (the Google Container Registry + // (https://cloud.google.com/container-registry/)). If unspecified, no scopes + // are added, unless Cloud Logging or Cloud Monitoring are enabled, in which + // case their required scopes will be added. OauthScopes []string `json:"oauthScopes,omitempty"` - - // ServiceAccount: The Google Cloud Platform Service Account to be used - // by the node VMs. Specify the email address of the Service Account; - // otherwise, if no Service Account is specified, the "default" service - // account is used. + // ServiceAccount: The Google Cloud Platform Service Account to be used by the + // node VMs. Specify the email address of the Service Account; otherwise, if no + // Service Account is specified, the "default" service account is used. ServiceAccount string `json:"serviceAccount,omitempty"` - // ShieldedInstanceConfig: Shielded Instance options. ShieldedInstanceConfig *ShieldedInstanceConfig `json:"shieldedInstanceConfig,omitempty"` - // UpgradeSettings: Upgrade settings control disruption and speed of the // upgrade. UpgradeSettings *UpgradeSettings `json:"upgradeSettings,omitempty"` - // ForceSendFields is a list of field names (e.g. "BootDiskKmsKey") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "BootDiskKmsKey") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "BootDiskKmsKey") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AutoprovisioningNodePoolDefaults) MarshalJSON() ([]byte, error) { type NoMethod AutoprovisioningNodePoolDefaults - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// AutoscaledRolloutPolicy: Autoscaled rollout policy uses cluster -// autoscaler during blue-green upgrades to scale both the green and -// blue pools. +// AutoscaledRolloutPolicy: Autoscaled rollout policy uses cluster autoscaler +// during blue-green upgrades to scale both the green and blue pools. type AutoscaledRolloutPolicy struct { } @@ -929,172 +784,135 @@ type AutoscaledRolloutPolicy struct { type AvailableVersion struct { // Reason: Reason for availability. Reason string `json:"reason,omitempty"` - // Version: Kubernetes version. Version string `json:"version,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Reason") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Reason") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Reason") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AvailableVersion) MarshalJSON() ([]byte, error) { type NoMethod AvailableVersion - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BestEffortProvisioning: Best effort provisioning. type BestEffortProvisioning struct { - // Enabled: When this is enabled, cluster/node pool creations will - // ignore non-fatal errors like stockout to best provision as many nodes - // as possible right now and eventually bring up all target number of - // nodes + // Enabled: When this is enabled, cluster/node pool creations will ignore + // non-fatal errors like stockout to best provision as many nodes as possible + // right now and eventually bring up all target number of nodes Enabled bool `json:"enabled,omitempty"` - // MinProvisionNodes: Minimum number of nodes to be provisioned to be - // considered as succeeded, and the rest of nodes will be provisioned - // gradually and eventually when stockout issue has been resolved. + // considered as succeeded, and the rest of nodes will be provisioned gradually + // and eventually when stockout issue has been resolved. MinProvisionNodes int64 `json:"minProvisionNodes,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BestEffortProvisioning) MarshalJSON() ([]byte, error) { type NoMethod BestEffortProvisioning - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BigQueryDestination: Parameters for using BigQuery as the destination -// of resource usage export. +// BigQueryDestination: Parameters for using BigQuery as the destination of +// resource usage export. type BigQueryDestination struct { // DatasetId: The ID of a BigQuery Dataset. DatasetId string `json:"datasetId,omitempty"` - // ForceSendFields is a list of field names (e.g. "DatasetId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DatasetId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DatasetId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BigQueryDestination) MarshalJSON() ([]byte, error) { type NoMethod BigQueryDestination - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BinaryAuthorization: Configuration for Binary Authorization. type BinaryAuthorization struct { - // Enabled: This field is deprecated. Leave this unset and instead - // configure BinaryAuthorization using evaluation_mode. If - // evaluation_mode is set to anything other than - // EVALUATION_MODE_UNSPECIFIED, this field is ignored. + // Enabled: This field is deprecated. Leave this unset and instead configure + // BinaryAuthorization using evaluation_mode. If evaluation_mode is set to + // anything other than EVALUATION_MODE_UNSPECIFIED, this field is ignored. Enabled bool `json:"enabled,omitempty"` - // EvaluationMode: Mode of operation for binauthz policy evaluation. If // unspecified, defaults to DISABLED. // // Possible values: // "EVALUATION_MODE_UNSPECIFIED" - Default value // "DISABLED" - Disable BinaryAuthorization - // "PROJECT_SINGLETON_POLICY_ENFORCE" - Enforce Kubernetes admission - // requests with BinaryAuthorization using the project's singleton - // policy. This is equivalent to setting the enabled boolean to true. - // "POLICY_BINDINGS" - Use Binary Authorization Continuous Validation - // with the policies specified in policy_bindings. + // "PROJECT_SINGLETON_POLICY_ENFORCE" - Enforce Kubernetes admission requests + // with BinaryAuthorization using the project's singleton policy. This is + // equivalent to setting the enabled boolean to true. + // "POLICY_BINDINGS" - Use Binary Authorization Continuous Validation with + // the policies specified in policy_bindings. // "POLICY_BINDINGS_AND_PROJECT_SINGLETON_POLICY_ENFORCE" - Use Binary // Authorization Continuous Validation with the policies specified in // policy_bindings and enforce Kubernetes admission requests with Binary // Authorization using the project's singleton policy. EvaluationMode string `json:"evaluationMode,omitempty"` - - // PolicyBindings: Optional. Binauthz policies that apply to this - // cluster. + // PolicyBindings: Optional. Binauthz policies that apply to this cluster. PolicyBindings []*PolicyBinding `json:"policyBindings,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BinaryAuthorization) MarshalJSON() ([]byte, error) { type NoMethod BinaryAuthorization - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BlueGreenInfo: Information relevant to blue-green upgrade. type BlueGreenInfo struct { - // BlueInstanceGroupUrls: The resource URLs of the [managed instance - // groups] + // BlueInstanceGroupUrls: The resource URLs of the [managed instance groups] // (/compute/docs/instance-groups/creating-groups-of-managed-instances) // associated with blue pool. BlueInstanceGroupUrls []string `json:"blueInstanceGroupUrls,omitempty"` - - // BluePoolDeletionStartTime: Time to start deleting blue pool to - // complete blue-green upgrade, in RFC3339 - // (https://www.ietf.org/rfc/rfc3339.txt) text format. + // BluePoolDeletionStartTime: Time to start deleting blue pool to complete + // blue-green upgrade, in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text + // format. BluePoolDeletionStartTime string `json:"bluePoolDeletionStartTime,omitempty"` - - // GreenInstanceGroupUrls: The resource URLs of the [managed instance - // groups] + // GreenInstanceGroupUrls: The resource URLs of the [managed instance groups] // (/compute/docs/instance-groups/creating-groups-of-managed-instances) // associated with green pool. GreenInstanceGroupUrls []string `json:"greenInstanceGroupUrls,omitempty"` - // GreenPoolVersion: Version of green pool. GreenPoolVersion string `json:"greenPoolVersion,omitempty"` - // Phase: Current blue-green upgrade phase. // // Possible values: @@ -1102,229 +920,175 @@ type BlueGreenInfo struct { // "UPDATE_STARTED" - blue-green upgrade has been initiated. // "CREATING_GREEN_POOL" - Start creating green pool nodes. // "CORDONING_BLUE_POOL" - Start cordoning blue pool nodes. - // "WAITING_TO_DRAIN_BLUE_POOL" - Start waiting after cordoning the - // blue pool and before draining it. + // "WAITING_TO_DRAIN_BLUE_POOL" - Start waiting after cordoning the blue pool + // and before draining it. // "DRAINING_BLUE_POOL" - Start draining blue pool nodes. - // "NODE_POOL_SOAKING" - Start soaking time after draining entire blue - // pool. + // "NODE_POOL_SOAKING" - Start soaking time after draining entire blue pool. // "DELETING_BLUE_POOL" - Start deleting blue nodes. // "ROLLBACK_STARTED" - Rollback has been initiated. Phase string `json:"phase,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "BlueInstanceGroupUrls") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "BlueInstanceGroupUrls") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BlueInstanceGroupUrls") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BlueGreenInfo) MarshalJSON() ([]byte, error) { type NoMethod BlueGreenInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BlueGreenSettings: Settings for blue-green upgrade. type BlueGreenSettings struct { - // AutoscaledRolloutPolicy: Autoscaled policy for cluster autoscaler - // enabled blue-green upgrade. + // AutoscaledRolloutPolicy: Autoscaled policy for cluster autoscaler enabled + // blue-green upgrade. AutoscaledRolloutPolicy *AutoscaledRolloutPolicy `json:"autoscaledRolloutPolicy,omitempty"` - - // NodePoolSoakDuration: Time needed after draining entire blue pool. - // After this period, blue pool will be cleaned up. + // NodePoolSoakDuration: Time needed after draining entire blue pool. After + // this period, blue pool will be cleaned up. NodePoolSoakDuration string `json:"nodePoolSoakDuration,omitempty"` - // StandardRolloutPolicy: Standard policy for the blue-green upgrade. StandardRolloutPolicy *StandardRolloutPolicy `json:"standardRolloutPolicy,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AutoscaledRolloutPolicy") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AutoscaledRolloutPolicy") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AutoscaledRolloutPolicy") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AutoscaledRolloutPolicy") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BlueGreenSettings) MarshalJSON() ([]byte, error) { type NoMethod BlueGreenSettings - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// CancelOperationRequest: CancelOperationRequest cancels a single -// operation. +// CancelOperationRequest: CancelOperationRequest cancels a single operation. type CancelOperationRequest struct { - // Name: The name (project, location, operation id) of the operation to - // cancel. Specified in the format - // `projects/*/locations/*/operations/*`. + // Name: The name (project, location, operation id) of the operation to cancel. + // Specified in the format `projects/*/locations/*/operations/*`. Name string `json:"name,omitempty"` - // OperationId: Required. Deprecated. The server-assigned `name` of the - // operation. This field has been deprecated and replaced by the name - // field. + // operation. This field has been deprecated and replaced by the name field. OperationId string `json:"operationId,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the operation resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the + // operation resides. This field has been deprecated and replaced by the name + // field. Zone string `json:"zone,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Name") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Name") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Name") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Name") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CancelOperationRequest) MarshalJSON() ([]byte, error) { type NoMethod CancelOperationRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // CertificateAuthorityDomainConfig: CertificateAuthorityDomainConfig -// configures one or more fully qualified domain names (FQDN) to a -// specific certificate. +// configures one or more fully qualified domain names (FQDN) to a specific +// certificate. type CertificateAuthorityDomainConfig struct { - // Fqdns: List of fully qualified domain names (FQDN). Specifying port - // is supported. Wilcards are NOT supported. Examples: - - // my.customdomain.com - 10.0.1.2:5000 + // Fqdns: List of fully qualified domain names (FQDN). Specifying port is + // supported. Wilcards are NOT supported. Examples: - my.customdomain.com - + // 10.0.1.2:5000 Fqdns []string `json:"fqdns,omitempty"` - - // GcpSecretManagerCertificateConfig: Google Secret Manager (GCP) - // certificate configuration. + // GcpSecretManagerCertificateConfig: Google Secret Manager (GCP) certificate + // configuration. GcpSecretManagerCertificateConfig *GCPSecretManagerCertificateConfig `json:"gcpSecretManagerCertificateConfig,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Fqdns") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Fqdns") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Fqdns") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CertificateAuthorityDomainConfig) MarshalJSON() ([]byte, error) { type NoMethod CertificateAuthorityDomainConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// CheckAutopilotCompatibilityResponse: -// CheckAutopilotCompatibilityResponse has a list of compatibility -// issues. +// CheckAutopilotCompatibilityResponse: CheckAutopilotCompatibilityResponse has +// a list of compatibility issues. type CheckAutopilotCompatibilityResponse struct { // Issues: The list of issues for the given operation. Issues []*AutopilotCompatibilityIssue `json:"issues,omitempty"` - // Summary: The summary of the autopilot compatibility response. Summary string `json:"summary,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Issues") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Issues") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Issues") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CheckAutopilotCompatibilityResponse) MarshalJSON() ([]byte, error) { type NoMethod CheckAutopilotCompatibilityResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // CidrBlock: CidrBlock contains an optional name and one CIDR block. type CidrBlock struct { // CidrBlock: cidr_block must be specified in CIDR notation. CidrBlock string `json:"cidrBlock,omitempty"` - - // DisplayName: display_name is an optional field for users to identify - // CIDR blocks. + // DisplayName: display_name is an optional field for users to identify CIDR + // blocks. DisplayName string `json:"displayName,omitempty"` - // ForceSendFields is a list of field names (e.g. "CidrBlock") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CidrBlock") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CidrBlock") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CidrBlock) MarshalJSON() ([]byte, error) { type NoMethod CidrBlock - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ClientCertificateConfig: Configuration for client certificates on the @@ -1332,598 +1096,451 @@ func (s *CidrBlock) MarshalJSON() ([]byte, error) { type ClientCertificateConfig struct { // IssueClientCertificate: Issue a client certificate. IssueClientCertificate bool `json:"issueClientCertificate,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "IssueClientCertificate") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "IssueClientCertificate") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "IssueClientCertificate") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "IssueClientCertificate") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ClientCertificateConfig) MarshalJSON() ([]byte, error) { type NoMethod ClientCertificateConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // CloudRunConfig: Configuration options for the Cloud Run feature. type CloudRunConfig struct { // Disabled: Whether Cloud Run addon is enabled for this cluster. Disabled bool `json:"disabled,omitempty"` - - // LoadBalancerType: Which load balancer type is installed for Cloud - // Run. + // LoadBalancerType: Which load balancer type is installed for Cloud Run. // // Possible values: - // "LOAD_BALANCER_TYPE_UNSPECIFIED" - Load balancer type for Cloud Run - // is unspecified. - // "LOAD_BALANCER_TYPE_EXTERNAL" - Install external load balancer for - // Cloud Run. - // "LOAD_BALANCER_TYPE_INTERNAL" - Install internal load balancer for - // Cloud Run. + // "LOAD_BALANCER_TYPE_UNSPECIFIED" - Load balancer type for Cloud Run is + // unspecified. + // "LOAD_BALANCER_TYPE_EXTERNAL" - Install external load balancer for Cloud + // Run. + // "LOAD_BALANCER_TYPE_INTERNAL" - Install internal load balancer for Cloud + // Run. LoadBalancerType string `json:"loadBalancerType,omitempty"` - // ForceSendFields is a list of field names (e.g. "Disabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CloudRunConfig) MarshalJSON() ([]byte, error) { type NoMethod CloudRunConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Cluster: A Google Kubernetes Engine cluster. type Cluster struct { - // AddonsConfig: Configurations for the various addons available to run - // in the cluster. + // AddonsConfig: Configurations for the various addons available to run in the + // cluster. AddonsConfig *AddonsConfig `json:"addonsConfig,omitempty"` - - // AuthenticatorGroupsConfig: Configuration controlling RBAC group - // membership information. + // AuthenticatorGroupsConfig: Configuration controlling RBAC group membership + // information. AuthenticatorGroupsConfig *AuthenticatorGroupsConfig `json:"authenticatorGroupsConfig,omitempty"` - // Autopilot: Autopilot configuration for the cluster. Autopilot *Autopilot `json:"autopilot,omitempty"` - // Autoscaling: Cluster-level autoscaling configuration. Autoscaling *ClusterAutoscaling `json:"autoscaling,omitempty"` - // BinaryAuthorization: Configuration for Binary Authorization. BinaryAuthorization *BinaryAuthorization `json:"binaryAuthorization,omitempty"` - - // ClusterIpv4Cidr: The IP address range of the container pods in this - // cluster, in CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `10.96.0.0/14`). Leave blank to have one automatically - // chosen or specify a `/14` block in `10.0.0.0/8`. + // ClusterIpv4Cidr: The IP address range of the container pods in this cluster, + // in CIDR (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) + // notation (e.g. `10.96.0.0/14`). Leave blank to have one automatically chosen + // or specify a `/14` block in `10.0.0.0/8`. ClusterIpv4Cidr string `json:"clusterIpv4Cidr,omitempty"` - // ClusterTelemetry: Telemetry integration for the cluster. ClusterTelemetry *ClusterTelemetry `json:"clusterTelemetry,omitempty"` - - // CompliancePostureConfig: Enable/Disable Compliance Posture features - // for the cluster. + // CompliancePostureConfig: Enable/Disable Compliance Posture features for the + // cluster. CompliancePostureConfig *CompliancePostureConfig `json:"compliancePostureConfig,omitempty"` - // Conditions: Which conditions caused the current cluster state. Conditions []*StatusCondition `json:"conditions,omitempty"` - - // ConfidentialNodes: Configuration of Confidential Nodes. All the nodes - // in the cluster will be Confidential VM once enabled. + // ConfidentialNodes: Configuration of Confidential Nodes. All the nodes in the + // cluster will be Confidential VM once enabled. ConfidentialNodes *ConfidentialNodes `json:"confidentialNodes,omitempty"` - - // CostManagementConfig: Configuration for the fine-grained cost - // management feature. + // CostManagementConfig: Configuration for the fine-grained cost management + // feature. CostManagementConfig *CostManagementConfig `json:"costManagementConfig,omitempty"` - - // CreateTime: [Output only] The time the cluster was created, in - // RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text format. + // CreateTime: [Output only] The time the cluster was created, in RFC3339 + // (https://www.ietf.org/rfc/rfc3339.txt) text format. CreateTime string `json:"createTime,omitempty"` - - // CurrentMasterVersion: [Output only] The current software version of - // the master endpoint. + // CurrentMasterVersion: [Output only] The current software version of the + // master endpoint. CurrentMasterVersion string `json:"currentMasterVersion,omitempty"` - // CurrentNodeCount: [Output only] The number of nodes currently in the // cluster. Deprecated. Call Kubernetes API directly to retrieve node // information. CurrentNodeCount int64 `json:"currentNodeCount,omitempty"` - // CurrentNodeVersion: [Output only] Deprecated, use NodePool.version // (https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters.nodePools) - // instead. The current version of the node software components. If they - // are currently at multiple versions because they're in the process of - // being upgraded, this reflects the minimum version of all nodes. + // instead. The current version of the node software components. If they are + // currently at multiple versions because they're in the process of being + // upgraded, this reflects the minimum version of all nodes. CurrentNodeVersion string `json:"currentNodeVersion,omitempty"` - // DatabaseEncryption: Configuration of etcd encryption. DatabaseEncryption *DatabaseEncryption `json:"databaseEncryption,omitempty"` - - // DefaultMaxPodsConstraint: The default constraint on the maximum - // number of pods that can be run simultaneously on a node in the node - // pool of this cluster. Only honored if cluster created with IP Alias - // support. + // DefaultMaxPodsConstraint: The default constraint on the maximum number of + // pods that can be run simultaneously on a node in the node pool of this + // cluster. Only honored if cluster created with IP Alias support. DefaultMaxPodsConstraint *MaxPodsConstraint `json:"defaultMaxPodsConstraint,omitempty"` - // Description: An optional description of this cluster. Description string `json:"description,omitempty"` - - // EnableK8sBetaApis: Kubernetes open source beta apis enabled on the - // cluster. Only beta apis. + // EnableK8sBetaApis: Kubernetes open source beta apis enabled on the cluster. + // Only beta apis. EnableK8sBetaApis *K8sBetaAPIConfig `json:"enableK8sBetaApis,omitempty"` - // EnableKubernetesAlpha: Kubernetes alpha features are enabled on this - // cluster. This includes alpha API groups (e.g. v1beta1) and features - // that may not be production ready in the kubernetes version of the - // master and nodes. The cluster has no SLA for uptime and master/node - // upgrades are disabled. Alpha enabled clusters are automatically - // deleted thirty days after creation. + // cluster. This includes alpha API groups (e.g. v1beta1) and features that may + // not be production ready in the kubernetes version of the master and nodes. + // The cluster has no SLA for uptime and master/node upgrades are disabled. + // Alpha enabled clusters are automatically deleted thirty days after creation. EnableKubernetesAlpha bool `json:"enableKubernetesAlpha,omitempty"` - - // EnableTpu: Enable the ability to use Cloud TPUs in this cluster. This - // field is deprecated, use tpu_config.enabled instead. + // EnableTpu: Enable the ability to use Cloud TPUs in this cluster. This field + // is deprecated, use tpu_config.enabled instead. EnableTpu bool `json:"enableTpu,omitempty"` - - // Endpoint: [Output only] The IP address of this cluster's master - // endpoint. The endpoint can be accessed from the internet at - // `https://username:password@endpoint/`. See the `masterAuth` property - // of this resource for username and password information. + // Endpoint: [Output only] The IP address of this cluster's master endpoint. + // The endpoint can be accessed from the internet at + // `https://username:password@endpoint/`. See the `masterAuth` property of this + // resource for username and password information. Endpoint string `json:"endpoint,omitempty"` - // EnterpriseConfig: GKE Enterprise Configuration. EnterpriseConfig *EnterpriseConfig `json:"enterpriseConfig,omitempty"` - - // Etag: This checksum is computed by the server based on the value of - // cluster fields, and may be sent on update requests to ensure the - // client has an up-to-date value before proceeding. + // Etag: This checksum is computed by the server based on the value of cluster + // fields, and may be sent on update requests to ensure the client has an + // up-to-date value before proceeding. Etag string `json:"etag,omitempty"` - - // ExpireTime: [Output only] The time the cluster will be automatically - // deleted in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text - // format. + // ExpireTime: [Output only] The time the cluster will be automatically deleted + // in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text format. ExpireTime string `json:"expireTime,omitempty"` - // Fleet: Fleet information for the cluster. Fleet *Fleet `json:"fleet,omitempty"` - // Id: Output only. Unique id for the cluster. Id string `json:"id,omitempty"` - // IdentityServiceConfig: Configuration for Identity Service component. IdentityServiceConfig *IdentityServiceConfig `json:"identityServiceConfig,omitempty"` - - // InitialClusterVersion: The initial Kubernetes version for this - // cluster. Valid versions are those found in validMasterVersions - // returned by getServerConfig. The version can be upgraded over time; - // such upgrades are reflected in currentMasterVersion and - // currentNodeVersion. Users may specify either explicit versions - // offered by Kubernetes Engine or version aliases, which have the - // following behavior: - "latest": picks the highest valid Kubernetes - // version - "1.X": picks the highest valid patch+gke.N patch in the 1.X - // version - "1.X.Y": picks the highest valid gke.N patch in the 1.X.Y - // version - "1.X.Y-gke.N": picks an explicit Kubernetes version - - // "","-": picks the default Kubernetes version + // InitialClusterVersion: The initial Kubernetes version for this cluster. + // Valid versions are those found in validMasterVersions returned by + // getServerConfig. The version can be upgraded over time; such upgrades are + // reflected in currentMasterVersion and currentNodeVersion. Users may specify + // either explicit versions offered by Kubernetes Engine or version aliases, + // which have the following behavior: - "latest": picks the highest valid + // Kubernetes version - "1.X": picks the highest valid patch+gke.N patch in the + // 1.X version - "1.X.Y": picks the highest valid gke.N patch in the 1.X.Y + // version - "1.X.Y-gke.N": picks an explicit Kubernetes version - "","-": + // picks the default Kubernetes version InitialClusterVersion string `json:"initialClusterVersion,omitempty"` - - // InitialNodeCount: The number of nodes to create in this cluster. You - // must ensure that your Compute Engine resource quota - // (https://cloud.google.com/compute/quotas) is sufficient for this - // number of instances. You must also have available firewall and routes - // quota. For requests, this field should only be used in lieu of a - // "node_pool" object, since this configuration (along with the - // "node_config") will be used to create a "NodePool" object with an - // auto-generated name. Do not use this and a node_pool at the same - // time. This field is deprecated, use node_pool.initial_node_count - // instead. + // InitialNodeCount: The number of nodes to create in this cluster. You must + // ensure that your Compute Engine resource quota + // (https://cloud.google.com/compute/quotas) is sufficient for this number of + // instances. You must also have available firewall and routes quota. For + // requests, this field should only be used in lieu of a "node_pool" object, + // since this configuration (along with the "node_config") will be used to + // create a "NodePool" object with an auto-generated name. Do not use this and + // a node_pool at the same time. This field is deprecated, use + // node_pool.initial_node_count instead. InitialNodeCount int64 `json:"initialNodeCount,omitempty"` - // InstanceGroupUrls: Deprecated. Use node_pools.instance_group_urls. InstanceGroupUrls []string `json:"instanceGroupUrls,omitempty"` - // IpAllocationPolicy: Configuration for cluster IP allocation. IpAllocationPolicy *IPAllocationPolicy `json:"ipAllocationPolicy,omitempty"` - - // LabelFingerprint: The fingerprint of the set of labels for this - // cluster. + // LabelFingerprint: The fingerprint of the set of labels for this cluster. LabelFingerprint string `json:"labelFingerprint,omitempty"` - // LegacyAbac: Configuration for the legacy ABAC authorization mode. LegacyAbac *LegacyAbac `json:"legacyAbac,omitempty"` - // Location: [Output only] The name of the Google Compute Engine zone // (https://cloud.google.com/compute/docs/regions-zones/regions-zones#available) // or region // (https://cloud.google.com/compute/docs/regions-zones/regions-zones#available) // in which the cluster resides. Location string `json:"location,omitempty"` - // Locations: The list of Google Compute Engine zones // (https://cloud.google.com/compute/docs/zones#available) in which the - // cluster's nodes should be located. This field provides a default - // value if NodePool.Locations + // cluster's nodes should be located. This field provides a default value if + // NodePool.Locations // (https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1/projects.locations.clusters.nodePools#NodePool.FIELDS.locations) - // are not specified during node pool creation. Warning: changing - // cluster locations will update the NodePool.Locations + // are not specified during node pool creation. Warning: changing cluster + // locations will update the NodePool.Locations // (https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1/projects.locations.clusters.nodePools#NodePool.FIELDS.locations) - // of all node pools and will result in nodes being added and/or - // removed. + // of all node pools and will result in nodes being added and/or removed. Locations []string `json:"locations,omitempty"` - // LoggingConfig: Logging configuration for the cluster. LoggingConfig *LoggingConfig `json:"loggingConfig,omitempty"` - - // LoggingService: The logging service the cluster should use to write - // logs. Currently available options: * - // `logging.googleapis.com/kubernetes` - The Cloud Logging service with - // a Kubernetes-native resource model * `logging.googleapis.com` - The - // legacy Cloud Logging service (no longer available as of GKE 1.15). * - // `none` - no logs will be exported from the cluster. If left as an - // empty string,`logging.googleapis.com/kubernetes` will be used for GKE - // 1.14+ or `logging.googleapis.com` for earlier versions. + // LoggingService: The logging service the cluster should use to write logs. + // Currently available options: * `logging.googleapis.com/kubernetes` - The + // Cloud Logging service with a Kubernetes-native resource model * + // `logging.googleapis.com` - The legacy Cloud Logging service (no longer + // available as of GKE 1.15). * `none` - no logs will be exported from the + // cluster. If left as an empty string,`logging.googleapis.com/kubernetes` will + // be used for GKE 1.14+ or `logging.googleapis.com` for earlier versions. LoggingService string `json:"loggingService,omitempty"` - // MaintenancePolicy: Configure the maintenance policy for this cluster. MaintenancePolicy *MaintenancePolicy `json:"maintenancePolicy,omitempty"` - // Master: Configuration for master components. Master *Master `json:"master,omitempty"` - // MasterAuth: The authentication information for accessing the master - // endpoint. If unspecified, the defaults are used: For clusters before - // v1.12, if master_auth is unspecified, `username` will be set to - // "admin", a random password will be generated, and a client - // certificate will be issued. + // endpoint. If unspecified, the defaults are used: For clusters before v1.12, + // if master_auth is unspecified, `username` will be set to "admin", a random + // password will be generated, and a client certificate will be issued. MasterAuth *MasterAuth `json:"masterAuth,omitempty"` - // MasterAuthorizedNetworksConfig: The configuration options for master // authorized networks feature. MasterAuthorizedNetworksConfig *MasterAuthorizedNetworksConfig `json:"masterAuthorizedNetworksConfig,omitempty"` - - // MasterIpv4CidrBlock: The IP prefix in CIDR notation to use for the - // hosted master network. This prefix will be used for assigning private - // IP addresses to the master or set of masters, as well as the ILB VIP. - // This field is deprecated, use - // private_cluster_config.master_ipv4_cidr_block instead. + // MasterIpv4CidrBlock: The IP prefix in CIDR notation to use for the hosted + // master network. This prefix will be used for assigning private IP addresses + // to the master or set of masters, as well as the ILB VIP. This field is + // deprecated, use private_cluster_config.master_ipv4_cidr_block instead. MasterIpv4CidrBlock string `json:"masterIpv4CidrBlock,omitempty"` - - // MeshCertificates: Configuration for issuance of mTLS keys and - // certificates to Kubernetes pods. + // MeshCertificates: Configuration for issuance of mTLS keys and certificates + // to Kubernetes pods. MeshCertificates *MeshCertificates `json:"meshCertificates,omitempty"` - // MonitoringConfig: Monitoring configuration for the cluster. MonitoringConfig *MonitoringConfig `json:"monitoringConfig,omitempty"` - - // MonitoringService: The monitoring service the cluster should use to - // write metrics. Currently available options: * - // "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service - // with a Kubernetes-native resource model * `monitoring.googleapis.com` - // - The legacy Cloud Monitoring service (no longer available as of GKE - // 1.15). * `none` - No metrics will be exported from the cluster. If - // left as an empty string,`monitoring.googleapis.com/kubernetes` will - // be used for GKE 1.14+ or `monitoring.googleapis.com` for earlier - // versions. + // MonitoringService: The monitoring service the cluster should use to write + // metrics. Currently available options: * + // "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service with a + // Kubernetes-native resource model * `monitoring.googleapis.com` - The legacy + // Cloud Monitoring service (no longer available as of GKE 1.15). * `none` - No + // metrics will be exported from the cluster. If left as an empty + // string,`monitoring.googleapis.com/kubernetes` will be used for GKE 1.14+ or + // `monitoring.googleapis.com` for earlier versions. MonitoringService string `json:"monitoringService,omitempty"` - - // Name: The name of this cluster. The name must be unique within this - // project and location (e.g. zone or region), and can be up to 40 - // characters with the following restrictions: * Lowercase letters, - // numbers, and hyphens only. * Must start with a letter. * Must end - // with a number or a letter. + // Name: The name of this cluster. The name must be unique within this project + // and location (e.g. zone or region), and can be up to 40 characters with the + // following restrictions: * Lowercase letters, numbers, and hyphens only. * + // Must start with a letter. * Must end with a number or a letter. Name string `json:"name,omitempty"` - // Network: The name of the Google Compute Engine network - // (https://cloud.google.com/compute/docs/networks-and-firewalls#networks) - // to which the cluster is connected. If left unspecified, the `default` - // network will be used. On output this shows the network ID instead of - // the name. + // (https://cloud.google.com/compute/docs/networks-and-firewalls#networks) to + // which the cluster is connected. If left unspecified, the `default` network + // will be used. On output this shows the network ID instead of the name. Network string `json:"network,omitempty"` - // NetworkConfig: Configuration for cluster networking. NetworkConfig *NetworkConfig `json:"networkConfig,omitempty"` - // NetworkPolicy: Configuration options for the NetworkPolicy feature. NetworkPolicy *NetworkPolicy `json:"networkPolicy,omitempty"` - - // NodeConfig: Parameters used in creating the cluster's nodes. For - // requests, this field should only be used in lieu of a "node_pool" - // object, since this configuration (along with the - // "initial_node_count") will be used to create a "NodePool" object with - // an auto-generated name. Do not use this and a node_pool at the same - // time. For responses, this field will be populated with the node - // configuration of the first node pool. (For configuration of each node - // pool, see `node_pool.config`) If unspecified, the defaults are used. + // NodeConfig: Parameters used in creating the cluster's nodes. For requests, + // this field should only be used in lieu of a "node_pool" object, since this + // configuration (along with the "initial_node_count") will be used to create a + // "NodePool" object with an auto-generated name. Do not use this and a + // node_pool at the same time. For responses, this field will be populated with + // the node configuration of the first node pool. (For configuration of each + // node pool, see `node_pool.config`) If unspecified, the defaults are used. // This field is deprecated, use node_pool.config instead. NodeConfig *NodeConfig `json:"nodeConfig,omitempty"` - - // NodeIpv4CidrSize: [Output only] The size of the address space on each - // node for hosting containers. This is provisioned from within the - // `container_ipv4_cidr` range. This field will only be set when cluster - // is in route-based network mode. + // NodeIpv4CidrSize: [Output only] The size of the address space on each node + // for hosting containers. This is provisioned from within the + // `container_ipv4_cidr` range. This field will only be set when cluster is in + // route-based network mode. NodeIpv4CidrSize int64 `json:"nodeIpv4CidrSize,omitempty"` - - // NodePoolAutoConfig: Node pool configs that apply to all - // auto-provisioned node pools in autopilot clusters and node - // auto-provisioning enabled clusters. + // NodePoolAutoConfig: Node pool configs that apply to all auto-provisioned + // node pools in autopilot clusters and node auto-provisioning enabled + // clusters. NodePoolAutoConfig *NodePoolAutoConfig `json:"nodePoolAutoConfig,omitempty"` - - // NodePoolDefaults: Default NodePool settings for the entire cluster. - // These settings are overridden if specified on the specific NodePool - // object. + // NodePoolDefaults: Default NodePool settings for the entire cluster. These + // settings are overridden if specified on the specific NodePool object. NodePoolDefaults *NodePoolDefaults `json:"nodePoolDefaults,omitempty"` - - // NodePools: The node pools associated with this cluster. This field - // should not be set if "node_config" or "initial_node_count" are - // specified. + // NodePools: The node pools associated with this cluster. This field should + // not be set if "node_config" or "initial_node_count" are specified. NodePools []*NodePool `json:"nodePools,omitempty"` - // NotificationConfig: Notification configuration of the cluster. NotificationConfig *NotificationConfig `json:"notificationConfig,omitempty"` - - // ParentProductConfig: The configuration of the parent product of the - // cluster. This field is used by Google internal products that are - // built on top of the GKE cluster and take the ownership of the - // cluster. + // ParentProductConfig: The configuration of the parent product of the cluster. + // This field is used by Google internal products that are built on top of the + // GKE cluster and take the ownership of the cluster. ParentProductConfig *ParentProductConfig `json:"parentProductConfig,omitempty"` - - // PodSecurityPolicyConfig: Configuration for the PodSecurityPolicy - // feature. + // PodSecurityPolicyConfig: Configuration for the PodSecurityPolicy feature. PodSecurityPolicyConfig *PodSecurityPolicyConfig `json:"podSecurityPolicyConfig,omitempty"` - - // PrivateCluster: If this is a private cluster setup. Private clusters - // are clusters that, by default have no external IP addresses on the - // nodes and where nodes and the master communicate over private IP - // addresses. This field is deprecated, use - // private_cluster_config.enable_private_nodes instead. + // PrivateCluster: If this is a private cluster setup. Private clusters are + // clusters that, by default have no external IP addresses on the nodes and + // where nodes and the master communicate over private IP addresses. This field + // is deprecated, use private_cluster_config.enable_private_nodes instead. PrivateCluster bool `json:"privateCluster,omitempty"` - // PrivateClusterConfig: Configuration for private cluster. PrivateClusterConfig *PrivateClusterConfig `json:"privateClusterConfig,omitempty"` - - // ProtectConfig: Deprecated: Use SecurityPostureConfig instead. - // Enable/Disable Protect API features for the cluster. + // ProtectConfig: Deprecated: Use SecurityPostureConfig instead. Enable/Disable + // Protect API features for the cluster. ProtectConfig *ProtectConfig `json:"protectConfig,omitempty"` - // ReleaseChannel: Release channel configuration. If left unspecified on - // cluster creation and a version is specified, the cluster is enrolled - // in the most mature release channel where the version is available - // (first checking STABLE, then REGULAR, and finally RAPID). Otherwise, - // if no release channel configuration and no version is specified, the - // cluster is enrolled in the REGULAR channel with its default version. + // cluster creation and a version is specified, the cluster is enrolled in the + // most mature release channel where the version is available (first checking + // STABLE, then REGULAR, and finally RAPID). Otherwise, if no release channel + // configuration and no version is specified, the cluster is enrolled in the + // REGULAR channel with its default version. ReleaseChannel *ReleaseChannel `json:"releaseChannel,omitempty"` - - // ResourceLabels: The resource labels for the cluster to use to - // annotate any related Google Compute Engine resources. + // ResourceLabels: The resource labels for the cluster to use to annotate any + // related Google Compute Engine resources. ResourceLabels map[string]string `json:"resourceLabels,omitempty"` - - // ResourceUsageExportConfig: Configuration for exporting resource - // usages. Resource usage export is disabled when this config - // unspecified. + // ResourceUsageExportConfig: Configuration for exporting resource usages. + // Resource usage export is disabled when this config unspecified. ResourceUsageExportConfig *ResourceUsageExportConfig `json:"resourceUsageExportConfig,omitempty"` - // SecretManagerConfig: Secret CSI driver configuration. SecretManagerConfig *SecretManagerConfig `json:"secretManagerConfig,omitempty"` - - // SecurityPostureConfig: Enable/Disable Security Posture API features - // for the cluster. + // SecurityPostureConfig: Enable/Disable Security Posture API features for the + // cluster. SecurityPostureConfig *SecurityPostureConfig `json:"securityPostureConfig,omitempty"` - // SelfLink: [Output only] Server-defined URL for the resource. SelfLink string `json:"selfLink,omitempty"` - - // ServicesIpv4Cidr: [Output only] The IP address range of the - // Kubernetes services in this cluster, in CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `1.2.3.4/29`). Service addresses are typically put in - // the last `/16` from the container CIDR. + // ServicesIpv4Cidr: [Output only] The IP address range of the Kubernetes + // services in this cluster, in CIDR + // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. + // `1.2.3.4/29`). Service addresses are typically put in the last `/16` from + // the container CIDR. ServicesIpv4Cidr string `json:"servicesIpv4Cidr,omitempty"` - // ShieldedNodes: Shielded Nodes configuration. ShieldedNodes *ShieldedNodes `json:"shieldedNodes,omitempty"` - // Status: [Output only] The current status of this cluster. // // Possible values: // "STATUS_UNSPECIFIED" - Not set. - // "PROVISIONING" - The PROVISIONING state indicates the cluster is - // being created. - // "RUNNING" - The RUNNING state indicates the cluster has been - // created and is fully usable. - // "RECONCILING" - The RECONCILING state indicates that some work is - // actively being done on the cluster, such as upgrading the master or - // node software. Details can be found in the `statusMessage` field. - // "STOPPING" - The STOPPING state indicates the cluster is being - // deleted. - // "ERROR" - The ERROR state indicates the cluster may be unusable. + // "PROVISIONING" - The PROVISIONING state indicates the cluster is being + // created. + // "RUNNING" - The RUNNING state indicates the cluster has been created and + // is fully usable. + // "RECONCILING" - The RECONCILING state indicates that some work is actively + // being done on the cluster, such as upgrading the master or node software. // Details can be found in the `statusMessage` field. - // "DEGRADED" - The DEGRADED state indicates the cluster requires user - // action to restore full functionality. Details can be found in the - // `statusMessage` field. + // "STOPPING" - The STOPPING state indicates the cluster is being deleted. + // "ERROR" - The ERROR state indicates the cluster may be unusable. Details + // can be found in the `statusMessage` field. + // "DEGRADED" - The DEGRADED state indicates the cluster requires user action + // to restore full functionality. Details can be found in the `statusMessage` + // field. Status string `json:"status,omitempty"` - - // StatusMessage: [Output only] Deprecated. Use conditions instead. - // Additional information about the current status of this cluster, if - // available. + // StatusMessage: [Output only] Deprecated. Use conditions instead. Additional + // information about the current status of this cluster, if available. StatusMessage string `json:"statusMessage,omitempty"` - // Subnetwork: The name of the Google Compute Engine subnetwork - // (https://cloud.google.com/compute/docs/subnetworks) to which the - // cluster is connected. On output this shows the subnetwork ID instead - // of the name. + // (https://cloud.google.com/compute/docs/subnetworks) to which the cluster is + // connected. On output this shows the subnetwork ID instead of the name. Subnetwork string `json:"subnetwork,omitempty"` - // TpuConfig: Configuration for Cloud TPU support; TpuConfig *TpuConfig `json:"tpuConfig,omitempty"` - - // TpuIpv4CidrBlock: [Output only] The IP address range of the Cloud - // TPUs in this cluster, in CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `1.2.3.4/29`). + // TpuIpv4CidrBlock: [Output only] The IP address range of the Cloud TPUs in + // this cluster, in CIDR + // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. + // `1.2.3.4/29`). TpuIpv4CidrBlock string `json:"tpuIpv4CidrBlock,omitempty"` - // VerticalPodAutoscaling: Cluster-level Vertical Pod Autoscaling // configuration. VerticalPodAutoscaling *VerticalPodAutoscaling `json:"verticalPodAutoscaling,omitempty"` - - // WorkloadAltsConfig: Configuration for direct-path (via ALTS) with - // workload identity. + // WorkloadAltsConfig: Configuration for direct-path (via ALTS) with workload + // identity. WorkloadAltsConfig *WorkloadALTSConfig `json:"workloadAltsConfig,omitempty"` - // WorkloadCertificates: Configuration for issuance of mTLS keys and // certificates to Kubernetes pods. WorkloadCertificates *WorkloadCertificates `json:"workloadCertificates,omitempty"` - - // WorkloadIdentityConfig: Configuration for the use of Kubernetes - // Service Accounts in GCP IAM policies. + // WorkloadIdentityConfig: Configuration for the use of Kubernetes Service + // Accounts in GCP IAM policies. WorkloadIdentityConfig *WorkloadIdentityConfig `json:"workloadIdentityConfig,omitempty"` - // Zone: [Output only] The name of the Google Compute Engine zone - // (https://cloud.google.com/compute/docs/zones#available) in which the - // cluster resides. This field is deprecated, use location instead. + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field is deprecated, use location instead. Zone string `json:"zone,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AddonsConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AddonsConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AddonsConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Cluster) MarshalJSON() ([]byte, error) { type NoMethod Cluster - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ClusterAutoscaling: ClusterAutoscaling contains global, per-cluster -// information required by Cluster Autoscaler to automatically adjust -// the size of the cluster and create/delete node pools based on the -// current needs. +// information required by Cluster Autoscaler to automatically adjust the size +// of the cluster and create/delete node pools based on the current needs. type ClusterAutoscaling struct { // AutoprovisioningLocations: The list of Google Compute Engine zones // (https://cloud.google.com/compute/docs/zones#available) in which the // NodePool's nodes can be created by NAP. AutoprovisioningLocations []string `json:"autoprovisioningLocations,omitempty"` - - // AutoprovisioningNodePoolDefaults: AutoprovisioningNodePoolDefaults - // contains defaults for a node pool created by NAP. + // AutoprovisioningNodePoolDefaults: AutoprovisioningNodePoolDefaults contains + // defaults for a node pool created by NAP. AutoprovisioningNodePoolDefaults *AutoprovisioningNodePoolDefaults `json:"autoprovisioningNodePoolDefaults,omitempty"` - // AutoscalingProfile: Defines autoscaling behaviour. // // Possible values: // "PROFILE_UNSPECIFIED" - No change to autoscaling configuration. - // "OPTIMIZE_UTILIZATION" - Prioritize optimizing utilization of - // resources. + // "OPTIMIZE_UTILIZATION" - Prioritize optimizing utilization of resources. // "BALANCED" - Use default (balanced) autoscaling configuration. AutoscalingProfile string `json:"autoscalingProfile,omitempty"` - // EnableNodeAutoprovisioning: Enables automatic node pool creation and // deletion. EnableNodeAutoprovisioning bool `json:"enableNodeAutoprovisioning,omitempty"` - - // ResourceLimits: Contains global constraints regarding minimum and - // maximum amount of resources in the cluster. + // ResourceLimits: Contains global constraints regarding minimum and maximum + // amount of resources in the cluster. ResourceLimits []*ResourceLimit `json:"resourceLimits,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AutoprovisioningLocations") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AutoprovisioningLocations") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "AutoprovisioningLocations") to include in API requests with the JSON - // null value. By default, fields with empty values are omitted from API - // requests. However, any field with an empty value appearing in - // NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "AutoprovisioningLocations") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ClusterAutoscaling) MarshalJSON() ([]byte, error) { type NoMethod ClusterAutoscaling - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ClusterNetworkPerformanceConfig: Configuration of all network -// bandwidth tiers +// ClusterNetworkPerformanceConfig: Configuration of all network bandwidth +// tiers type ClusterNetworkPerformanceConfig struct { - // TotalEgressBandwidthTier: Specifies the total network bandwidth tier - // for the NodePool. + // TotalEgressBandwidthTier: Specifies the total network bandwidth tier for the + // NodePool. // // Possible values: // "TIER_UNSPECIFIED" - Default value // "TIER_1" - Higher bandwidth, actual values based on VM size. TotalEgressBandwidthTier string `json:"totalEgressBandwidthTier,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "TotalEgressBandwidthTier") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "TotalEgressBandwidthTier") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "TotalEgressBandwidthTier") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "TotalEgressBandwidthTier") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ClusterNetworkPerformanceConfig) MarshalJSON() ([]byte, error) { type NoMethod ClusterNetworkPerformanceConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ClusterTelemetry: Telemetry integration for the cluster. @@ -1936,442 +1553,333 @@ type ClusterTelemetry struct { // "ENABLED" - Monitoring integration is enabled. // "SYSTEM_ONLY" - Only system components are monitored and logged. Type string `json:"type,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Type") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Type") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Type") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Type") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ClusterTelemetry) MarshalJSON() ([]byte, error) { type NoMethod ClusterTelemetry - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ClusterUpdate: ClusterUpdate describes an update to the cluster. -// Exactly one update can be applied to a cluster with each request, so -// at most one field can be provided. +// ClusterUpdate: ClusterUpdate describes an update to the cluster. Exactly one +// update can be applied to a cluster with each request, so at most one field +// can be provided. type ClusterUpdate struct { - // AdditionalPodRangesConfig: The additional pod ranges to be added to - // the cluster. These pod ranges can be used by node pools to allocate - // pod IPs. + // AdditionalPodRangesConfig: The additional pod ranges to be added to the + // cluster. These pod ranges can be used by node pools to allocate pod IPs. AdditionalPodRangesConfig *AdditionalPodRangesConfig `json:"additionalPodRangesConfig,omitempty"` - - // DesiredAddonsConfig: Configurations for the various addons available - // to run in the cluster. + // DesiredAddonsConfig: Configurations for the various addons available to run + // in the cluster. DesiredAddonsConfig *AddonsConfig `json:"desiredAddonsConfig,omitempty"` - - // DesiredAuthenticatorGroupsConfig: AuthenticatorGroupsConfig specifies - // the config for the cluster security groups settings. + // DesiredAuthenticatorGroupsConfig: AuthenticatorGroupsConfig specifies the + // config for the cluster security groups settings. DesiredAuthenticatorGroupsConfig *AuthenticatorGroupsConfig `json:"desiredAuthenticatorGroupsConfig,omitempty"` - // DesiredAutopilotWorkloadPolicyConfig: The desired workload policy // configuration for the autopilot cluster. DesiredAutopilotWorkloadPolicyConfig *WorkloadPolicyConfig `json:"desiredAutopilotWorkloadPolicyConfig,omitempty"` - - // DesiredBinaryAuthorization: The desired configuration options for the - // Binary Authorization feature. + // DesiredBinaryAuthorization: The desired configuration options for the Binary + // Authorization feature. DesiredBinaryAuthorization *BinaryAuthorization `json:"desiredBinaryAuthorization,omitempty"` - // DesiredClusterAutoscaling: Cluster-level autoscaling configuration. DesiredClusterAutoscaling *ClusterAutoscaling `json:"desiredClusterAutoscaling,omitempty"` - - // DesiredClusterTelemetry: The desired telemetry integration for the - // cluster. + // DesiredClusterTelemetry: The desired telemetry integration for the cluster. DesiredClusterTelemetry *ClusterTelemetry `json:"desiredClusterTelemetry,omitempty"` - - // DesiredContainerdConfig: The desired containerd config for the - // cluster. + // DesiredContainerdConfig: The desired containerd config for the cluster. DesiredContainerdConfig *ContainerdConfig `json:"desiredContainerdConfig,omitempty"` - - // DesiredCostManagementConfig: The desired configuration for the - // fine-grained cost management feature. + // DesiredCostManagementConfig: The desired configuration for the fine-grained + // cost management feature. DesiredCostManagementConfig *CostManagementConfig `json:"desiredCostManagementConfig,omitempty"` - // DesiredDatabaseEncryption: Configuration of etcd encryption. DesiredDatabaseEncryption *DatabaseEncryption `json:"desiredDatabaseEncryption,omitempty"` - - // DesiredDatapathProvider: The desired datapath provider for the - // cluster. + // DesiredDatapathProvider: The desired datapath provider for the cluster. // // Possible values: // "DATAPATH_PROVIDER_UNSPECIFIED" - Default value. - // "LEGACY_DATAPATH" - Use the IPTables implementation based on - // kube-proxy. - // "ADVANCED_DATAPATH" - Use the eBPF based GKE Dataplane V2 with - // additional features. See the [GKE Dataplane V2 - // documentation](https://cloud.google.com/kubernetes-engine/docs/how-to/ - // dataplane-v2) for more. + // "LEGACY_DATAPATH" - Use the IPTables implementation based on kube-proxy. + // "ADVANCED_DATAPATH" - Use the eBPF based GKE Dataplane V2 with additional + // features. See the [GKE Dataplane V2 + // documentation](https://cloud.google.com/kubernetes-engine/docs/how-to/datapla + // ne-v2) for more. DesiredDatapathProvider string `json:"desiredDatapathProvider,omitempty"` - - // DesiredDefaultSnatStatus: The desired status of whether to disable - // default sNAT for this cluster. + // DesiredDefaultSnatStatus: The desired status of whether to disable default + // sNAT for this cluster. DesiredDefaultSnatStatus *DefaultSnatStatus `json:"desiredDefaultSnatStatus,omitempty"` - - // DesiredDnsConfig: DNSConfig contains clusterDNS config for this - // cluster. + // DesiredDnsConfig: DNSConfig contains clusterDNS config for this cluster. DesiredDnsConfig *DNSConfig `json:"desiredDnsConfig,omitempty"` - // DesiredEnableCiliumClusterwideNetworkPolicy: Enable/Disable Cilium // Clusterwide Network Policy for the cluster. DesiredEnableCiliumClusterwideNetworkPolicy bool `json:"desiredEnableCiliumClusterwideNetworkPolicy,omitempty"` - - // DesiredEnableFqdnNetworkPolicy: Enable/Disable FQDN Network Policy - // for the cluster. + // DesiredEnableFqdnNetworkPolicy: Enable/Disable FQDN Network Policy for the + // cluster. DesiredEnableFqdnNetworkPolicy bool `json:"desiredEnableFqdnNetworkPolicy,omitempty"` - // DesiredEnableMultiNetworking: Enable/Disable Multi-Networking for the // cluster DesiredEnableMultiNetworking bool `json:"desiredEnableMultiNetworking,omitempty"` - // DesiredEnablePrivateEndpoint: Enable/Disable private endpoint for the // cluster's master. DesiredEnablePrivateEndpoint bool `json:"desiredEnablePrivateEndpoint,omitempty"` - // DesiredFleet: The desired fleet configuration for the cluster. DesiredFleet *Fleet `json:"desiredFleet,omitempty"` - - // DesiredGatewayApiConfig: The desired config of Gateway API on this - // cluster. + // DesiredGatewayApiConfig: The desired config of Gateway API on this cluster. DesiredGatewayApiConfig *GatewayAPIConfig `json:"desiredGatewayApiConfig,omitempty"` - // DesiredGcfsConfig: The desired GCFS config for the cluster. DesiredGcfsConfig *GcfsConfig `json:"desiredGcfsConfig,omitempty"` - - // DesiredHostMaintenancePolicy: HostMaintenancePolicy contains the - // desired maintenance policy for the Google Compute Engine hosts. + // DesiredHostMaintenancePolicy: HostMaintenancePolicy contains the desired + // maintenance policy for the Google Compute Engine hosts. DesiredHostMaintenancePolicy *HostMaintenancePolicy `json:"desiredHostMaintenancePolicy,omitempty"` - // DesiredIdentityServiceConfig: The desired Identity Service component // configuration. DesiredIdentityServiceConfig *IdentityServiceConfig `json:"desiredIdentityServiceConfig,omitempty"` - - // DesiredImageType: The desired image type for the node pool. NOTE: Set - // the "desired_node_pool" field as well. + // DesiredImageType: The desired image type for the node pool. NOTE: Set the + // "desired_node_pool" field as well. DesiredImageType string `json:"desiredImageType,omitempty"` - // DesiredInTransitEncryptionConfig: Specify the details of in-transit - // encryption. + // encryption. Now named inter-node transparent encryption. // // Possible values: - // "IN_TRANSIT_ENCRYPTION_CONFIG_UNSPECIFIED" - Unspecified, will be - // inferred as default - IN_TRANSIT_ENCRYPTION_UNSPECIFIED. - // "IN_TRANSIT_ENCRYPTION_DISABLED" - In-transit encryption is - // disabled. + // "IN_TRANSIT_ENCRYPTION_CONFIG_UNSPECIFIED" - Unspecified, will be inferred + // as default - IN_TRANSIT_ENCRYPTION_UNSPECIFIED. + // "IN_TRANSIT_ENCRYPTION_DISABLED" - In-transit encryption is disabled. // "IN_TRANSIT_ENCRYPTION_INTER_NODE_TRANSPARENT" - Data in-transit is // encrypted using inter-node transparent encryption. DesiredInTransitEncryptionConfig string `json:"desiredInTransitEncryptionConfig,omitempty"` - // DesiredIntraNodeVisibilityConfig: The desired config of Intra-node // visibility. DesiredIntraNodeVisibilityConfig *IntraNodeVisibilityConfig `json:"desiredIntraNodeVisibilityConfig,omitempty"` - // DesiredK8sBetaApis: Beta APIs enabled for cluster. DesiredK8sBetaApis *K8sBetaAPIConfig `json:"desiredK8sBetaApis,omitempty"` - // DesiredL4ilbSubsettingConfig: The desired L4 Internal Load Balancer // Subsetting configuration. DesiredL4ilbSubsettingConfig *ILBSubsettingConfig `json:"desiredL4ilbSubsettingConfig,omitempty"` - // DesiredLocations: The desired list of Google Compute Engine zones // (https://cloud.google.com/compute/docs/zones#available) in which the // cluster's nodes should be located. This list must always include the - // cluster's primary zone. Warning: changing cluster locations will - // update the locations of all node pools and will result in nodes being - // added and/or removed. + // cluster's primary zone. Warning: changing cluster locations will update the + // locations of all node pools and will result in nodes being added and/or + // removed. DesiredLocations []string `json:"desiredLocations,omitempty"` - // DesiredLoggingConfig: The desired logging configuration. DesiredLoggingConfig *LoggingConfig `json:"desiredLoggingConfig,omitempty"` - - // DesiredLoggingService: The logging service the cluster should use to - // write logs. Currently available options: * - // `logging.googleapis.com/kubernetes` - The Cloud Logging service with - // a Kubernetes-native resource model * `logging.googleapis.com` - The - // legacy Cloud Logging service (no longer available as of GKE 1.15). * - // `none` - no logs will be exported from the cluster. If left as an - // empty string,`logging.googleapis.com/kubernetes` will be used for GKE - // 1.14+ or `logging.googleapis.com` for earlier versions. + // DesiredLoggingService: The logging service the cluster should use to write + // logs. Currently available options: * `logging.googleapis.com/kubernetes` - + // The Cloud Logging service with a Kubernetes-native resource model * + // `logging.googleapis.com` - The legacy Cloud Logging service (no longer + // available as of GKE 1.15). * `none` - no logs will be exported from the + // cluster. If left as an empty string,`logging.googleapis.com/kubernetes` will + // be used for GKE 1.14+ or `logging.googleapis.com` for earlier versions. DesiredLoggingService string `json:"desiredLoggingService,omitempty"` - // DesiredMaster: Configuration for master components. DesiredMaster *Master `json:"desiredMaster,omitempty"` - - // DesiredMasterAuthorizedNetworksConfig: The desired configuration - // options for master authorized networks feature. + // DesiredMasterAuthorizedNetworksConfig: The desired configuration options for + // master authorized networks feature. DesiredMasterAuthorizedNetworksConfig *MasterAuthorizedNetworksConfig `json:"desiredMasterAuthorizedNetworksConfig,omitempty"` - - // DesiredMasterVersion: The Kubernetes version to change the master to. - // The only valid value is the latest supported version. Users may - // specify either explicit versions offered by Kubernetes Engine or - // version aliases, which have the following behavior: - "latest": picks - // the highest valid Kubernetes version - "1.X": picks the highest valid - // patch+gke.N patch in the 1.X version - "1.X.Y": picks the highest - // valid gke.N patch in the 1.X.Y version - "1.X.Y-gke.N": picks an - // explicit Kubernetes version - "-": picks the default Kubernetes - // version + // DesiredMasterVersion: The Kubernetes version to change the master to. The + // only valid value is the latest supported version. Users may specify either + // explicit versions offered by Kubernetes Engine or version aliases, which + // have the following behavior: - "latest": picks the highest valid Kubernetes + // version - "1.X": picks the highest valid patch+gke.N patch in the 1.X + // version - "1.X.Y": picks the highest valid gke.N patch in the 1.X.Y version + // - "1.X.Y-gke.N": picks an explicit Kubernetes version - "-": picks the + // default Kubernetes version DesiredMasterVersion string `json:"desiredMasterVersion,omitempty"` - // DesiredMeshCertificates: Configuration for issuance of mTLS keys and // certificates to Kubernetes pods. DesiredMeshCertificates *MeshCertificates `json:"desiredMeshCertificates,omitempty"` - // DesiredMonitoringConfig: The desired monitoring configuration. DesiredMonitoringConfig *MonitoringConfig `json:"desiredMonitoringConfig,omitempty"` - - // DesiredMonitoringService: The monitoring service the cluster should - // use to write metrics. Currently available options: * - // "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service - // with a Kubernetes-native resource model * `monitoring.googleapis.com` - // - The legacy Cloud Monitoring service (no longer available as of GKE - // 1.15). * `none` - No metrics will be exported from the cluster. If - // left as an empty string,`monitoring.googleapis.com/kubernetes` will - // be used for GKE 1.14+ or `monitoring.googleapis.com` for earlier - // versions. + // DesiredMonitoringService: The monitoring service the cluster should use to + // write metrics. Currently available options: * + // "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service with a + // Kubernetes-native resource model * `monitoring.googleapis.com` - The legacy + // Cloud Monitoring service (no longer available as of GKE 1.15). * `none` - No + // metrics will be exported from the cluster. If left as an empty + // string,`monitoring.googleapis.com/kubernetes` will be used for GKE 1.14+ or + // `monitoring.googleapis.com` for earlier versions. DesiredMonitoringService string `json:"desiredMonitoringService,omitempty"` - - // DesiredNetworkPerformanceConfig: The desired network performance - // config. + // DesiredNetworkPerformanceConfig: The desired network performance config. DesiredNetworkPerformanceConfig *ClusterNetworkPerformanceConfig `json:"desiredNetworkPerformanceConfig,omitempty"` - - // DesiredNodePoolAutoConfigNetworkTags: The desired network tags that - // apply to all auto-provisioned node pools in autopilot clusters and - // node auto-provisioning enabled clusters. + // DesiredNodePoolAutoConfigNetworkTags: The desired network tags that apply to + // all auto-provisioned node pools in autopilot clusters and node + // auto-provisioning enabled clusters. DesiredNodePoolAutoConfigNetworkTags *NetworkTags `json:"desiredNodePoolAutoConfigNetworkTags,omitempty"` - - // DesiredNodePoolAutoConfigResourceManagerTags: The desired resource - // manager tags that apply to all auto-provisioned node pools in - // autopilot clusters and node auto-provisioning enabled clusters. + // DesiredNodePoolAutoConfigResourceManagerTags: The desired resource manager + // tags that apply to all auto-provisioned node pools in autopilot clusters and + // node auto-provisioning enabled clusters. DesiredNodePoolAutoConfigResourceManagerTags *ResourceManagerTags `json:"desiredNodePoolAutoConfigResourceManagerTags,omitempty"` - - // DesiredNodePoolAutoscaling: Autoscaler configuration for the node - // pool specified in desired_node_pool_id. If there is only one pool in - // the cluster and desired_node_pool_id is not provided then the change - // applies to that single node pool. + // DesiredNodePoolAutoscaling: Autoscaler configuration for the node pool + // specified in desired_node_pool_id. If there is only one pool in the cluster + // and desired_node_pool_id is not provided then the change applies to that + // single node pool. DesiredNodePoolAutoscaling *NodePoolAutoscaling `json:"desiredNodePoolAutoscaling,omitempty"` - - // DesiredNodePoolId: The node pool to be upgraded. This field is - // mandatory if "desired_node_version", "desired_image_family", - // "desired_node_pool_autoscaling", or - // "desired_workload_metadata_config" is specified and there is more - // than one node pool on the cluster. + // DesiredNodePoolId: The node pool to be upgraded. This field is mandatory if + // "desired_node_version", "desired_image_family", + // "desired_node_pool_autoscaling", or "desired_workload_metadata_config" is + // specified and there is more than one node pool on the cluster. DesiredNodePoolId string `json:"desiredNodePoolId,omitempty"` - - // DesiredNodePoolLoggingConfig: The desired node pool logging - // configuration defaults for the cluster. + // DesiredNodePoolLoggingConfig: The desired node pool logging configuration + // defaults for the cluster. DesiredNodePoolLoggingConfig *NodePoolLoggingConfig `json:"desiredNodePoolLoggingConfig,omitempty"` - - // DesiredNodeVersion: The Kubernetes version to change the nodes to - // (typically an upgrade). Users may specify either explicit versions - // offered by Kubernetes Engine or version aliases, which have the - // following behavior: - "latest": picks the highest valid Kubernetes - // version - "1.X": picks the highest valid patch+gke.N patch in the 1.X - // version - "1.X.Y": picks the highest valid gke.N patch in the 1.X.Y - // version - "1.X.Y-gke.N": picks an explicit Kubernetes version - "-": - // picks the Kubernetes master version + // DesiredNodeVersion: The Kubernetes version to change the nodes to (typically + // an upgrade). Users may specify either explicit versions offered by + // Kubernetes Engine or version aliases, which have the following behavior: - + // "latest": picks the highest valid Kubernetes version - "1.X": picks the + // highest valid patch+gke.N patch in the 1.X version - "1.X.Y": picks the + // highest valid gke.N patch in the 1.X.Y version - "1.X.Y-gke.N": picks an + // explicit Kubernetes version - "-": picks the Kubernetes master version DesiredNodeVersion string `json:"desiredNodeVersion,omitempty"` - // DesiredNotificationConfig: The desired notification configuration. DesiredNotificationConfig *NotificationConfig `json:"desiredNotificationConfig,omitempty"` - // DesiredParentProductConfig: The desired parent product config for the // cluster. DesiredParentProductConfig *ParentProductConfig `json:"desiredParentProductConfig,omitempty"` - - // DesiredPodSecurityPolicyConfig: The desired configuration options for - // the PodSecurityPolicy feature. + // DesiredPodSecurityPolicyConfig: The desired configuration options for the + // PodSecurityPolicy feature. DesiredPodSecurityPolicyConfig *PodSecurityPolicyConfig `json:"desiredPodSecurityPolicyConfig,omitempty"` - - // DesiredPrivateClusterConfig: The desired private cluster - // configuration. master_global_access_config is the only field that can - // be changed via this field. See also - // ClusterUpdate.desired_enable_private_endpoint for modifying other - // fields within PrivateClusterConfig. + // DesiredPrivateClusterConfig: The desired private cluster configuration. + // master_global_access_config is the only field that can be changed via this + // field. See also ClusterUpdate.desired_enable_private_endpoint for modifying + // other fields within PrivateClusterConfig. DesiredPrivateClusterConfig *PrivateClusterConfig `json:"desiredPrivateClusterConfig,omitempty"` - - // DesiredPrivateIpv6GoogleAccess: The desired state of IPv6 - // connectivity to Google Services. + // DesiredPrivateIpv6GoogleAccess: The desired state of IPv6 connectivity to + // Google Services. // // Possible values: - // "PRIVATE_IPV6_GOOGLE_ACCESS_UNSPECIFIED" - Default value. Same as - // DISABLED - // "PRIVATE_IPV6_GOOGLE_ACCESS_DISABLED" - No private access to or - // from Google Services - // "PRIVATE_IPV6_GOOGLE_ACCESS_TO_GOOGLE" - Enables private IPv6 - // access to Google Services from GKE - // "PRIVATE_IPV6_GOOGLE_ACCESS_BIDIRECTIONAL" - Enables private IPv6 - // access to and from Google Services + // "PRIVATE_IPV6_GOOGLE_ACCESS_UNSPECIFIED" - Default value. Same as DISABLED + // "PRIVATE_IPV6_GOOGLE_ACCESS_DISABLED" - No private access to or from + // Google Services + // "PRIVATE_IPV6_GOOGLE_ACCESS_TO_GOOGLE" - Enables private IPv6 access to + // Google Services from GKE + // "PRIVATE_IPV6_GOOGLE_ACCESS_BIDIRECTIONAL" - Enables private IPv6 access + // to and from Google Services DesiredPrivateIpv6GoogleAccess string `json:"desiredPrivateIpv6GoogleAccess,omitempty"` - - // DesiredProtectConfig: Deprecated: Use DesiredSecurityPostureConfig - // instead. Enable/Disable Protect API features for the cluster. + // DesiredProtectConfig: Deprecated: Use DesiredSecurityPostureConfig instead. + // Enable/Disable Protect API features for the cluster. DesiredProtectConfig *ProtectConfig `json:"desiredProtectConfig,omitempty"` - // DesiredReleaseChannel: The desired release channel configuration. DesiredReleaseChannel *ReleaseChannel `json:"desiredReleaseChannel,omitempty"` - - // DesiredResourceUsageExportConfig: The desired configuration for - // exporting resource usage. + // DesiredResourceUsageExportConfig: The desired configuration for exporting + // resource usage. DesiredResourceUsageExportConfig *ResourceUsageExportConfig `json:"desiredResourceUsageExportConfig,omitempty"` - // DesiredSecretManagerConfig: Enable/Disable Secret Manager Config. DesiredSecretManagerConfig *SecretManagerConfig `json:"desiredSecretManagerConfig,omitempty"` - - // DesiredSecurityPostureConfig: Enable/Disable Security Posture API - // features for the cluster. + // DesiredSecurityPostureConfig: Enable/Disable Security Posture API features + // for the cluster. DesiredSecurityPostureConfig *SecurityPostureConfig `json:"desiredSecurityPostureConfig,omitempty"` - - // DesiredServiceExternalIpsConfig: ServiceExternalIPsConfig specifies - // the config for the use of Services with ExternalIPs field. + // DesiredServiceExternalIpsConfig: ServiceExternalIPsConfig specifies the + // config for the use of Services with ExternalIPs field. DesiredServiceExternalIpsConfig *ServiceExternalIPsConfig `json:"desiredServiceExternalIpsConfig,omitempty"` - // DesiredShieldedNodes: Configuration for Shielded Nodes. DesiredShieldedNodes *ShieldedNodes `json:"desiredShieldedNodes,omitempty"` - - // DesiredStackType: The desired stack type of the cluster. If a stack - // type is provided and does not match the current stack type of the - // cluster, update will attempt to change the stack type to the new - // type. + // DesiredStackType: The desired stack type of the cluster. If a stack type is + // provided and does not match the current stack type of the cluster, update + // will attempt to change the stack type to the new type. // // Possible values: - // "STACK_TYPE_UNSPECIFIED" - By default, the clusters will be IPV4 - // only + // "STACK_TYPE_UNSPECIFIED" - By default, the clusters will be IPV4 only // "IPV4" - The value used if the cluster is a IPV4 only // "IPV4_IPV6" - The value used if the cluster is a dual stack cluster DesiredStackType string `json:"desiredStackType,omitempty"` - // DesiredTpuConfig: The desired Cloud TPU configuration. DesiredTpuConfig *TpuConfig `json:"desiredTpuConfig,omitempty"` - // DesiredVerticalPodAutoscaling: Cluster-level Vertical Pod Autoscaling // configuration. DesiredVerticalPodAutoscaling *VerticalPodAutoscaling `json:"desiredVerticalPodAutoscaling,omitempty"` - - // DesiredWorkloadAltsConfig: Configuration for direct-path (via ALTS) - // with workload identity. + // DesiredWorkloadAltsConfig: Configuration for direct-path (via ALTS) with + // workload identity. DesiredWorkloadAltsConfig *WorkloadALTSConfig `json:"desiredWorkloadAltsConfig,omitempty"` - - // DesiredWorkloadCertificates: Configuration for issuance of mTLS keys - // and certificates to Kubernetes pods. + // DesiredWorkloadCertificates: Configuration for issuance of mTLS keys and + // certificates to Kubernetes pods. DesiredWorkloadCertificates *WorkloadCertificates `json:"desiredWorkloadCertificates,omitempty"` - // DesiredWorkloadIdentityConfig: Configuration for Workload Identity. DesiredWorkloadIdentityConfig *WorkloadIdentityConfig `json:"desiredWorkloadIdentityConfig,omitempty"` - - // EnableK8sBetaApis: Kubernetes open source beta apis enabled on the - // cluster. Only beta apis + // EnableK8sBetaApis: Kubernetes open source beta apis enabled on the cluster. + // Only beta apis EnableK8sBetaApis *K8sBetaAPIConfig `json:"enableK8sBetaApis,omitempty"` - - // Etag: The current etag of the cluster. If an etag is provided and - // does not match the current etag of the cluster, update will be - // blocked and an ABORTED error will be returned. + // Etag: The current etag of the cluster. If an etag is provided and does not + // match the current etag of the cluster, update will be blocked and an ABORTED + // error will be returned. Etag string `json:"etag,omitempty"` - - // PrivateClusterConfig: The desired private cluster configuration. Has - // no effect. Use desired_private_cluster_config instead. + // PrivateClusterConfig: The desired private cluster configuration. Has no + // effect. Use desired_private_cluster_config instead. PrivateClusterConfig *PrivateClusterConfig `json:"privateClusterConfig,omitempty"` - - // RemovedAdditionalPodRangesConfig: The additional pod ranges that are - // to be removed from the cluster. The pod ranges specified here must - // have been specified earlier in the 'additional_pod_ranges_config' - // argument. + // RemovedAdditionalPodRangesConfig: The additional pod ranges that are to be + // removed from the cluster. The pod ranges specified here must have been + // specified earlier in the 'additional_pod_ranges_config' argument. RemovedAdditionalPodRangesConfig *AdditionalPodRangesConfig `json:"removedAdditionalPodRangesConfig,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AdditionalPodRangesConfig") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AdditionalPodRangesConfig") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "AdditionalPodRangesConfig") to include in API requests with the JSON - // null value. By default, fields with empty values are omitted from API - // requests. However, any field with an empty value appearing in - // NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "AdditionalPodRangesConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ClusterUpdate) MarshalJSON() ([]byte, error) { type NoMethod ClusterUpdate - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// CompleteIPRotationRequest: CompleteIPRotationRequest moves the -// cluster master back into single-IP mode. +// CompleteIPRotationRequest: CompleteIPRotationRequest moves the cluster +// master back into single-IP mode. type CompleteIPRotationRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster. This field - // has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster. This field has + // been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster name) of the cluster to - // complete IP rotation. Specified in the format - // `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster name) of the cluster to complete + // IP rotation. Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CompleteIPRotationRequest) MarshalJSON() ([]byte, error) { type NoMethod CompleteIPRotationRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// CompleteNodePoolUpgradeRequest: CompleteNodePoolUpgradeRequest sets -// the name of target node pool to complete upgrade. +// CompleteNodePoolUpgradeRequest: CompleteNodePoolUpgradeRequest sets the name +// of target node pool to complete upgrade. type CompleteNodePoolUpgradeRequest struct { } -// CompliancePostureConfig: CompliancePostureConfig defines the settings -// needed to enable/disable features for the Compliance Posture. +// CompliancePostureConfig: CompliancePostureConfig defines the settings needed +// to enable/disable features for the Compliance Posture. type CompliancePostureConfig struct { // ComplianceStandards: List of enabled compliance standards. ComplianceStandards []*ComplianceStandard `json:"complianceStandards,omitempty"` - // Mode: Defines the enablement mode for Compliance Posture. // // Possible values: @@ -2379,87 +1887,67 @@ type CompliancePostureConfig struct { // "DISABLED" - Disables Compliance Posture features on the cluster. // "ENABLED" - Enables Compliance Posture features on the cluster. Mode string `json:"mode,omitempty"` - - // ForceSendFields is a list of field names (e.g. "ComplianceStandards") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "ComplianceStandards") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ComplianceStandards") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ComplianceStandards") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CompliancePostureConfig) MarshalJSON() ([]byte, error) { type NoMethod CompliancePostureConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ComplianceStandard: Defines the details of a compliance standard. type ComplianceStandard struct { // Standard: Name of the compliance standard. Standard string `json:"standard,omitempty"` - // ForceSendFields is a list of field names (e.g. "Standard") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Standard") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Standard") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ComplianceStandard) MarshalJSON() ([]byte, error) { type NoMethod ComplianceStandard - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ConfidentialNodes: ConfidentialNodes is configuration for the -// confidential nodes feature, which makes nodes run on confidential -// VMs. +// ConfidentialNodes: ConfidentialNodes is configuration for the confidential +// nodes feature, which makes nodes run on confidential VMs. type ConfidentialNodes struct { // Enabled: Whether Confidential Nodes feature is enabled. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ConfidentialNodes) MarshalJSON() ([]byte, error) { type NoMethod ConfidentialNodes - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ConfigConnectorConfig: Configuration options for the Config Connector @@ -2467,91 +1955,70 @@ func (s *ConfidentialNodes) MarshalJSON() ([]byte, error) { type ConfigConnectorConfig struct { // Enabled: Whether Cloud Connector is enabled for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ConfigConnectorConfig) MarshalJSON() ([]byte, error) { type NoMethod ConfigConnectorConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ConsumptionMeteringConfig: Parameters for controlling consumption -// metering. +// ConsumptionMeteringConfig: Parameters for controlling consumption metering. type ConsumptionMeteringConfig struct { // Enabled: Whether to enable consumption metering for this cluster. If // enabled, a second BigQuery table will be created to hold resource // consumption records. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ConsumptionMeteringConfig) MarshalJSON() ([]byte, error) { type NoMethod ConsumptionMeteringConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ContainerdConfig: ContainerdConfig contains configuration to -// customize containerd. +// ContainerdConfig: ContainerdConfig contains configuration to customize +// containerd. type ContainerdConfig struct { // PrivateRegistryAccessConfig: PrivateRegistryAccessConfig is used to // configure access configuration for private container registries. PrivateRegistryAccessConfig *PrivateRegistryAccessConfig `json:"privateRegistryAccessConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "PrivateRegistryAccessConfig") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // "PrivateRegistryAccessConfig") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields + // for more details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "PrivateRegistryAccessConfig") to include in API requests with the - // JSON null value. By default, fields with empty values are omitted - // from API requests. However, any field with an empty value appearing - // in NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "PrivateRegistryAccessConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ContainerdConfig) MarshalJSON() ([]byte, error) { type NoMethod ContainerdConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // CostManagementConfig: Configuration for fine-grained cost management @@ -2559,28 +2026,22 @@ func (s *ContainerdConfig) MarshalJSON() ([]byte, error) { type CostManagementConfig struct { // Enabled: Whether the feature is enabled or not. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CostManagementConfig) MarshalJSON() ([]byte, error) { type NoMethod CostManagementConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // CreateClusterRequest: CreateClusterRequest creates a cluster. @@ -2588,105 +2049,82 @@ type CreateClusterRequest struct { // Cluster: Required. A cluster resource // (https://cloud.google.com/container-engine/reference/rest/v1beta1/projects.locations.clusters) Cluster *Cluster `json:"cluster,omitempty"` - - // Parent: The parent (project and location) where the cluster will be - // created. Specified in the format `projects/*/locations/*`. + // Parent: The parent (project and location) where the cluster will be created. + // Specified in the format `projects/*/locations/*`. Parent string `json:"parent,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the parent field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the parent field. Zone string `json:"zone,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Cluster") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Cluster") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Cluster") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Cluster") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CreateClusterRequest) MarshalJSON() ([]byte, error) { type NoMethod CreateClusterRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// CreateNodePoolRequest: CreateNodePoolRequest creates a node pool for -// a cluster. +// CreateNodePoolRequest: CreateNodePoolRequest creates a node pool for a +// cluster. type CreateNodePoolRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster. This field - // has been deprecated and replaced by the parent field. + // ClusterId: Required. Deprecated. The name of the cluster. This field has + // been deprecated and replaced by the parent field. ClusterId string `json:"clusterId,omitempty"` - // NodePool: Required. The node pool to create. NodePool *NodePool `json:"nodePool,omitempty"` - - // Parent: The parent (project, location, cluster name) where the node - // pool will be created. Specified in the format + // Parent: The parent (project, location, cluster name) where the node pool + // will be created. Specified in the format // `projects/*/locations/*/clusters/*`. Parent string `json:"parent,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the parent field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the parent field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *CreateNodePoolRequest) MarshalJSON() ([]byte, error) { type NoMethod CreateNodePoolRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// DNSConfig: DNSConfig contains the desired set of options for -// configuring clusterDNS. +// DNSConfig: DNSConfig contains the desired set of options for configuring +// clusterDNS. type DNSConfig struct { - // AdditiveVpcScopeDnsDomain: Optional. The domain used in Additive VPC - // scope. + // AdditiveVpcScopeDnsDomain: Optional. The domain used in Additive VPC scope. AdditiveVpcScopeDnsDomain string `json:"additiveVpcScopeDnsDomain,omitempty"` - - // ClusterDns: cluster_dns indicates which in-cluster DNS provider - // should be used. + // ClusterDns: cluster_dns indicates which in-cluster DNS provider should be + // used. // // Possible values: // "PROVIDER_UNSPECIFIED" - Default value @@ -2695,80 +2133,62 @@ type DNSConfig struct { // "CLOUD_DNS" - Use CloudDNS for DNS resolution. // "KUBE_DNS" - Use KubeDNS for DNS resolution. ClusterDns string `json:"clusterDns,omitempty"` - - // ClusterDnsDomain: cluster_dns_domain is the suffix used for all - // cluster service records. + // ClusterDnsDomain: cluster_dns_domain is the suffix used for all cluster + // service records. ClusterDnsDomain string `json:"clusterDnsDomain,omitempty"` - - // ClusterDnsScope: cluster_dns_scope indicates the scope of access to - // cluster DNS records. + // ClusterDnsScope: cluster_dns_scope indicates the scope of access to cluster + // DNS records. // // Possible values: - // "DNS_SCOPE_UNSPECIFIED" - Default value, will be inferred as - // cluster scope. - // "CLUSTER_SCOPE" - DNS records are accessible from within the - // cluster. + // "DNS_SCOPE_UNSPECIFIED" - Default value, will be inferred as cluster + // scope. + // "CLUSTER_SCOPE" - DNS records are accessible from within the cluster. // "VPC_SCOPE" - DNS records are accessible from within the VPC. ClusterDnsScope string `json:"clusterDnsScope,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AdditiveVpcScopeDnsDomain") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AdditiveVpcScopeDnsDomain") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "AdditiveVpcScopeDnsDomain") to include in API requests with the JSON - // null value. By default, fields with empty values are omitted from API - // requests. However, any field with an empty value appearing in - // NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "AdditiveVpcScopeDnsDomain") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *DNSConfig) MarshalJSON() ([]byte, error) { type NoMethod DNSConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // DailyMaintenanceWindow: Time window specified for daily maintenance // operations. type DailyMaintenanceWindow struct { - // Duration: [Output only] Duration of the time window, automatically - // chosen to be smallest possible in the given scenario. + // Duration: [Output only] Duration of the time window, automatically chosen to + // be smallest possible in the given scenario. Duration string `json:"duration,omitempty"` - - // StartTime: Time within the maintenance window to start the - // maintenance operations. It must be in format "HH:MM", where HH : - // [00-23] and MM : [00-59] GMT. + // StartTime: Time within the maintenance window to start the maintenance + // operations. It must be in format "HH:MM", where HH : [00-23] and MM : + // [00-59] GMT. StartTime string `json:"startTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Duration") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Duration") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Duration") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *DailyMaintenanceWindow) MarshalJSON() ([]byte, error) { type NoMethod DailyMaintenanceWindow - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // DatabaseEncryption: Configuration of etcd encryption. @@ -2778,340 +2198,273 @@ type DatabaseEncryption struct { // Possible values: // "CURRENT_STATE_UNSPECIFIED" - Should never be set // "CURRENT_STATE_ENCRYPTED" - Secrets in etcd are encrypted. - // "CURRENT_STATE_DECRYPTED" - Secrets in etcd are stored in plain - // text (at etcd level) - this is unrelated to Compute Engine level full - // disk encryption. - // "CURRENT_STATE_ENCRYPTION_PENDING" - Encryption (or re-encryption - // with a different CloudKMS key) of Secrets is in progress. - // "CURRENT_STATE_ENCRYPTION_ERROR" - Encryption (or re-encryption - // with a different CloudKMS key) of Secrets in etcd encountered an - // error. - // "CURRENT_STATE_DECRYPTION_PENDING" - De-crypting Secrets to plain - // text in etcd is in progress. - // "CURRENT_STATE_DECRYPTION_ERROR" - De-crypting Secrets to plain - // text in etcd encountered an error. + // "CURRENT_STATE_DECRYPTED" - Secrets in etcd are stored in plain text (at + // etcd level) - this is unrelated to Compute Engine level full disk + // encryption. + // "CURRENT_STATE_ENCRYPTION_PENDING" - Encryption (or re-encryption with a + // different CloudKMS key) of Secrets is in progress. + // "CURRENT_STATE_ENCRYPTION_ERROR" - Encryption (or re-encryption with a + // different CloudKMS key) of Secrets in etcd encountered an error. + // "CURRENT_STATE_DECRYPTION_PENDING" - De-crypting Secrets to plain text in + // etcd is in progress. + // "CURRENT_STATE_DECRYPTION_ERROR" - De-crypting Secrets to plain text in + // etcd encountered an error. CurrentState string `json:"currentState,omitempty"` - - // DecryptionKeys: Output only. Keys in use by the cluster for - // decrypting existing objects, in addition to the key in `key_name`. - // Each item is a CloudKMS key resource. + // DecryptionKeys: Output only. Keys in use by the cluster for decrypting + // existing objects, in addition to the key in `key_name`. Each item is a + // CloudKMS key resource. DecryptionKeys []string `json:"decryptionKeys,omitempty"` - - // KeyName: Name of CloudKMS key to use for the encryption of secrets in - // etcd. Ex. - // projects/my-project/locations/global/keyRings/my-ring/cryptoKeys/my-ke - // y + // KeyName: Name of CloudKMS key to use for the encryption of secrets in etcd. + // Ex. projects/my-project/locations/global/keyRings/my-ring/cryptoKeys/my-key KeyName string `json:"keyName,omitempty"` - // LastOperationErrors: Output only. Records errors seen during // DatabaseEncryption update operations. LastOperationErrors []*OperationError `json:"lastOperationErrors,omitempty"` - // State: The desired state of etcd encryption. // // Possible values: // "UNKNOWN" - Should never be set // "ENCRYPTED" - Secrets in etcd are encrypted. - // "DECRYPTED" - Secrets in etcd are stored in plain text (at etcd - // level) - this is unrelated to Compute Engine level full disk - // encryption. + // "DECRYPTED" - Secrets in etcd are stored in plain text (at etcd level) - + // this is unrelated to Compute Engine level full disk encryption. State string `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. "CurrentState") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CurrentState") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CurrentState") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *DatabaseEncryption) MarshalJSON() ([]byte, error) { type NoMethod DatabaseEncryption - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// Date: Represents a whole or partial calendar date, such as a -// birthday. The time of day and time zone are either specified -// elsewhere or are insignificant. The date is relative to the Gregorian -// Calendar. This can represent one of the following: * A full date, -// with non-zero year, month, and day values. * A month and day, with a -// zero year (for example, an anniversary). * A year on its own, with a -// zero month and a zero day. * A year and month, with a zero day (for -// example, a credit card expiration date). Related types: * -// google.type.TimeOfDay * google.type.DateTime * + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Date: Represents a whole or partial calendar date, such as a birthday. The +// time of day and time zone are either specified elsewhere or are +// insignificant. The date is relative to the Gregorian Calendar. This can +// represent one of the following: * A full date, with non-zero year, month, +// and day values. * A month and day, with a zero year (for example, an +// anniversary). * A year on its own, with a zero month and a zero day. * A +// year and month, with a zero day (for example, a credit card expiration +// date). Related types: * google.type.TimeOfDay * google.type.DateTime * // google.protobuf.Timestamp type Date struct { - // Day: Day of a month. Must be from 1 to 31 and valid for the year and - // month, or 0 to specify a year by itself or a year and month where the - // day isn't significant. + // Day: Day of a month. Must be from 1 to 31 and valid for the year and month, + // or 0 to specify a year by itself or a year and month where the day isn't + // significant. Day int64 `json:"day,omitempty"` - - // Month: Month of a year. Must be from 1 to 12, or 0 to specify a year - // without a month and day. + // Month: Month of a year. Must be from 1 to 12, or 0 to specify a year without + // a month and day. Month int64 `json:"month,omitempty"` - - // Year: Year of the date. Must be from 1 to 9999, or 0 to specify a - // date without a year. + // Year: Year of the date. Must be from 1 to 9999, or 0 to specify a date + // without a year. Year int64 `json:"year,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Day") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Day") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Day") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Day") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Date) MarshalJSON() ([]byte, error) { type NoMethod Date - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// DefaultSnatStatus: DefaultSnatStatus contains the desired state of -// whether default sNAT should be disabled on the cluster. +// DefaultSnatStatus: DefaultSnatStatus contains the desired state of whether +// default sNAT should be disabled on the cluster. type DefaultSnatStatus struct { // Disabled: Disables cluster default sNAT rules. Disabled bool `json:"disabled,omitempty"` - // ForceSendFields is a list of field names (e.g. "Disabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *DefaultSnatStatus) MarshalJSON() ([]byte, error) { type NoMethod DefaultSnatStatus - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // DnsCacheConfig: Configuration for NodeLocal DNSCache type DnsCacheConfig struct { // Enabled: Whether NodeLocal DNSCache is enabled for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *DnsCacheConfig) MarshalJSON() ([]byte, error) { type NoMethod DnsCacheConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Empty: A generic empty message that you can re-use to avoid defining -// duplicated empty messages in your APIs. A typical example is to use -// it as the request or the response type of an API method. For -// instance: service Foo { rpc Bar(google.protobuf.Empty) returns -// (google.protobuf.Empty); } +// duplicated empty messages in your APIs. A typical example is to use it as +// the request or the response type of an API method. For instance: service Foo +// { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } type Empty struct { - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` } -// EnterpriseConfig: EnterpriseConfig is the cluster enterprise -// configuration. +// EnterpriseConfig: EnterpriseConfig is the cluster enterprise configuration. type EnterpriseConfig struct { - // ClusterTier: Output only. [Output only] cluster_tier specifies the - // premium tier of the cluster. + // ClusterTier: Output only. [Output only] cluster_tier specifies the premium + // tier of the cluster. // // Possible values: - // "CLUSTER_TIER_UNSPECIFIED" - CLUSTER_TIER_UNSPECIFIED is when - // cluster_tier is not set. + // "CLUSTER_TIER_UNSPECIFIED" - CLUSTER_TIER_UNSPECIFIED is when cluster_tier + // is not set. // "STANDARD" - STANDARD indicates a standard GKE cluster. // "ENTERPRISE" - ENTERPRISE indicates a GKE Enterprise cluster. ClusterTier string `json:"clusterTier,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterTier") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterTier") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterTier") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *EnterpriseConfig) MarshalJSON() ([]byte, error) { type NoMethod EnterpriseConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// EphemeralStorageConfig: EphemeralStorageConfig contains configuration -// for the ephemeral storage filesystem. +// EphemeralStorageConfig: EphemeralStorageConfig contains configuration for +// the ephemeral storage filesystem. type EphemeralStorageConfig struct { - // LocalSsdCount: Number of local SSDs to use to back ephemeral storage. - // Uses NVMe interfaces. The limit for this value is dependent upon the - // maximum number of disk available on a machine per zone. See: - // https://cloud.google.com/compute/docs/disks/local-ssd for more - // information. A zero (or unset) value has different meanings depending - // on machine type being used: 1. For pre-Gen3 machines, which support - // flexible numbers of local ssds, zero (or unset) means to disable - // using local SSDs as ephemeral storage. 2. For Gen3 machines which - // dictate a specific number of local ssds, zero (or unset) means to use - // the default number of local ssds that goes with that machine type. - // For example, for a c3-standard-8-lssd machine, 2 local ssds would be - // provisioned. For c3-standard-8 (which doesn't support local ssds), 0 - // will be provisioned. See + // LocalSsdCount: Number of local SSDs to use to back ephemeral storage. Uses + // NVMe interfaces. The limit for this value is dependent upon the maximum + // number of disk available on a machine per zone. See: + // https://cloud.google.com/compute/docs/disks/local-ssd for more information. + // A zero (or unset) value has different meanings depending on machine type + // being used: 1. For pre-Gen3 machines, which support flexible numbers of + // local ssds, zero (or unset) means to disable using local SSDs as ephemeral + // storage. 2. For Gen3 machines which dictate a specific number of local ssds, + // zero (or unset) means to use the default number of local ssds that goes with + // that machine type. For example, for a c3-standard-8-lssd machine, 2 local + // ssds would be provisioned. For c3-standard-8 (which doesn't support local + // ssds), 0 will be provisioned. See // https://cloud.google.com/compute/docs/disks/local-ssd#choose_number_local_ssds // for more info. LocalSsdCount int64 `json:"localSsdCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "LocalSsdCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "LocalSsdCount") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "LocalSsdCount") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *EphemeralStorageConfig) MarshalJSON() ([]byte, error) { type NoMethod EphemeralStorageConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// EphemeralStorageLocalSsdConfig: EphemeralStorageLocalSsdConfig -// contains configuration for the node ephemeral storage using Local -// SSDs. +// EphemeralStorageLocalSsdConfig: EphemeralStorageLocalSsdConfig contains +// configuration for the node ephemeral storage using Local SSDs. type EphemeralStorageLocalSsdConfig struct { - // LocalSsdCount: Number of local SSDs to use to back ephemeral storage. - // Uses NVMe interfaces. A zero (or unset) value has different meanings - // depending on machine type being used: 1. For pre-Gen3 machines, which - // support flexible numbers of local ssds, zero (or unset) means to - // disable using local SSDs as ephemeral storage. The limit for this - // value is dependent upon the maximum number of disk available on a - // machine per zone. See: - // https://cloud.google.com/compute/docs/disks/local-ssd for more - // information. 2. For Gen3 machines which dictate a specific number of - // local ssds, zero (or unset) means to use the default number of local - // ssds that goes with that machine type. For example, for a - // c3-standard-8-lssd machine, 2 local ssds would be provisioned. For - // c3-standard-8 (which doesn't support local ssds), 0 will be - // provisioned. See + // LocalSsdCount: Number of local SSDs to use to back ephemeral storage. Uses + // NVMe interfaces. A zero (or unset) value has different meanings depending on + // machine type being used: 1. For pre-Gen3 machines, which support flexible + // numbers of local ssds, zero (or unset) means to disable using local SSDs as + // ephemeral storage. The limit for this value is dependent upon the maximum + // number of disk available on a machine per zone. See: + // https://cloud.google.com/compute/docs/disks/local-ssd for more information. + // 2. For Gen3 machines which dictate a specific number of local ssds, zero (or + // unset) means to use the default number of local ssds that goes with that + // machine type. For example, for a c3-standard-8-lssd machine, 2 local ssds + // would be provisioned. For c3-standard-8 (which doesn't support local ssds), + // 0 will be provisioned. See // https://cloud.google.com/compute/docs/disks/local-ssd#choose_number_local_ssds // for more info. LocalSsdCount int64 `json:"localSsdCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "LocalSsdCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "LocalSsdCount") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "LocalSsdCount") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *EphemeralStorageLocalSsdConfig) MarshalJSON() ([]byte, error) { type NoMethod EphemeralStorageLocalSsdConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // FastSocket: Configuration of Fast Socket feature. type FastSocket struct { // Enabled: Whether Fast Socket features are enabled in the node pool. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *FastSocket) MarshalJSON() ([]byte, error) { type NoMethod FastSocket - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// Filter: Allows filtering to one or more specific event types. If -// event types are present, those and only those event types will be -// transmitted to the cluster. Other types will be skipped. If no filter -// is specified, or no event types are present, all event types will be -// sent +// Filter: Allows filtering to one or more specific event types. If event types +// are present, those and only those event types will be transmitted to the +// cluster. Other types will be skipped. If no filter is specified, or no event +// types are present, all event types will be sent type Filter struct { // EventType: Event types to allowlist. // @@ -3121,67 +2474,53 @@ type Filter struct { // "UPGRADE_EVENT" - Corresponds with UpgradeEvent. // "SECURITY_BULLETIN_EVENT" - Corresponds with SecurityBulletinEvent. EventType []string `json:"eventType,omitempty"` - // ForceSendFields is a list of field names (e.g. "EventType") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EventType") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EventType") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Filter) MarshalJSON() ([]byte, error) { type NoMethod Filter - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Fleet: Fleet is the fleet configuration for the cluster. type Fleet struct { - // Membership: [Output only] The full resource name of the registered - // fleet membership of the cluster, in the format + // Membership: [Output only] The full resource name of the registered fleet + // membership of the cluster, in the format // `//gkehub.googleapis.com/projects/*/locations/*/memberships/*`. Membership string `json:"membership,omitempty"` - - // PreRegistered: [Output only] Whether the cluster has been registered - // through the fleet API. + // PreRegistered: [Output only] Whether the cluster has been registered through + // the fleet API. PreRegistered bool `json:"preRegistered,omitempty"` - - // Project: The Fleet host project(project ID or project number) where - // this cluster will be registered to. This field cannot be changed - // after the cluster has been registered. + // Project: The Fleet host project(project ID or project number) where this + // cluster will be registered to. This field cannot be changed after the + // cluster has been registered. Project string `json:"project,omitempty"` - // ForceSendFields is a list of field names (e.g. "Membership") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Membership") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Membership") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Fleet) MarshalJSON() ([]byte, error) { type NoMethod Fleet - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // GCPSecretManagerCertificateConfig: GCPSecretManagerCertificateConfig @@ -3189,787 +2528,615 @@ func (s *Fleet) MarshalJSON() ([]byte, error) { // (https://cloud.google.com/secret-manager). type GCPSecretManagerCertificateConfig struct { // SecretUri: Secret URI, in the form - // "projects/$PROJECT_ID/secrets/$SECRET_NAME/versions/$VERSION". - // Version can be fixed (e.g. "2") or "latest" + // "projects/$PROJECT_ID/secrets/$SECRET_NAME/versions/$VERSION". Version can + // be fixed (e.g. "2") or "latest" SecretUri string `json:"secretUri,omitempty"` - // ForceSendFields is a list of field names (e.g. "SecretUri") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "SecretUri") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "SecretUri") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GCPSecretManagerCertificateConfig) MarshalJSON() ([]byte, error) { type NoMethod GCPSecretManagerCertificateConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GPUDriverInstallationConfig: GPUDriverInstallationConfig specifies -// the version of GPU driver to be auto installed. +// GPUDriverInstallationConfig: GPUDriverInstallationConfig specifies the +// version of GPU driver to be auto installed. type GPUDriverInstallationConfig struct { // GpuDriverVersion: Mode for how the GPU driver is installed. // // Possible values: - // "GPU_DRIVER_VERSION_UNSPECIFIED" - Default value is to not install - // any GPU driver. - // "INSTALLATION_DISABLED" - Disable GPU driver auto installation and - // needs manual installation + // "GPU_DRIVER_VERSION_UNSPECIFIED" - Default value is to not install any GPU + // driver. + // "INSTALLATION_DISABLED" - Disable GPU driver auto installation and needs + // manual installation // "DEFAULT" - "Default" GPU driver in COS and Ubuntu. // "LATEST" - "Latest" GPU driver in COS. GpuDriverVersion string `json:"gpuDriverVersion,omitempty"` - // ForceSendFields is a list of field names (e.g. "GpuDriverVersion") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "GpuDriverVersion") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "GpuDriverVersion") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GPUDriverInstallationConfig) MarshalJSON() ([]byte, error) { type NoMethod GPUDriverInstallationConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GPUSharingConfig: GPUSharingConfig represents the GPU sharing -// configuration for Hardware Accelerators. +// GPUSharingConfig: GPUSharingConfig represents the GPU sharing configuration +// for Hardware Accelerators. type GPUSharingConfig struct { - // GpuSharingStrategy: The type of GPU sharing strategy to enable on the - // GPU node. + // GpuSharingStrategy: The type of GPU sharing strategy to enable on the GPU + // node. // // Possible values: // "GPU_SHARING_STRATEGY_UNSPECIFIED" - Default value. // "TIME_SHARING" - GPUs are time-shared between containers. // "MPS" - GPUs are shared between containers with NVIDIA MPS. GpuSharingStrategy string `json:"gpuSharingStrategy,omitempty"` - // MaxSharedClientsPerGpu: The max number of containers that can share a // physical GPU. MaxSharedClientsPerGpu int64 `json:"maxSharedClientsPerGpu,omitempty,string"` - - // ForceSendFields is a list of field names (e.g. "GpuSharingStrategy") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "GpuSharingStrategy") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "GpuSharingStrategy") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "GpuSharingStrategy") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GPUSharingConfig) MarshalJSON() ([]byte, error) { type NoMethod GPUSharingConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GatewayAPIConfig: GatewayAPIConfig contains the desired config of -// Gateway API on this cluster. +// GatewayAPIConfig: GatewayAPIConfig contains the desired config of Gateway +// API on this cluster. type GatewayAPIConfig struct { // Channel: The Gateway API release channel to use for Gateway API. // // Possible values: // "CHANNEL_UNSPECIFIED" - Default value. // "CHANNEL_DISABLED" - Gateway API support is disabled - // "CHANNEL_EXPERIMENTAL" - Gateway API support is enabled, - // experimental CRDs are installed - // "CHANNEL_STANDARD" - Gateway API support is enabled, standard CRDs + // "CHANNEL_EXPERIMENTAL" - Gateway API support is enabled, experimental CRDs // are installed + // "CHANNEL_STANDARD" - Gateway API support is enabled, standard CRDs are + // installed Channel string `json:"channel,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Channel") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Channel") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Channel") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Channel") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GatewayAPIConfig) MarshalJSON() ([]byte, error) { type NoMethod GatewayAPIConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GcePersistentDiskCsiDriverConfig: Configuration for the Compute -// Engine PD CSI driver. +// GcePersistentDiskCsiDriverConfig: Configuration for the Compute Engine PD +// CSI driver. type GcePersistentDiskCsiDriverConfig struct { // Enabled: Whether the Compute Engine PD CSI driver is enabled for this // cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GcePersistentDiskCsiDriverConfig) MarshalJSON() ([]byte, error) { type NoMethod GcePersistentDiskCsiDriverConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GcfsConfig: GcfsConfig contains configurations of Google Container -// File System. +// GcfsConfig: GcfsConfig contains configurations of Google Container File +// System. type GcfsConfig struct { // Enabled: Whether to use GCFS. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GcfsConfig) MarshalJSON() ([]byte, error) { type NoMethod GcfsConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GcpFilestoreCsiDriverConfig: Configuration for the GCP Filestore CSI -// driver. +// GcpFilestoreCsiDriverConfig: Configuration for the GCP Filestore CSI driver. type GcpFilestoreCsiDriverConfig struct { - // Enabled: Whether the GCP Filestore CSI driver is enabled for this - // cluster. + // Enabled: Whether the GCP Filestore CSI driver is enabled for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GcpFilestoreCsiDriverConfig) MarshalJSON() ([]byte, error) { type NoMethod GcpFilestoreCsiDriverConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GcsFuseCsiDriverConfig: Configuration for the Cloud Storage Fuse CSI -// driver. +// GcsFuseCsiDriverConfig: Configuration for the Cloud Storage Fuse CSI driver. type GcsFuseCsiDriverConfig struct { - // Enabled: Whether the Cloud Storage Fuse CSI driver is enabled for - // this cluster. + // Enabled: Whether the Cloud Storage Fuse CSI driver is enabled for this + // cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GcsFuseCsiDriverConfig) MarshalJSON() ([]byte, error) { type NoMethod GcsFuseCsiDriverConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GetJSONWebKeysResponse: GetJSONWebKeysResponse is a valid JSON Web -// Key Set as specififed in rfc 7517 +// GetJSONWebKeysResponse: GetJSONWebKeysResponse is a valid JSON Web Key Set +// as specififed in rfc 7517 type GetJSONWebKeysResponse struct { - // CacheHeader: OnePlatform automatically extracts this field and uses - // it to set the HTTP Cache-Control header. + // CacheHeader: OnePlatform automatically extracts this field and uses it to + // set the HTTP Cache-Control header. CacheHeader *HttpCacheControlResponseHeader `json:"cacheHeader,omitempty"` - - // Keys: The public component of the keys used by the cluster to sign - // token requests. + // Keys: The public component of the keys used by the cluster to sign token + // requests. Keys []*Jwk `json:"keys,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CacheHeader") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CacheHeader") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CacheHeader") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GetJSONWebKeysResponse) MarshalJSON() ([]byte, error) { type NoMethod GetJSONWebKeysResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // GetOpenIDConfigResponse: GetOpenIDConfigResponse is an OIDC discovery -// document for the cluster. See the OpenID Connect Discovery 1.0 -// specification for details. +// document for the cluster. See the OpenID Connect Discovery 1.0 specification +// for details. type GetOpenIDConfigResponse struct { - // CacheHeader: OnePlatform automatically extracts this field and uses - // it to set the HTTP Cache-Control header. + // CacheHeader: OnePlatform automatically extracts this field and uses it to + // set the HTTP Cache-Control header. CacheHeader *HttpCacheControlResponseHeader `json:"cacheHeader,omitempty"` - // ClaimsSupported: Supported claims. ClaimsSupported []string `json:"claims_supported,omitempty"` - // GrantTypes: Supported grant types. GrantTypes []string `json:"grant_types,omitempty"` - - // IdTokenSigningAlgValuesSupported: supported ID Token signing - // Algorithms. + // IdTokenSigningAlgValuesSupported: supported ID Token signing Algorithms. IdTokenSigningAlgValuesSupported []string `json:"id_token_signing_alg_values_supported,omitempty"` - // Issuer: OIDC Issuer. Issuer string `json:"issuer,omitempty"` - // JwksUri: JSON Web Key uri. JwksUri string `json:"jwks_uri,omitempty"` - // ResponseTypesSupported: Supported response types. ResponseTypesSupported []string `json:"response_types_supported,omitempty"` - // SubjectTypesSupported: Supported subject types. SubjectTypesSupported []string `json:"subject_types_supported,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CacheHeader") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CacheHeader") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CacheHeader") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GetOpenIDConfigResponse) MarshalJSON() ([]byte, error) { type NoMethod GetOpenIDConfigResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // GkeBackupAgentConfig: Configuration for the Backup for GKE Agent. type GkeBackupAgentConfig struct { - // Enabled: Whether the Backup for GKE agent is enabled for this - // cluster. + // Enabled: Whether the Backup for GKE agent is enabled for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GkeBackupAgentConfig) MarshalJSON() ([]byte, error) { type NoMethod GkeBackupAgentConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HorizontalPodAutoscaling: Configuration options for the horizontal -// pod autoscaling feature, which increases or decreases the number of -// replica pods a replication controller has based on the resource usage -// of the existing pods. +// HorizontalPodAutoscaling: Configuration options for the horizontal pod +// autoscaling feature, which increases or decreases the number of replica pods +// a replication controller has based on the resource usage of the existing +// pods. type HorizontalPodAutoscaling struct { - // Disabled: Whether the Horizontal Pod Autoscaling feature is enabled - // in the cluster. When enabled, it ensures that metrics are collected - // into Stackdriver Monitoring. + // Disabled: Whether the Horizontal Pod Autoscaling feature is enabled in the + // cluster. When enabled, it ensures that metrics are collected into + // Stackdriver Monitoring. Disabled bool `json:"disabled,omitempty"` - // ForceSendFields is a list of field names (e.g. "Disabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HorizontalPodAutoscaling) MarshalJSON() ([]byte, error) { type NoMethod HorizontalPodAutoscaling - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HostMaintenancePolicy: HostMaintenancePolicy contains the maintenance -// policy for the hosts on which the GKE VMs run on. +// HostMaintenancePolicy: HostMaintenancePolicy contains the maintenance policy +// for the hosts on which the GKE VMs run on. type HostMaintenancePolicy struct { - // MaintenanceInterval: Specifies the frequency of planned maintenance - // events. + // MaintenanceInterval: Specifies the frequency of planned maintenance events. // // Possible values: - // "MAINTENANCE_INTERVAL_UNSPECIFIED" - The maintenance interval is - // not explicitly specified. - // "AS_NEEDED" - Nodes are eligible to receive infrastructure and - // hypervisor updates as they become available. This may result in more - // maintenance operations (live migrations or terminations) for the node - // than the PERIODIC option. - // "PERIODIC" - Nodes receive infrastructure and hypervisor updates on - // a periodic basis, minimizing the number of maintenance operations - // (live migrations or terminations) on an individual VM. This may mean - // underlying VMs will take longer to receive an update than if it was - // configured for AS_NEEDED. Security updates will still be applied as - // soon as they are available. + // "MAINTENANCE_INTERVAL_UNSPECIFIED" - The maintenance interval is not + // explicitly specified. + // "AS_NEEDED" - Nodes are eligible to receive infrastructure and hypervisor + // updates as they become available. This may result in more maintenance + // operations (live migrations or terminations) for the node than the PERIODIC + // option. + // "PERIODIC" - Nodes receive infrastructure and hypervisor updates on a + // periodic basis, minimizing the number of maintenance operations (live + // migrations or terminations) on an individual VM. This may mean underlying + // VMs will take longer to receive an update than if it was configured for + // AS_NEEDED. Security updates will still be applied as soon as they are + // available. MaintenanceInterval string `json:"maintenanceInterval,omitempty"` - - // OpportunisticMaintenanceStrategy: Strategy that will trigger - // maintenance on behalf of the customer. + // OpportunisticMaintenanceStrategy: Strategy that will trigger maintenance on + // behalf of the customer. OpportunisticMaintenanceStrategy *OpportunisticMaintenanceStrategy `json:"opportunisticMaintenanceStrategy,omitempty"` - - // ForceSendFields is a list of field names (e.g. "MaintenanceInterval") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "MaintenanceInterval") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MaintenanceInterval") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "MaintenanceInterval") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HostMaintenancePolicy) MarshalJSON() ([]byte, error) { type NoMethod HostMaintenancePolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // HttpCacheControlResponseHeader: RFC-2616: cache control support type HttpCacheControlResponseHeader struct { - // Age: 14.6 response cache age, in seconds since the response is - // generated + // Age: 14.6 response cache age, in seconds since the response is generated Age int64 `json:"age,omitempty,string"` - // Directive: 14.9 request and response directives Directive string `json:"directive,omitempty"` - // Expires: 14.21 response cache expires, in RFC 1123 date format Expires string `json:"expires,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Age") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Age") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Age") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Age") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HttpCacheControlResponseHeader) MarshalJSON() ([]byte, error) { type NoMethod HttpCacheControlResponseHeader - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HttpLoadBalancing: Configuration options for the HTTP (L7) load -// balancing controller addon, which makes it easy to set up HTTP load -// balancers for services in a cluster. +// HttpLoadBalancing: Configuration options for the HTTP (L7) load balancing +// controller addon, which makes it easy to set up HTTP load balancers for +// services in a cluster. type HttpLoadBalancing struct { - // Disabled: Whether the HTTP Load Balancing controller is enabled in - // the cluster. When enabled, it runs a small pod in the cluster that - // manages the load balancers. + // Disabled: Whether the HTTP Load Balancing controller is enabled in the + // cluster. When enabled, it runs a small pod in the cluster that manages the + // load balancers. Disabled bool `json:"disabled,omitempty"` - // ForceSendFields is a list of field names (e.g. "Disabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HttpLoadBalancing) MarshalJSON() ([]byte, error) { type NoMethod HttpLoadBalancing - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // HugepagesConfig: Hugepages amount in both 2m and 1g size type HugepagesConfig struct { // HugepageSize1g: Optional. Amount of 1G hugepages HugepageSize1g int64 `json:"hugepageSize1g,omitempty"` - // HugepageSize2m: Optional. Amount of 2M hugepages HugepageSize2m int64 `json:"hugepageSize2m,omitempty"` - // ForceSendFields is a list of field names (e.g. "HugepageSize1g") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "HugepageSize1g") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "HugepageSize1g") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HugepagesConfig) MarshalJSON() ([]byte, error) { type NoMethod HugepagesConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ILBSubsettingConfig: ILBSubsettingConfig contains the desired config -// of L4 Internal LoadBalancer subsetting on this cluster. +// ILBSubsettingConfig: ILBSubsettingConfig contains the desired config of L4 +// Internal LoadBalancer subsetting on this cluster. type ILBSubsettingConfig struct { // Enabled: Enables l4 ILB subsetting for this cluster Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ILBSubsettingConfig) MarshalJSON() ([]byte, error) { type NoMethod ILBSubsettingConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// IPAllocationPolicy: Configuration for controlling how IPs are -// allocated in the cluster. +// IPAllocationPolicy: Configuration for controlling how IPs are allocated in +// the cluster. type IPAllocationPolicy struct { - // AdditionalPodRangesConfig: Output only. [Output only] The additional - // pod ranges that are added to the cluster. These pod ranges can be - // used by new node pools to allocate pod IPs automatically. Once the - // range is removed it will not show up in IPAllocationPolicy. + // AdditionalPodRangesConfig: Output only. [Output only] The additional pod + // ranges that are added to the cluster. These pod ranges can be used by new + // node pools to allocate pod IPs automatically. Once the range is removed it + // will not show up in IPAllocationPolicy. AdditionalPodRangesConfig *AdditionalPodRangesConfig `json:"additionalPodRangesConfig,omitempty"` - - // AllowRouteOverlap: If true, allow allocation of cluster CIDR ranges - // that overlap with certain kinds of network routes. By default we do - // not allow cluster CIDR ranges to intersect with any user declared - // routes. With allow_route_overlap == true, we allow overlapping with - // CIDR ranges that are larger than the cluster CIDR range. If this - // field is set to true, then cluster and services CIDRs must be - // fully-specified (e.g. `10.96.0.0/14`, but not `/14`), which means: 1) - // When `use_ip_aliases` is true, `cluster_ipv4_cidr_block` and - // `services_ipv4_cidr_block` must be fully-specified. 2) When - // `use_ip_aliases` is false, `cluster.cluster_ipv4_cidr` muse be - // fully-specified. + // AllowRouteOverlap: If true, allow allocation of cluster CIDR ranges that + // overlap with certain kinds of network routes. By default we do not allow + // cluster CIDR ranges to intersect with any user declared routes. With + // allow_route_overlap == true, we allow overlapping with CIDR ranges that are + // larger than the cluster CIDR range. If this field is set to true, then + // cluster and services CIDRs must be fully-specified (e.g. `10.96.0.0/14`, but + // not `/14`), which means: 1) When `use_ip_aliases` is true, + // `cluster_ipv4_cidr_block` and `services_ipv4_cidr_block` must be + // fully-specified. 2) When `use_ip_aliases` is false, + // `cluster.cluster_ipv4_cidr` muse be fully-specified. AllowRouteOverlap bool `json:"allowRouteOverlap,omitempty"` - - // ClusterIpv4Cidr: This field is deprecated, use - // cluster_ipv4_cidr_block. + // ClusterIpv4Cidr: This field is deprecated, use cluster_ipv4_cidr_block. ClusterIpv4Cidr string `json:"clusterIpv4Cidr,omitempty"` - - // ClusterIpv4CidrBlock: The IP address range for the cluster pod IPs. - // If this field is set, then `cluster.cluster_ipv4_cidr` must be left - // blank. This field is only applicable when `use_ip_aliases` is true. - // Set to blank to have a range chosen with the default size. Set to - // /netmask (e.g. `/14`) to have a range chosen with a specific netmask. - // Set to a CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `10.96.0.0/14`) from the RFC-1918 private networks - // (e.g. `10.0.0.0/8`, `172.16.0.0/12`, `192.168.0.0/16`) to pick a - // specific range to use. + // ClusterIpv4CidrBlock: The IP address range for the cluster pod IPs. If this + // field is set, then `cluster.cluster_ipv4_cidr` must be left blank. This + // field is only applicable when `use_ip_aliases` is true. Set to blank to have + // a range chosen with the default size. Set to /netmask (e.g. `/14`) to have a + // range chosen with a specific netmask. Set to a CIDR + // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. + // `10.96.0.0/14`) from the RFC-1918 private networks (e.g. `10.0.0.0/8`, + // `172.16.0.0/12`, `192.168.0.0/16`) to pick a specific range to use. ClusterIpv4CidrBlock string `json:"clusterIpv4CidrBlock,omitempty"` - - // ClusterSecondaryRangeName: The name of the secondary range to be used - // for the cluster CIDR block. The secondary range will be used for pod - // IP addresses. This must be an existing secondary range associated - // with the cluster subnetwork. This field is only applicable with - // use_ip_aliases and create_subnetwork is false. + // ClusterSecondaryRangeName: The name of the secondary range to be used for + // the cluster CIDR block. The secondary range will be used for pod IP + // addresses. This must be an existing secondary range associated with the + // cluster subnetwork. This field is only applicable with use_ip_aliases and + // create_subnetwork is false. ClusterSecondaryRangeName string `json:"clusterSecondaryRangeName,omitempty"` - - // CreateSubnetwork: Whether a new subnetwork will be created - // automatically for the cluster. This field is only applicable when - // `use_ip_aliases` is true. + // CreateSubnetwork: Whether a new subnetwork will be created automatically for + // the cluster. This field is only applicable when `use_ip_aliases` is true. CreateSubnetwork bool `json:"createSubnetwork,omitempty"` - - // DefaultPodIpv4RangeUtilization: Output only. [Output only] The - // utilization of the cluster default IPv4 range for the pod. The ratio - // is Usage/[Total number of IPs in the secondary range], + // DefaultPodIpv4RangeUtilization: Output only. [Output only] The utilization + // of the cluster default IPv4 range for the pod. The ratio is Usage/[Total + // number of IPs in the secondary range], // Usage=numNodes*numZones*podIPsPerNode. DefaultPodIpv4RangeUtilization float64 `json:"defaultPodIpv4RangeUtilization,omitempty"` - // Ipv6AccessType: The ipv6 access type (internal or external) when // create_subnetwork is true // // Possible values: - // "IPV6_ACCESS_TYPE_UNSPECIFIED" - Default value, will be defaulted - // as type external. - // "INTERNAL" - Access type internal (all v6 addresses are internal - // IPs) - // "EXTERNAL" - Access type external (all v6 addresses are external - // IPs) + // "IPV6_ACCESS_TYPE_UNSPECIFIED" - Default value, will be defaulted as type + // external. + // "INTERNAL" - Access type internal (all v6 addresses are internal IPs) + // "EXTERNAL" - Access type external (all v6 addresses are external IPs) Ipv6AccessType string `json:"ipv6AccessType,omitempty"` - // NodeIpv4Cidr: This field is deprecated, use node_ipv4_cidr_block. NodeIpv4Cidr string `json:"nodeIpv4Cidr,omitempty"` - - // NodeIpv4CidrBlock: The IP address range of the instance IPs in this - // cluster. This is applicable only if `create_subnetwork` is true. Set - // to blank to have a range chosen with the default size. Set to - // /netmask (e.g. `/14`) to have a range chosen with a specific netmask. - // Set to a CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `10.96.0.0/14`) from the RFC-1918 private networks - // (e.g. `10.0.0.0/8`, `172.16.0.0/12`, `192.168.0.0/16`) to pick a - // specific range to use. + // NodeIpv4CidrBlock: The IP address range of the instance IPs in this cluster. + // This is applicable only if `create_subnetwork` is true. Set to blank to have + // a range chosen with the default size. Set to /netmask (e.g. `/14`) to have a + // range chosen with a specific netmask. Set to a CIDR + // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. + // `10.96.0.0/14`) from the RFC-1918 private networks (e.g. `10.0.0.0/8`, + // `172.16.0.0/12`, `192.168.0.0/16`) to pick a specific range to use. NodeIpv4CidrBlock string `json:"nodeIpv4CidrBlock,omitempty"` - - // PodCidrOverprovisionConfig: [PRIVATE FIELD] Pod CIDR size - // overprovisioning config for the cluster. Pod CIDR size per node - // depends on max_pods_per_node. By default, the value of - // max_pods_per_node is doubled and then rounded off to next power of 2 - // to get the size of pod CIDR block per node. Example: + // PodCidrOverprovisionConfig: [PRIVATE FIELD] Pod CIDR size overprovisioning + // config for the cluster. Pod CIDR size per node depends on max_pods_per_node. + // By default, the value of max_pods_per_node is doubled and then rounded off + // to next power of 2 to get the size of pod CIDR block per node. Example: // max_pods_per_node of 30 would result in 64 IPs (/26). This config can - // disable the doubling of IPs (we still round off to next power of 2) - // Example: max_pods_per_node of 30 will result in 32 IPs (/27) when - // overprovisioning is disabled. + // disable the doubling of IPs (we still round off to next power of 2) Example: + // max_pods_per_node of 30 will result in 32 IPs (/27) when overprovisioning is + // disabled. PodCidrOverprovisionConfig *PodCIDROverprovisionConfig `json:"podCidrOverprovisionConfig,omitempty"` - - // ServicesIpv4Cidr: This field is deprecated, use - // services_ipv4_cidr_block. + // ServicesIpv4Cidr: This field is deprecated, use services_ipv4_cidr_block. ServicesIpv4Cidr string `json:"servicesIpv4Cidr,omitempty"` - - // ServicesIpv4CidrBlock: The IP address range of the services IPs in - // this cluster. If blank, a range will be automatically chosen with the - // default size. This field is only applicable when `use_ip_aliases` is - // true. Set to blank to have a range chosen with the default size. Set - // to /netmask (e.g. `/14`) to have a range chosen with a specific - // netmask. Set to a CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `10.96.0.0/14`) from the RFC-1918 private networks - // (e.g. `10.0.0.0/8`, `172.16.0.0/12`, `192.168.0.0/16`) to pick a - // specific range to use. + // ServicesIpv4CidrBlock: The IP address range of the services IPs in this + // cluster. If blank, a range will be automatically chosen with the default + // size. This field is only applicable when `use_ip_aliases` is true. Set to + // blank to have a range chosen with the default size. Set to /netmask (e.g. + // `/14`) to have a range chosen with a specific netmask. Set to a CIDR + // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. + // `10.96.0.0/14`) from the RFC-1918 private networks (e.g. `10.0.0.0/8`, + // `172.16.0.0/12`, `192.168.0.0/16`) to pick a specific range to use. ServicesIpv4CidrBlock string `json:"servicesIpv4CidrBlock,omitempty"` - - // ServicesIpv6CidrBlock: Output only. [Output only] The services IPv6 - // CIDR block for the cluster. + // ServicesIpv6CidrBlock: Output only. [Output only] The services IPv6 CIDR + // block for the cluster. ServicesIpv6CidrBlock string `json:"servicesIpv6CidrBlock,omitempty"` - - // ServicesSecondaryRangeName: The name of the secondary range to be - // used as for the services CIDR block. The secondary range will be used - // for service ClusterIPs. This must be an existing secondary range - // associated with the cluster subnetwork. This field is only applicable - // with use_ip_aliases and create_subnetwork is false. + // ServicesSecondaryRangeName: The name of the secondary range to be used as + // for the services CIDR block. The secondary range will be used for service + // ClusterIPs. This must be an existing secondary range associated with the + // cluster subnetwork. This field is only applicable with use_ip_aliases and + // create_subnetwork is false. ServicesSecondaryRangeName string `json:"servicesSecondaryRangeName,omitempty"` - // StackType: IP stack type // // Possible values: - // "STACK_TYPE_UNSPECIFIED" - By default, the clusters will be IPV4 - // only + // "STACK_TYPE_UNSPECIFIED" - By default, the clusters will be IPV4 only // "IPV4" - The value used if the cluster is a IPV4 only // "IPV4_IPV6" - The value used if the cluster is a dual stack cluster StackType string `json:"stackType,omitempty"` - - // SubnetIpv6CidrBlock: Output only. [Output only] The subnet's IPv6 - // CIDR block used by nodes and pods. + // SubnetIpv6CidrBlock: Output only. [Output only] The subnet's IPv6 CIDR block + // used by nodes and pods. SubnetIpv6CidrBlock string `json:"subnetIpv6CidrBlock,omitempty"` - - // SubnetworkName: A custom subnetwork name to be used if - // `create_subnetwork` is true. If this field is empty, then an - // automatic name will be chosen for the new subnetwork. + // SubnetworkName: A custom subnetwork name to be used if `create_subnetwork` + // is true. If this field is empty, then an automatic name will be chosen for + // the new subnetwork. SubnetworkName string `json:"subnetworkName,omitempty"` - - // TpuIpv4CidrBlock: The IP address range of the Cloud TPUs in this - // cluster. If unspecified, a range will be automatically chosen with - // the default size. This field is only applicable when `use_ip_aliases` - // is true. If unspecified, the range will use the default size. Set to - // /netmask (e.g. `/14`) to have a range chosen with a specific netmask. - // Set to a CIDR - // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `10.96.0.0/14`) from the RFC-1918 private networks - // (e.g. `10.0.0.0/8`, `172.16.0.0/12`, `192.168.0.0/16`) to pick a - // specific range to use. This field is deprecated, use - // cluster.tpu_config.ipv4_cidr_block instead. + // TpuIpv4CidrBlock: The IP address range of the Cloud TPUs in this cluster. If + // unspecified, a range will be automatically chosen with the default size. + // This field is only applicable when `use_ip_aliases` is true. If unspecified, + // the range will use the default size. Set to /netmask (e.g. `/14`) to have a + // range chosen with a specific netmask. Set to a CIDR + // (http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. + // `10.96.0.0/14`) from the RFC-1918 private networks (e.g. `10.0.0.0/8`, + // `172.16.0.0/12`, `192.168.0.0/16`) to pick a specific range to use. This + // field is deprecated, use cluster.tpu_config.ipv4_cidr_block instead. TpuIpv4CidrBlock string `json:"tpuIpv4CidrBlock,omitempty"` - - // UseIpAliases: Whether alias IPs will be used for pod IPs in the - // cluster. This is used in conjunction with use_routes. It cannot be - // true if use_routes is true. If both use_ip_aliases and use_routes are - // false, then the server picks the default IP allocation mode + // UseIpAliases: Whether alias IPs will be used for pod IPs in the cluster. + // This is used in conjunction with use_routes. It cannot be true if use_routes + // is true. If both use_ip_aliases and use_routes are false, then the server + // picks the default IP allocation mode UseIpAliases bool `json:"useIpAliases,omitempty"` - - // UseRoutes: Whether routes will be used for pod IPs in the cluster. - // This is used in conjunction with use_ip_aliases. It cannot be true if - // use_ip_aliases is true. If both use_ip_aliases and use_routes are - // false, then the server picks the default IP allocation mode + // UseRoutes: Whether routes will be used for pod IPs in the cluster. This is + // used in conjunction with use_ip_aliases. It cannot be true if use_ip_aliases + // is true. If both use_ip_aliases and use_routes are false, then the server + // picks the default IP allocation mode UseRoutes bool `json:"useRoutes,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AdditionalPodRangesConfig") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AdditionalPodRangesConfig") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "AdditionalPodRangesConfig") to include in API requests with the JSON - // null value. By default, fields with empty values are omitted from API - // requests. However, any field with an empty value appearing in - // NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "AdditionalPodRangesConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *IPAllocationPolicy) MarshalJSON() ([]byte, error) { type NoMethod IPAllocationPolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } func (s *IPAllocationPolicy) UnmarshalJSON(data []byte) error { @@ -3986,63 +3153,51 @@ func (s *IPAllocationPolicy) UnmarshalJSON(data []byte) error { return nil } -// IdentityServiceConfig: IdentityServiceConfig is configuration for -// Identity Service which allows customers to use external identity -// providers with the K8S API +// IdentityServiceConfig: IdentityServiceConfig is configuration for Identity +// Service which allows customers to use external identity providers with the +// K8S API type IdentityServiceConfig struct { // Enabled: Whether to enable the Identity Service component Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *IdentityServiceConfig) MarshalJSON() ([]byte, error) { type NoMethod IdentityServiceConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// IntraNodeVisibilityConfig: IntraNodeVisibilityConfig contains the -// desired config of the intra-node visibility on this cluster. +// IntraNodeVisibilityConfig: IntraNodeVisibilityConfig contains the desired +// config of the intra-node visibility on this cluster. type IntraNodeVisibilityConfig struct { // Enabled: Enables intra node visibility for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *IntraNodeVisibilityConfig) MarshalJSON() ([]byte, error) { type NoMethod IntraNodeVisibilityConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // IstioConfig: Configuration options for Istio addon. @@ -4053,329 +3208,256 @@ type IstioConfig struct { // "AUTH_NONE" - auth not enabled // "AUTH_MUTUAL_TLS" - auth mutual TLS enabled Auth string `json:"auth,omitempty"` - // Disabled: Whether Istio is enabled for this cluster. Disabled bool `json:"disabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Auth") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Auth") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Auth") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Auth") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *IstioConfig) MarshalJSON() ([]byte, error) { type NoMethod IstioConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Jwk: Jwk is a JSON Web Key as specified in RFC 7517 type Jwk struct { // Alg: Algorithm. Alg string `json:"alg,omitempty"` - // Crv: Used for ECDSA keys. Crv string `json:"crv,omitempty"` - // E: Used for RSA keys. E string `json:"e,omitempty"` - // Kid: Key ID. Kid string `json:"kid,omitempty"` - // Kty: Key Type. Kty string `json:"kty,omitempty"` - // N: Used for RSA keys. N string `json:"n,omitempty"` - // Use: Permitted uses for the public keys. Use string `json:"use,omitempty"` - // X: Used for ECDSA keys. X string `json:"x,omitempty"` - // Y: Used for ECDSA keys. Y string `json:"y,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Alg") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Alg") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Alg") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Alg") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Jwk) MarshalJSON() ([]byte, error) { type NoMethod Jwk - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// K8sBetaAPIConfig: Kubernetes open source beta apis enabled on the -// cluster. +// K8sBetaAPIConfig: Kubernetes open source beta apis enabled on the cluster. type K8sBetaAPIConfig struct { - // EnabledApis: api name, e.g. - // storage.k8s.io/v1beta1/csistoragecapacities. + // EnabledApis: api name, e.g. storage.k8s.io/v1beta1/csistoragecapacities. EnabledApis []string `json:"enabledApis,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnabledApis") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnabledApis") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EnabledApis") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *K8sBetaAPIConfig) MarshalJSON() ([]byte, error) { type NoMethod K8sBetaAPIConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // KalmConfig: Configuration options for the KALM addon. type KalmConfig struct { // Enabled: Whether KALM is enabled for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *KalmConfig) MarshalJSON() ([]byte, error) { type NoMethod KalmConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // KubernetesDashboard: Configuration for the Kubernetes Dashboard. type KubernetesDashboard struct { - // Disabled: Whether the Kubernetes Dashboard is enabled for this - // cluster. + // Disabled: Whether the Kubernetes Dashboard is enabled for this cluster. Disabled bool `json:"disabled,omitempty"` - // ForceSendFields is a list of field names (e.g. "Disabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *KubernetesDashboard) MarshalJSON() ([]byte, error) { type NoMethod KubernetesDashboard - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// LegacyAbac: Configuration for the legacy Attribute Based Access -// Control authorization mode. +// LegacyAbac: Configuration for the legacy Attribute Based Access Control +// authorization mode. type LegacyAbac struct { - // Enabled: Whether the ABAC authorizer is enabled for this cluster. - // When enabled, identities in the system, including service accounts, - // nodes, and controllers, will have statically granted permissions - // beyond those provided by the RBAC configuration or IAM. + // Enabled: Whether the ABAC authorizer is enabled for this cluster. When + // enabled, identities in the system, including service accounts, nodes, and + // controllers, will have statically granted permissions beyond those provided + // by the RBAC configuration or IAM. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *LegacyAbac) MarshalJSON() ([]byte, error) { type NoMethod LegacyAbac - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // LinuxNodeConfig: Parameters that can be configured on Linux nodes. type LinuxNodeConfig struct { - // CgroupMode: cgroup_mode specifies the cgroup mode to be used on the - // node. + // CgroupMode: cgroup_mode specifies the cgroup mode to be used on the node. // // Possible values: - // "CGROUP_MODE_UNSPECIFIED" - CGROUP_MODE_UNSPECIFIED is when - // unspecified cgroup configuration is used. The default for the GKE - // node OS image will be used. - // "CGROUP_MODE_V1" - CGROUP_MODE_V1 specifies to use cgroupv1 for the - // cgroup configuration on the node image. - // "CGROUP_MODE_V2" - CGROUP_MODE_V2 specifies to use cgroupv2 for the - // cgroup configuration on the node image. + // "CGROUP_MODE_UNSPECIFIED" - CGROUP_MODE_UNSPECIFIED is when unspecified + // cgroup configuration is used. The default for the GKE node OS image will be + // used. + // "CGROUP_MODE_V1" - CGROUP_MODE_V1 specifies to use cgroupv1 for the cgroup + // configuration on the node image. + // "CGROUP_MODE_V2" - CGROUP_MODE_V2 specifies to use cgroupv2 for the cgroup + // configuration on the node image. CgroupMode string `json:"cgroupMode,omitempty"` - // Hugepages: Optional. Amounts for 2M and 1G hugepages Hugepages *HugepagesConfig `json:"hugepages,omitempty"` - - // Sysctls: The Linux kernel parameters to be applied to the nodes and - // all pods running on the nodes. The following parameters are - // supported. net.core.busy_poll net.core.busy_read - // net.core.netdev_max_backlog net.core.rmem_max net.core.wmem_default - // net.core.wmem_max net.core.optmem_max net.core.somaxconn - // net.ipv4.tcp_rmem net.ipv4.tcp_wmem net.ipv4.tcp_tw_reuse + // Sysctls: The Linux kernel parameters to be applied to the nodes and all pods + // running on the nodes. The following parameters are supported. + // net.core.busy_poll net.core.busy_read net.core.netdev_max_backlog + // net.core.rmem_max net.core.wmem_default net.core.wmem_max + // net.core.optmem_max net.core.somaxconn net.ipv4.tcp_rmem net.ipv4.tcp_wmem + // net.ipv4.tcp_tw_reuse Sysctls map[string]string `json:"sysctls,omitempty"` - // ForceSendFields is a list of field names (e.g. "CgroupMode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CgroupMode") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CgroupMode") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *LinuxNodeConfig) MarshalJSON() ([]byte, error) { type NoMethod LinuxNodeConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ListClustersResponse: ListClustersResponse is the result of // ListClustersRequest. type ListClustersResponse struct { - // Clusters: A list of clusters in the project in the specified zone, or - // across all ones. + // Clusters: A list of clusters in the project in the specified zone, or across + // all ones. Clusters []*Cluster `json:"clusters,omitempty"` - - // MissingZones: If any zones are listed here, the list of clusters - // returned may be missing those zones. + // MissingZones: If any zones are listed here, the list of clusters returned + // may be missing those zones. MissingZones []string `json:"missingZones,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Clusters") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Clusters") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Clusters") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ListClustersResponse) MarshalJSON() ([]byte, error) { type NoMethod ListClustersResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ListLocationsResponse: ListLocationsResponse returns the list of all -// GKE locations and their recommendation state. +// ListLocationsResponse: ListLocationsResponse returns the list of all GKE +// locations and their recommendation state. type ListLocationsResponse struct { // Locations: A full list of GKE locations. Locations []*Location `json:"locations,omitempty"` - // NextPageToken: Only return ListLocationsResponse that occur after the // page_token. This value should be populated from the - // ListLocationsResponse.next_page_token if that response token was set - // (which happens when listing more Locations than fit in a single + // ListLocationsResponse.next_page_token if that response token was set (which + // happens when listing more Locations than fit in a single // ListLocationsResponse). NextPageToken string `json:"nextPageToken,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Locations") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Locations") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Locations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) { type NoMethod ListLocationsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ListNodePoolsResponse: ListNodePoolsResponse is the result of @@ -4384,204 +3466,160 @@ type ListNodePoolsResponse struct { // NodePools: A list of node pools for a cluster. NodePools []*NodePool `json:"nodePools,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "NodePools") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NodePools") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "NodePools") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ListNodePoolsResponse) MarshalJSON() ([]byte, error) { type NoMethod ListNodePoolsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ListOperationsResponse: ListOperationsResponse is the result of // ListOperationsRequest. type ListOperationsResponse struct { - // MissingZones: If any zones are listed here, the list of operations - // returned may be missing the operations from those zones. + // MissingZones: If any zones are listed here, the list of operations returned + // may be missing the operations from those zones. MissingZones []string `json:"missingZones,omitempty"` - - // Operations: A list of operations in the project in the specified - // zone. + // Operations: A list of operations in the project in the specified zone. Operations []*Operation `json:"operations,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "MissingZones") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MissingZones") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "MissingZones") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) { type NoMethod ListOperationsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ListUsableSubnetworksResponse: ListUsableSubnetworksResponse is the -// response of ListUsableSubnetworksRequest. +// ListUsableSubnetworksResponse: ListUsableSubnetworksResponse is the response +// of ListUsableSubnetworksRequest. type ListUsableSubnetworksResponse struct { - // NextPageToken: This token allows you to get the next page of results - // for list requests. If the number of results is larger than - // `page_size`, use the `next_page_token` as a value for the query - // parameter `page_token` in the next request. The value will become - // empty when there are no more pages. + // NextPageToken: This token allows you to get the next page of results for + // list requests. If the number of results is larger than `page_size`, use the + // `next_page_token` as a value for the query parameter `page_token` in the + // next request. The value will become empty when there are no more pages. NextPageToken string `json:"nextPageToken,omitempty"` - - // Subnetworks: A list of usable subnetworks in the specified network - // project. + // Subnetworks: A list of usable subnetworks in the specified network project. Subnetworks []*UsableSubnetwork `json:"subnetworks,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NextPageToken") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ListUsableSubnetworksResponse) MarshalJSON() ([]byte, error) { type NoMethod ListUsableSubnetworksResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// LocalNvmeSsdBlockConfig: LocalNvmeSsdBlockConfig contains -// configuration for using raw-block local NVMe SSDs +// LocalNvmeSsdBlockConfig: LocalNvmeSsdBlockConfig contains configuration for +// using raw-block local NVMe SSDs type LocalNvmeSsdBlockConfig struct { - // LocalSsdCount: Number of local NVMe SSDs to use. The limit for this - // value is dependent upon the maximum number of disk available on a - // machine per zone. See: - // https://cloud.google.com/compute/docs/disks/local-ssd for more - // information. A zero (or unset) value has different meanings depending - // on machine type being used: 1. For pre-Gen3 machines, which support - // flexible numbers of local ssds, zero (or unset) means to disable - // using local SSDs as ephemeral storage. 2. For Gen3 machines which - // dictate a specific number of local ssds, zero (or unset) means to use - // the default number of local ssds that goes with that machine type. - // For example, for a c3-standard-8-lssd machine, 2 local ssds would be - // provisioned. For c3-standard-8 (which doesn't support local ssds), 0 - // will be provisioned. See + // LocalSsdCount: Number of local NVMe SSDs to use. The limit for this value is + // dependent upon the maximum number of disk available on a machine per zone. + // See: https://cloud.google.com/compute/docs/disks/local-ssd for more + // information. A zero (or unset) value has different meanings depending on + // machine type being used: 1. For pre-Gen3 machines, which support flexible + // numbers of local ssds, zero (or unset) means to disable using local SSDs as + // ephemeral storage. 2. For Gen3 machines which dictate a specific number of + // local ssds, zero (or unset) means to use the default number of local ssds + // that goes with that machine type. For example, for a c3-standard-8-lssd + // machine, 2 local ssds would be provisioned. For c3-standard-8 (which doesn't + // support local ssds), 0 will be provisioned. See // https://cloud.google.com/compute/docs/disks/local-ssd#choose_number_local_ssds // for more info. LocalSsdCount int64 `json:"localSsdCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "LocalSsdCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "LocalSsdCount") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "LocalSsdCount") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *LocalNvmeSsdBlockConfig) MarshalJSON() ([]byte, error) { type NoMethod LocalNvmeSsdBlockConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Location: Location returns the location name, and if the location is // recommended for GKE cluster scheduling. type Location struct { - // Name: Contains the name of the resource requested. Specified in the - // format `projects/*/locations/*`. + // Name: Contains the name of the resource requested. Specified in the format + // `projects/*/locations/*`. Name string `json:"name,omitempty"` - - // Recommended: Whether the location is recommended for GKE cluster - // scheduling. + // Recommended: Whether the location is recommended for GKE cluster scheduling. Recommended bool `json:"recommended,omitempty"` - - // Type: Contains the type of location this Location is for. Regional or - // Zonal. + // Type: Contains the type of location this Location is for. Regional or Zonal. // // Possible values: - // "LOCATION_TYPE_UNSPECIFIED" - LOCATION_TYPE_UNSPECIFIED means the - // location type was not determined. + // "LOCATION_TYPE_UNSPECIFIED" - LOCATION_TYPE_UNSPECIFIED means the location + // type was not determined. // "ZONE" - A GKE Location where Zonal clusters can be created. // "REGION" - A GKE Location where Regional clusters can be created. Type string `json:"type,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Name") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Name") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Name") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Name") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Location) MarshalJSON() ([]byte, error) { type NoMethod Location - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// LoggingComponentConfig: LoggingComponentConfig is cluster logging -// component configuration. +// LoggingComponentConfig: LoggingComponentConfig is cluster logging component +// configuration. type LoggingComponentConfig struct { - // EnableComponents: Select components to collect logs. An empty set - // would disable all logging. + // EnableComponents: Select components to collect logs. An empty set would + // disable all logging. // // Possible values: // "COMPONENT_UNSPECIFIED" - Default value. This shouldn't be used. @@ -4591,62 +3629,48 @@ type LoggingComponentConfig struct { // "SCHEDULER" - kube-scheduler // "CONTROLLER_MANAGER" - kube-controller-manager EnableComponents []string `json:"enableComponents,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnableComponents") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnableComponents") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EnableComponents") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *LoggingComponentConfig) MarshalJSON() ([]byte, error) { type NoMethod LoggingComponentConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // LoggingConfig: LoggingConfig is cluster logging configuration. type LoggingConfig struct { // ComponentConfig: Logging components configuration ComponentConfig *LoggingComponentConfig `json:"componentConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "ComponentConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ComponentConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ComponentConfig") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *LoggingConfig) MarshalJSON() ([]byte, error) { type NoMethod LoggingConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// LoggingVariantConfig: LoggingVariantConfig specifies the behaviour of -// the logging component. +// LoggingVariantConfig: LoggingVariantConfig specifies the behaviour of the +// logging component. type LoggingVariantConfig struct { // Variant: Logging variant deployed on nodes. // @@ -4655,178 +3679,139 @@ type LoggingVariantConfig struct { // "DEFAULT" - default logging variant. // "MAX_THROUGHPUT" - maximum logging throughput variant. Variant string `json:"variant,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Variant") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Variant") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Variant") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Variant") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *LoggingVariantConfig) MarshalJSON() ([]byte, error) { type NoMethod LoggingVariantConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// MaintenanceExclusionOptions: Represents the Maintenance exclusion -// option. +// MaintenanceExclusionOptions: Represents the Maintenance exclusion option. type MaintenanceExclusionOptions struct { - // Scope: Scope specifies the upgrade scope which upgrades are blocked - // by the exclusion. + // Scope: Scope specifies the upgrade scope which upgrades are blocked by the + // exclusion. // // Possible values: // "NO_UPGRADES" - NO_UPGRADES excludes all upgrades, including patch - // upgrades and minor upgrades across control planes and nodes. This is - // the default exclusion behavior. - // "NO_MINOR_UPGRADES" - NO_MINOR_UPGRADES excludes all minor upgrades - // for the cluster, only patches are allowed. - // "NO_MINOR_OR_NODE_UPGRADES" - NO_MINOR_OR_NODE_UPGRADES excludes - // all minor upgrades for the cluster, and also exclude all node pool - // upgrades. Only control plane patches are allowed. + // upgrades and minor upgrades across control planes and nodes. This is the + // default exclusion behavior. + // "NO_MINOR_UPGRADES" - NO_MINOR_UPGRADES excludes all minor upgrades for + // the cluster, only patches are allowed. + // "NO_MINOR_OR_NODE_UPGRADES" - NO_MINOR_OR_NODE_UPGRADES excludes all minor + // upgrades for the cluster, and also exclude all node pool upgrades. Only + // control plane patches are allowed. Scope string `json:"scope,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Scope") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Scope") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Scope") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MaintenanceExclusionOptions) MarshalJSON() ([]byte, error) { type NoMethod MaintenanceExclusionOptions - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// MaintenancePolicy: MaintenancePolicy defines the maintenance policy -// to be used for the cluster. +// MaintenancePolicy: MaintenancePolicy defines the maintenance policy to be +// used for the cluster. type MaintenancePolicy struct { - // ResourceVersion: A hash identifying the version of this policy, so - // that updates to fields of the policy won't accidentally undo - // intermediate changes (and so that users of the API unaware of some - // fields won't accidentally remove other fields). Make a `get()` - // request to the cluster to get the current resource version and - // include it with requests to set the policy. + // ResourceVersion: A hash identifying the version of this policy, so that + // updates to fields of the policy won't accidentally undo intermediate changes + // (and so that users of the API unaware of some fields won't accidentally + // remove other fields). Make a `get()` request to the cluster to get the + // current resource version and include it with requests to set the policy. ResourceVersion string `json:"resourceVersion,omitempty"` - // Window: Specifies the maintenance window in which maintenance may be // performed. Window *MaintenanceWindow `json:"window,omitempty"` - // ForceSendFields is a list of field names (e.g. "ResourceVersion") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ResourceVersion") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ResourceVersion") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MaintenancePolicy) MarshalJSON() ([]byte, error) { type NoMethod MaintenancePolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// MaintenanceWindow: MaintenanceWindow defines the maintenance window -// to be used for the cluster. +// MaintenanceWindow: MaintenanceWindow defines the maintenance window to be +// used for the cluster. type MaintenanceWindow struct { - // DailyMaintenanceWindow: DailyMaintenanceWindow specifies a daily - // maintenance operation window. + // DailyMaintenanceWindow: DailyMaintenanceWindow specifies a daily maintenance + // operation window. DailyMaintenanceWindow *DailyMaintenanceWindow `json:"dailyMaintenanceWindow,omitempty"` - - // MaintenanceExclusions: Exceptions to maintenance window. - // Non-emergency maintenance should not occur in these windows. + // MaintenanceExclusions: Exceptions to maintenance window. Non-emergency + // maintenance should not occur in these windows. MaintenanceExclusions map[string]TimeWindow `json:"maintenanceExclusions,omitempty"` - - // RecurringWindow: RecurringWindow specifies some number of recurring - // time periods for maintenance to occur. The time windows may be - // overlapping. If no maintenance windows are set, maintenance can occur - // at any time. + // RecurringWindow: RecurringWindow specifies some number of recurring time + // periods for maintenance to occur. The time windows may be overlapping. If no + // maintenance windows are set, maintenance can occur at any time. RecurringWindow *RecurringTimeWindow `json:"recurringWindow,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "DailyMaintenanceWindow") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "DailyMaintenanceWindow") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DailyMaintenanceWindow") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "DailyMaintenanceWindow") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MaintenanceWindow) MarshalJSON() ([]byte, error) { type NoMethod MaintenanceWindow - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ManagedPrometheusConfig: ManagedPrometheusConfig defines the -// configuration for Google Cloud Managed Service for Prometheus. +// ManagedPrometheusConfig: ManagedPrometheusConfig defines the configuration +// for Google Cloud Managed Service for Prometheus. type ManagedPrometheusConfig struct { // Enabled: Enable Managed Collection. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ManagedPrometheusConfig) MarshalJSON() ([]byte, error) { type NoMethod ManagedPrometheusConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Master: Master is the configuration for components on master. @@ -4834,207 +3819,161 @@ type Master struct { } // MasterAuth: The authentication information for accessing the master -// endpoint. Authentication can be done using HTTP basic auth or using -// client certificates. +// endpoint. Authentication can be done using HTTP basic auth or using client +// certificates. type MasterAuth struct { - // ClientCertificate: [Output only] Base64-encoded public certificate - // used by clients to authenticate to the cluster endpoint. + // ClientCertificate: [Output only] Base64-encoded public certificate used by + // clients to authenticate to the cluster endpoint. ClientCertificate string `json:"clientCertificate,omitempty"` - - // ClientCertificateConfig: Configuration for client certificate - // authentication on the cluster. For clusters before v1.12, if no - // configuration is specified, a client certificate is issued. + // ClientCertificateConfig: Configuration for client certificate authentication + // on the cluster. For clusters before v1.12, if no configuration is specified, + // a client certificate is issued. ClientCertificateConfig *ClientCertificateConfig `json:"clientCertificateConfig,omitempty"` - - // ClientKey: [Output only] Base64-encoded private key used by clients - // to authenticate to the cluster endpoint. - ClientKey string `json:"clientKey,omitempty"` - + // ClientKey: [Output only] Base64-encoded private key used by clients to + // authenticate to the cluster endpoint. + ClientKey string `json:"clientKey,omitempty"` ClusterCaCertificate string `json:"clusterCaCertificate,omitempty"` - - // Password: The password to use for HTTP basic authentication to the - // master endpoint. Because the master endpoint is open to the Internet, - // you should create a strong password. If a password is provided for - // cluster creation, username must be non-empty. Warning: basic - // authentication is deprecated, and will be removed in GKE control - // plane versions 1.19 and newer. For a list of recommended - // authentication methods, see: + // Password: The password to use for HTTP basic authentication to the master + // endpoint. Because the master endpoint is open to the Internet, you should + // create a strong password. If a password is provided for cluster creation, + // username must be non-empty. Warning: basic authentication is deprecated, and + // will be removed in GKE control plane versions 1.19 and newer. For a list of + // recommended authentication methods, see: // https://cloud.google.com/kubernetes-engine/docs/how-to/api-server-authentication Password string `json:"password,omitempty"` - - // Username: The username to use for HTTP basic authentication to the - // master endpoint. For clusters v1.6.0 and later, basic authentication - // can be disabled by leaving username unspecified (or setting it to the - // empty string). Warning: basic authentication is deprecated, and will - // be removed in GKE control plane versions 1.19 and newer. For a list - // of recommended authentication methods, see: + // Username: The username to use for HTTP basic authentication to the master + // endpoint. For clusters v1.6.0 and later, basic authentication can be + // disabled by leaving username unspecified (or setting it to the empty + // string). Warning: basic authentication is deprecated, and will be removed in + // GKE control plane versions 1.19 and newer. For a list of recommended + // authentication methods, see: // https://cloud.google.com/kubernetes-engine/docs/how-to/api-server-authentication Username string `json:"username,omitempty"` - - // ForceSendFields is a list of field names (e.g. "ClientCertificate") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "ClientCertificate") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClientCertificate") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ClientCertificate") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MasterAuth) MarshalJSON() ([]byte, error) { type NoMethod MasterAuth - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // MasterAuthorizedNetworksConfig: Configuration options for the master // authorized networks feature. Enabled master authorized networks will -// disallow all external traffic to access Kubernetes master through -// HTTPS except traffic from the given CIDR blocks, Google Compute -// Engine Public IPs and Google Prod IPs. +// disallow all external traffic to access Kubernetes master through HTTPS +// except traffic from the given CIDR blocks, Google Compute Engine Public IPs +// and Google Prod IPs. type MasterAuthorizedNetworksConfig struct { - // CidrBlocks: cidr_blocks define up to 10 external networks that could - // access Kubernetes master through HTTPS. + // CidrBlocks: cidr_blocks define up to 10 external networks that could access + // Kubernetes master through HTTPS. CidrBlocks []*CidrBlock `json:"cidrBlocks,omitempty"` - // Enabled: Whether or not master authorized networks is enabled. Enabled bool `json:"enabled,omitempty"` - - // GcpPublicCidrsAccessEnabled: Whether master is accessbile via Google - // Compute Engine Public IP addresses. + // GcpPublicCidrsAccessEnabled: Whether master is accessbile via Google Compute + // Engine Public IP addresses. GcpPublicCidrsAccessEnabled bool `json:"gcpPublicCidrsAccessEnabled,omitempty"` - // ForceSendFields is a list of field names (e.g. "CidrBlocks") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CidrBlocks") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CidrBlocks") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MasterAuthorizedNetworksConfig) MarshalJSON() ([]byte, error) { type NoMethod MasterAuthorizedNetworksConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // MaxPodsConstraint: Constraints applied to pods. type MaxPodsConstraint struct { // MaxPodsPerNode: Constraint enforced on the max num of pods per node. MaxPodsPerNode int64 `json:"maxPodsPerNode,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "MaxPodsPerNode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MaxPodsPerNode") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "MaxPodsPerNode") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MaxPodsConstraint) MarshalJSON() ([]byte, error) { type NoMethod MaxPodsConstraint - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// MeshCertificates: Configuration for issuance of mTLS keys and -// certificates to Kubernetes pods. +// MeshCertificates: Configuration for issuance of mTLS keys and certificates +// to Kubernetes pods. type MeshCertificates struct { - // EnableCertificates: enable_certificates controls issuance of workload - // mTLS certificates. If set, the GKE Workload Identity Certificates - // controller and node agent will be deployed in the cluster, which can - // then be configured by creating a WorkloadCertificateConfig Custom - // Resource. Requires Workload Identity (workload_pool must be - // non-empty). + // EnableCertificates: enable_certificates controls issuance of workload mTLS + // certificates. If set, the GKE Workload Identity Certificates controller and + // node agent will be deployed in the cluster, which can then be configured by + // creating a WorkloadCertificateConfig Custom Resource. Requires Workload + // Identity (workload_pool must be non-empty). EnableCertificates bool `json:"enableCertificates,omitempty"` - - // ForceSendFields is a list of field names (e.g. "EnableCertificates") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "EnableCertificates") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnableCertificates") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EnableCertificates") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MeshCertificates) MarshalJSON() ([]byte, error) { type NoMethod MeshCertificates - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Metric: Progress metric is (string, int|float|string) pair. type Metric struct { // DoubleValue: For metrics with floating point value. DoubleValue float64 `json:"doubleValue,omitempty"` - // IntValue: For metrics with integer value. IntValue int64 `json:"intValue,omitempty,string"` - // Name: Required. Metric name, e.g., "nodes total", "percent done". Name string `json:"name,omitempty"` - - // StringValue: For metrics with custom values (ratios, visual progress, - // etc.). + // StringValue: For metrics with custom values (ratios, visual progress, etc.). StringValue string `json:"stringValue,omitempty"` - // ForceSendFields is a list of field names (e.g. "DoubleValue") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DoubleValue") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DoubleValue") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Metric) MarshalJSON() ([]byte, error) { type NoMethod Metric - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } func (s *Metric) UnmarshalJSON(data []byte) error { @@ -5051,17 +3990,16 @@ func (s *Metric) UnmarshalJSON(data []byte) error { return nil } -// MonitoringComponentConfig: MonitoringComponentConfig is cluster -// monitoring component configuration. +// MonitoringComponentConfig: MonitoringComponentConfig is cluster monitoring +// component configuration. type MonitoringComponentConfig struct { - // EnableComponents: Select components to collect metrics. An empty set - // would disable all monitoring. + // EnableComponents: Select components to collect metrics. An empty set would + // disable all monitoring. // // Possible values: // "COMPONENT_UNSPECIFIED" - Default value. This shouldn't be used. // "SYSTEM_COMPONENTS" - system components - // "WORKLOADS" - Deprecated: Use Google Cloud Managed Service for - // Prometheus. + // "WORKLOADS" - Deprecated: Use Google Cloud Managed Service for Prometheus. // "APISERVER" - kube-apiserver // "SCHEDULER" - kube-scheduler // "CONTROLLER_MANAGER" - kube-controller-manager @@ -5072,68 +4010,52 @@ type MonitoringComponentConfig struct { // "DEPLOYMENT" - Deployment // "STATEFULSET" - Statefulset EnableComponents []string `json:"enableComponents,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnableComponents") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnableComponents") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EnableComponents") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *MonitoringComponentConfig) MarshalJSON() ([]byte, error) { type NoMethod MonitoringComponentConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// MonitoringConfig: MonitoringConfig is cluster monitoring -// configuration. +// MonitoringConfig: MonitoringConfig is cluster monitoring configuration. type MonitoringConfig struct { - // AdvancedDatapathObservabilityConfig: Configuration of Advanced - // Datapath Observability features. + // AdvancedDatapathObservabilityConfig: Configuration of Advanced Datapath + // Observability features. AdvancedDatapathObservabilityConfig *AdvancedDatapathObservabilityConfig `json:"advancedDatapathObservabilityConfig,omitempty"` - // ComponentConfig: Monitoring components configuration ComponentConfig *MonitoringComponentConfig `json:"componentConfig,omitempty"` - - // ManagedPrometheusConfig: Enable Google Cloud Managed Service for - // Prometheus in the cluster. + // ManagedPrometheusConfig: Enable Google Cloud Managed Service for Prometheus + // in the cluster. ManagedPrometheusConfig *ManagedPrometheusConfig `json:"managedPrometheusConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "AdvancedDatapathObservabilityConfig") to unconditionally include in - // API requests. By default, fields with empty or default values are - // omitted from API requests. However, any non-pointer, non-interface - // field appearing in ForceSendFields will be sent to the server - // regardless of whether the field is empty or not. This may be used to - // include empty fields in Patch requests. + // "AdvancedDatapathObservabilityConfig") to unconditionally include in API + // requests. By default, fields with empty or default values are omitted from + // API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. - // "AdvancedDatapathObservabilityConfig") to include in API requests - // with the JSON null value. By default, fields with empty values are - // omitted from API requests. However, any field with an empty value - // appearing in NullFields will be sent to the server as null. It is an - // error if a field in this list has a non-empty value. This may be used - // to include null fields in Patch requests. + // "AdvancedDatapathObservabilityConfig") to include in API requests with the + // JSON null value. By default, fields with empty values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-NullFields for + // more details. NullFields []string `json:"-"` } func (s *MonitoringConfig) MarshalJSON() ([]byte, error) { type NoMethod MonitoringConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NetworkConfig: NetworkConfig reports the relative names of network & @@ -5144,161 +4066,122 @@ type NetworkConfig struct { // // Possible values: // "DATAPATH_PROVIDER_UNSPECIFIED" - Default value. - // "LEGACY_DATAPATH" - Use the IPTables implementation based on - // kube-proxy. - // "ADVANCED_DATAPATH" - Use the eBPF based GKE Dataplane V2 with - // additional features. See the [GKE Dataplane V2 - // documentation](https://cloud.google.com/kubernetes-engine/docs/how-to/ - // dataplane-v2) for more. + // "LEGACY_DATAPATH" - Use the IPTables implementation based on kube-proxy. + // "ADVANCED_DATAPATH" - Use the eBPF based GKE Dataplane V2 with additional + // features. See the [GKE Dataplane V2 + // documentation](https://cloud.google.com/kubernetes-engine/docs/how-to/datapla + // ne-v2) for more. DatapathProvider string `json:"datapathProvider,omitempty"` - - // DefaultSnatStatus: Whether the cluster disables default in-node sNAT - // rules. In-node sNAT rules will be disabled when default_snat_status - // is disabled. When disabled is set to false, default IP masquerade - // rules will be applied to the nodes to prevent sNAT on cluster - // internal traffic. + // DefaultSnatStatus: Whether the cluster disables default in-node sNAT rules. + // In-node sNAT rules will be disabled when default_snat_status is disabled. + // When disabled is set to false, default IP masquerade rules will be applied + // to the nodes to prevent sNAT on cluster internal traffic. DefaultSnatStatus *DefaultSnatStatus `json:"defaultSnatStatus,omitempty"` - // DnsConfig: DNSConfig contains clusterDNS config for this cluster. DnsConfig *DNSConfig `json:"dnsConfig,omitempty"` - - // EnableCiliumClusterwideNetworkPolicy: Whether - // CiliumClusterWideNetworkPolicy is enabled on this cluster. + // EnableCiliumClusterwideNetworkPolicy: Whether CiliumClusterWideNetworkPolicy + // is enabled on this cluster. EnableCiliumClusterwideNetworkPolicy bool `json:"enableCiliumClusterwideNetworkPolicy,omitempty"` - - // EnableFqdnNetworkPolicy: Whether FQDN Network Policy is enabled on - // this cluster. + // EnableFqdnNetworkPolicy: Whether FQDN Network Policy is enabled on this + // cluster. EnableFqdnNetworkPolicy bool `json:"enableFqdnNetworkPolicy,omitempty"` - - // EnableIntraNodeVisibility: Whether Intra-node visibility is enabled - // for this cluster. This makes same node pod to pod traffic visible for - // VPC network. + // EnableIntraNodeVisibility: Whether Intra-node visibility is enabled for this + // cluster. This makes same node pod to pod traffic visible for VPC network. EnableIntraNodeVisibility bool `json:"enableIntraNodeVisibility,omitempty"` - - // EnableL4ilbSubsetting: Whether L4ILB Subsetting is enabled for this - // cluster. + // EnableL4ilbSubsetting: Whether L4ILB Subsetting is enabled for this cluster. EnableL4ilbSubsetting bool `json:"enableL4ilbSubsetting,omitempty"` - - // EnableMultiNetworking: Whether multi-networking is enabled for this - // cluster. + // EnableMultiNetworking: Whether multi-networking is enabled for this cluster. EnableMultiNetworking bool `json:"enableMultiNetworking,omitempty"` - - // GatewayApiConfig: GatewayAPIConfig contains the desired config of - // Gateway API on this cluster. + // GatewayApiConfig: GatewayAPIConfig contains the desired config of Gateway + // API on this cluster. GatewayApiConfig *GatewayAPIConfig `json:"gatewayApiConfig,omitempty"` - - // InTransitEncryptionConfig: Specify the details of in-transit - // encryption. + // InTransitEncryptionConfig: Specify the details of in-transit encryption. // // Possible values: - // "IN_TRANSIT_ENCRYPTION_CONFIG_UNSPECIFIED" - Unspecified, will be - // inferred as default - IN_TRANSIT_ENCRYPTION_UNSPECIFIED. - // "IN_TRANSIT_ENCRYPTION_DISABLED" - In-transit encryption is - // disabled. + // "IN_TRANSIT_ENCRYPTION_CONFIG_UNSPECIFIED" - Unspecified, will be inferred + // as default - IN_TRANSIT_ENCRYPTION_UNSPECIFIED. + // "IN_TRANSIT_ENCRYPTION_DISABLED" - In-transit encryption is disabled. // "IN_TRANSIT_ENCRYPTION_INTER_NODE_TRANSPARENT" - Data in-transit is // encrypted using inter-node transparent encryption. InTransitEncryptionConfig string `json:"inTransitEncryptionConfig,omitempty"` - // Network: Output only. The relative name of the Google Compute Engine - // network(https://cloud.google.com/compute/docs/networks-and-firewalls#n - // etworks) to which the cluster is connected. Example: + // network(https://cloud.google.com/compute/docs/networks-and-firewalls#networks + // ) to which the cluster is connected. Example: // projects/my-project/global/networks/my-network Network string `json:"network,omitempty"` - // NetworkPerformanceConfig: Network bandwidth tier configuration. NetworkPerformanceConfig *ClusterNetworkPerformanceConfig `json:"networkPerformanceConfig,omitempty"` - - // PrivateIpv6GoogleAccess: The desired state of IPv6 connectivity to - // Google Services. By default, no private IPv6 access to or from Google - // Services (all access will be via IPv4) + // PrivateIpv6GoogleAccess: The desired state of IPv6 connectivity to Google + // Services. By default, no private IPv6 access to or from Google Services (all + // access will be via IPv4) // // Possible values: - // "PRIVATE_IPV6_GOOGLE_ACCESS_UNSPECIFIED" - Default value. Same as - // DISABLED - // "PRIVATE_IPV6_GOOGLE_ACCESS_DISABLED" - No private access to or - // from Google Services - // "PRIVATE_IPV6_GOOGLE_ACCESS_TO_GOOGLE" - Enables private IPv6 - // access to Google Services from GKE - // "PRIVATE_IPV6_GOOGLE_ACCESS_BIDIRECTIONAL" - Enables private IPv6 - // access to and from Google Services + // "PRIVATE_IPV6_GOOGLE_ACCESS_UNSPECIFIED" - Default value. Same as DISABLED + // "PRIVATE_IPV6_GOOGLE_ACCESS_DISABLED" - No private access to or from + // Google Services + // "PRIVATE_IPV6_GOOGLE_ACCESS_TO_GOOGLE" - Enables private IPv6 access to + // Google Services from GKE + // "PRIVATE_IPV6_GOOGLE_ACCESS_BIDIRECTIONAL" - Enables private IPv6 access + // to and from Google Services PrivateIpv6GoogleAccess string `json:"privateIpv6GoogleAccess,omitempty"` - - // ServiceExternalIpsConfig: ServiceExternalIPsConfig specifies if - // services with externalIPs field are blocked or not. + // ServiceExternalIpsConfig: ServiceExternalIPsConfig specifies if services + // with externalIPs field are blocked or not. ServiceExternalIpsConfig *ServiceExternalIPsConfig `json:"serviceExternalIpsConfig,omitempty"` - - // Subnetwork: Output only. The relative name of the Google Compute - // Engine subnetwork (https://cloud.google.com/compute/docs/vpc) to - // which the cluster is connected. Example: + // Subnetwork: Output only. The relative name of the Google Compute Engine + // subnetwork (https://cloud.google.com/compute/docs/vpc) to which the cluster + // is connected. Example: // projects/my-project/regions/us-central1/subnetworks/my-subnet Subnetwork string `json:"subnetwork,omitempty"` - // ForceSendFields is a list of field names (e.g. "DatapathProvider") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DatapathProvider") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "DatapathProvider") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NetworkConfig) MarshalJSON() ([]byte, error) { type NoMethod NetworkConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NetworkPerformanceConfig: Configuration of all network bandwidth -// tiers +// NetworkPerformanceConfig: Configuration of all network bandwidth tiers type NetworkPerformanceConfig struct { - // ExternalIpEgressBandwidthTier: Specifies the network bandwidth tier - // for the NodePool for traffic to external/public IP addresses. + // ExternalIpEgressBandwidthTier: Specifies the network bandwidth tier for the + // NodePool for traffic to external/public IP addresses. // // Possible values: // "TIER_UNSPECIFIED" - Default value // "TIER_1" - Higher bandwidth, actual values based on VM size. ExternalIpEgressBandwidthTier string `json:"externalIpEgressBandwidthTier,omitempty"` - - // TotalEgressBandwidthTier: Specifies the total network bandwidth tier - // for the NodePool. + // TotalEgressBandwidthTier: Specifies the total network bandwidth tier for the + // NodePool. // // Possible values: // "TIER_UNSPECIFIED" - Default value // "TIER_1" - Higher bandwidth, actual values based on VM size. TotalEgressBandwidthTier string `json:"totalEgressBandwidthTier,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "ExternalIpEgressBandwidthTier") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // "ExternalIpEgressBandwidthTier") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields + // for more details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "ExternalIpEgressBandwidthTier") to include in API requests with the - // JSON null value. By default, fields with empty values are omitted - // from API requests. However, any field with an empty value appearing - // in NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "ExternalIpEgressBandwidthTier") + // to include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NetworkPerformanceConfig) MarshalJSON() ([]byte, error) { type NoMethod NetworkPerformanceConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NetworkPolicy: Configuration options for the NetworkPolicy feature. @@ -5306,104 +4189,84 @@ func (s *NetworkPerformanceConfig) MarshalJSON() ([]byte, error) { type NetworkPolicy struct { // Enabled: Whether network policy is enabled on the cluster. Enabled bool `json:"enabled,omitempty"` - // Provider: The selected network policy provider. // // Possible values: // "PROVIDER_UNSPECIFIED" - Not set // "CALICO" - Tigera (Calico Felix). Provider string `json:"provider,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NetworkPolicy) MarshalJSON() ([]byte, error) { type NoMethod NetworkPolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NetworkPolicyConfig: Configuration for NetworkPolicy. This only -// tracks whether the addon is enabled or not on the Master, it does not -// track whether network policy is enabled for the nodes. +// NetworkPolicyConfig: Configuration for NetworkPolicy. This only tracks +// whether the addon is enabled or not on the Master, it does not track whether +// network policy is enabled for the nodes. type NetworkPolicyConfig struct { // Disabled: Whether NetworkPolicy is enabled for this cluster. Disabled bool `json:"disabled,omitempty"` - // ForceSendFields is a list of field names (e.g. "Disabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NetworkPolicyConfig) MarshalJSON() ([]byte, error) { type NoMethod NetworkPolicyConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NetworkTags: Collection of Compute Engine network tags that can be -// applied to a node's underlying VM instance. (See `tags` field in -// `NodeConfig` (/kubernetes-engine/docs/reference/rest/v1/NodeConfig)). +// NetworkTags: Collection of Compute Engine network tags that can be applied +// to a node's underlying VM instance. (See `tags` field in `NodeConfig` +// (/kubernetes-engine/docs/reference/rest/v1/NodeConfig)). type NetworkTags struct { // Tags: List of network tags. Tags []string `json:"tags,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Tags") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Tags") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Tags") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Tags") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NetworkTags) MarshalJSON() ([]byte, error) { type NoMethod NetworkTags - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodeAffinity: Specifies the NodeAffinity key, values, and affinity -// operator according to shared sole tenant node group affinities +// NodeAffinity: Specifies the NodeAffinity key, values, and affinity operator +// according to shared sole tenant node group affinities // (https://cloud.google.com/compute/docs/nodes/sole-tenant-nodes#node_affinity_and_anti-affinity). type NodeAffinity struct { // Key: Key for NodeAffinity. Key string `json:"key,omitempty"` - // Operator: Operator for NodeAffinity. // // Possible values: @@ -5411,372 +4274,283 @@ type NodeAffinity struct { // "IN" - Affinity operator. // "NOT_IN" - Anti-affinity operator. Operator string `json:"operator,omitempty"` - // Values: Values for NodeAffinity. Values []string `json:"values,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Key") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Key") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Key") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Key") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeAffinity) MarshalJSON() ([]byte, error) { type NoMethod NodeAffinity - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodeConfig: Parameters that describe the nodes in a cluster. GKE -// Autopilot clusters do not recognize parameters in `NodeConfig`. Use +// NodeConfig: Parameters that describe the nodes in a cluster. GKE Autopilot +// clusters do not recognize parameters in `NodeConfig`. Use // AutoprovisioningNodePoolDefaults instead. type NodeConfig struct { - // Accelerators: A list of hardware accelerators to be attached to each - // node. See https://cloud.google.com/compute/docs/gpus for more - // information about support for GPUs. + // Accelerators: A list of hardware accelerators to be attached to each node. + // See https://cloud.google.com/compute/docs/gpus for more information about + // support for GPUs. Accelerators []*AcceleratorConfig `json:"accelerators,omitempty"` - // AdvancedMachineFeatures: Advanced features for the Compute Engine VM. AdvancedMachineFeatures *AdvancedMachineFeatures `json:"advancedMachineFeatures,omitempty"` - - // BootDiskKmsKey: The Customer Managed Encryption Key used to encrypt - // the boot disk attached to each node in the node pool. This should be - // of the form - // projects/[KEY_PROJECT_ID]/locations/[LOCATION]/keyRings/[RING_NAME]/cr - // yptoKeys/[KEY_NAME]. For more information about protecting resources - // with Cloud KMS Keys please see: + // BootDiskKmsKey: The Customer Managed Encryption Key used to encrypt the + // boot disk attached to each node in the node pool. This should be of the form + // projects/[KEY_PROJECT_ID]/locations/[LOCATION]/keyRings/[RING_NAME]/cryptoKey + // s/[KEY_NAME]. For more information about protecting resources with Cloud KMS + // Keys please see: // https://cloud.google.com/compute/docs/disks/customer-managed-encryption BootDiskKmsKey string `json:"bootDiskKmsKey,omitempty"` - - // ConfidentialNodes: Confidential nodes config. All the nodes in the - // node pool will be Confidential VM once enabled. + // ConfidentialNodes: Confidential nodes config. All the nodes in the node pool + // will be Confidential VM once enabled. ConfidentialNodes *ConfidentialNodes `json:"confidentialNodes,omitempty"` - // ContainerdConfig: Parameters for containerd customization. ContainerdConfig *ContainerdConfig `json:"containerdConfig,omitempty"` - - // DiskSizeGb: Size of the disk attached to each node, specified in GB. - // The smallest allowed disk size is 10GB. If unspecified, the default - // disk size is 100GB. + // DiskSizeGb: Size of the disk attached to each node, specified in GB. The + // smallest allowed disk size is 10GB. If unspecified, the default disk size is + // 100GB. DiskSizeGb int64 `json:"diskSizeGb,omitempty"` - // DiskType: Type of the disk attached to each node (e.g. 'pd-standard', // 'pd-ssd' or 'pd-balanced') If unspecified, the default disk type is // 'pd-standard' DiskType string `json:"diskType,omitempty"` - // EnableConfidentialStorage: Optional. Reserved for future use. EnableConfidentialStorage bool `json:"enableConfidentialStorage,omitempty"` - - // EphemeralStorageConfig: Parameters for the ephemeral storage - // filesystem. If unspecified, ephemeral storage is backed by the boot - // disk. + // EphemeralStorageConfig: Parameters for the ephemeral storage filesystem. If + // unspecified, ephemeral storage is backed by the boot disk. EphemeralStorageConfig *EphemeralStorageConfig `json:"ephemeralStorageConfig,omitempty"` - - // EphemeralStorageLocalSsdConfig: Parameters for the node ephemeral - // storage using Local SSDs. If unspecified, ephemeral storage is backed - // by the boot disk. This field is functionally equivalent to the - // ephemeral_storage_config + // EphemeralStorageLocalSsdConfig: Parameters for the node ephemeral storage + // using Local SSDs. If unspecified, ephemeral storage is backed by the boot + // disk. This field is functionally equivalent to the ephemeral_storage_config EphemeralStorageLocalSsdConfig *EphemeralStorageLocalSsdConfig `json:"ephemeralStorageLocalSsdConfig,omitempty"` - // FastSocket: Enable or disable NCCL fast socket for the node pool. FastSocket *FastSocket `json:"fastSocket,omitempty"` - // GcfsConfig: GCFS (Google Container File System) configs. GcfsConfig *GcfsConfig `json:"gcfsConfig,omitempty"` - // Gvnic: Enable or disable gvnic on the node pool. Gvnic *VirtualNIC `json:"gvnic,omitempty"` - // HostMaintenancePolicy: HostMaintenancePolicy contains the desired // maintenance policy for the Google Compute Engine hosts. HostMaintenancePolicy *HostMaintenancePolicy `json:"hostMaintenancePolicy,omitempty"` - - // ImageType: The image type to use for this node. Note that for a given - // image type, the latest version of it will be used. Please see - // https://cloud.google.com/kubernetes-engine/docs/concepts/node-images - // for available image types. + // ImageType: The image type to use for this node. Note that for a given image + // type, the latest version of it will be used. Please see + // https://cloud.google.com/kubernetes-engine/docs/concepts/node-images for + // available image types. ImageType string `json:"imageType,omitempty"` - // KubeletConfig: Node kubelet configs. KubeletConfig *NodeKubeletConfig `json:"kubeletConfig,omitempty"` - - // Labels: The map of Kubernetes labels (key/value pairs) to be applied - // to each node. These will added in addition to any default label(s) - // that Kubernetes may apply to the node. In case of conflict in label - // keys, the applied set may differ depending on the Kubernetes version - // -- it's best to assume the behavior is undefined and conflicts should - // be avoided. For more information, including usage and the valid - // values, see: + // Labels: The map of Kubernetes labels (key/value pairs) to be applied to each + // node. These will added in addition to any default label(s) that Kubernetes + // may apply to the node. In case of conflict in label keys, the applied set + // may differ depending on the Kubernetes version -- it's best to assume the + // behavior is undefined and conflicts should be avoided. For more information, + // including usage and the valid values, see: // https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ Labels map[string]string `json:"labels,omitempty"` - // LinuxNodeConfig: Parameters that can be configured on Linux nodes. LinuxNodeConfig *LinuxNodeConfig `json:"linuxNodeConfig,omitempty"` - - // LocalNvmeSsdBlockConfig: Parameters for using raw-block Local NVMe - // SSDs. + // LocalNvmeSsdBlockConfig: Parameters for using raw-block Local NVMe SSDs. LocalNvmeSsdBlockConfig *LocalNvmeSsdBlockConfig `json:"localNvmeSsdBlockConfig,omitempty"` - - // LocalSsdCount: The number of local SSD disks to be attached to the - // node. The limit for this value is dependent upon the maximum number - // of disks available on a machine per zone. See: - // https://cloud.google.com/compute/docs/disks/local-ssd for more - // information. + // LocalSsdCount: The number of local SSD disks to be attached to the node. The + // limit for this value is dependent upon the maximum number of disks available + // on a machine per zone. See: + // https://cloud.google.com/compute/docs/disks/local-ssd for more information. LocalSsdCount int64 `json:"localSsdCount,omitempty"` - // LoggingConfig: Logging configuration. LoggingConfig *NodePoolLoggingConfig `json:"loggingConfig,omitempty"` - // MachineType: The name of a Google Compute Engine machine type - // (https://cloud.google.com/compute/docs/machine-types). If - // unspecified, the default machine type is `e2-medium`. + // (https://cloud.google.com/compute/docs/machine-types). If unspecified, the + // default machine type is `e2-medium`. MachineType string `json:"machineType,omitempty"` - - // Metadata: The metadata key/value pairs assigned to instances in the - // cluster. Keys must conform to the regexp `[a-zA-Z0-9-_]+` and be less - // than 128 bytes in length. These are reflected as part of a URL in the - // metadata server. Additionally, to avoid ambiguity, keys must not - // conflict with any other metadata keys for the project or be one of - // the reserved keys: - "cluster-location" - "cluster-name" - - // "cluster-uid" - "configure-sh" - "containerd-configure-sh" - - // "enable-oslogin" - "gci-ensure-gke-docker" - "gci-metrics-enabled" - - // "gci-update-strategy" - "instance-template" - "kube-env" - - // "startup-script" - "user-data" - "disable-address-manager" - - // "windows-startup-script-ps1" - "common-psm1" - "k8s-node-setup-psm1" - // - "install-ssh-psm1" - "user-profile-psm1" Values are free-form - // strings, and only have meaning as interpreted by the image running in - // the instance. The only restriction placed on them is that each - // value's size must be less than or equal to 32 KB. The total size of - // all keys and values must be less than 512 KB. + // Metadata: The metadata key/value pairs assigned to instances in the cluster. + // Keys must conform to the regexp `[a-zA-Z0-9-_]+` and be less than 128 bytes + // in length. These are reflected as part of a URL in the metadata server. + // Additionally, to avoid ambiguity, keys must not conflict with any other + // metadata keys for the project or be one of the reserved keys: - + // "cluster-location" - "cluster-name" - "cluster-uid" - "configure-sh" - + // "containerd-configure-sh" - "enable-oslogin" - "gci-ensure-gke-docker" - + // "gci-metrics-enabled" - "gci-update-strategy" - "instance-template" - + // "kube-env" - "startup-script" - "user-data" - "disable-address-manager" - + // "windows-startup-script-ps1" - "common-psm1" - "k8s-node-setup-psm1" - + // "install-ssh-psm1" - "user-profile-psm1" Values are free-form strings, and + // only have meaning as interpreted by the image running in the instance. The + // only restriction placed on them is that each value's size must be less than + // or equal to 32 KB. The total size of all keys and values must be less than + // 512 KB. Metadata map[string]string `json:"metadata,omitempty"` - // MinCpuPlatform: Minimum CPU platform to be used by this instance. The - // instance may be scheduled on the specified or newer CPU platform. - // Applicable values are the friendly names of CPU platforms, such as - // `minCpuPlatform: "Intel Haswell" or `minCpuPlatform: "Intel Sandy - // Bridge". For more information, read how to specify min CPU platform + // instance may be scheduled on the specified or newer CPU platform. Applicable + // values are the friendly names of CPU platforms, such as `minCpuPlatform: + // "Intel Haswell" or `minCpuPlatform: "Intel Sandy Bridge". For more + // information, read how to specify min CPU platform // (https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform). MinCpuPlatform string `json:"minCpuPlatform,omitempty"` - - // NodeGroup: Setting this field will assign instances of this pool to - // run on the specified node group. This is useful for running workloads - // on sole tenant nodes + // NodeGroup: Setting this field will assign instances of this pool to run on + // the specified node group. This is useful for running workloads on sole + // tenant nodes // (https://cloud.google.com/compute/docs/nodes/sole-tenant-nodes). NodeGroup string `json:"nodeGroup,omitempty"` - - // OauthScopes: The set of Google API scopes to be made available on all - // of the node VMs under the "default" service account. The following - // scopes are recommended, but not required, and by default are not - // included: * `https://www.googleapis.com/auth/compute` is required for - // mounting persistent storage on your nodes. * - // `https://www.googleapis.com/auth/devstorage.read_only` is required - // for communicating with **gcr.io** (the Google Container Registry - // (https://cloud.google.com/container-registry/)). If unspecified, no - // scopes are added, unless Cloud Logging or Cloud Monitoring are - // enabled, in which case their required scopes will be added. + // OauthScopes: The set of Google API scopes to be made available on all of the + // node VMs under the "default" service account. The following scopes are + // recommended, but not required, and by default are not included: * + // `https://www.googleapis.com/auth/compute` is required for mounting + // persistent storage on your nodes. * + // `https://www.googleapis.com/auth/devstorage.read_only` is required for + // communicating with **gcr.io** (the Google Container Registry + // (https://cloud.google.com/container-registry/)). If unspecified, no scopes + // are added, unless Cloud Logging or Cloud Monitoring are enabled, in which + // case their required scopes will be added. OauthScopes []string `json:"oauthScopes,omitempty"` - - // Preemptible: Whether the nodes are created as preemptible VM - // instances. See: + // Preemptible: Whether the nodes are created as preemptible VM instances. See: // https://cloud.google.com/compute/docs/instances/preemptible for more // information about preemptible VM instances. Preemptible bool `json:"preemptible,omitempty"` - - // ReservationAffinity: The optional reservation affinity. Setting this - // field will apply the specified Zonal Compute Reservation + // ReservationAffinity: The optional reservation affinity. Setting this field + // will apply the specified Zonal Compute Reservation // (https://cloud.google.com/compute/docs/instances/reserving-zonal-resources) // to this node pool. ReservationAffinity *ReservationAffinity `json:"reservationAffinity,omitempty"` - - // ResourceLabels: The resource labels for the node pool to use to - // annotate any related Google Compute Engine resources. + // ResourceLabels: The resource labels for the node pool to use to annotate any + // related Google Compute Engine resources. ResourceLabels map[string]string `json:"resourceLabels,omitempty"` - - // ResourceManagerTags: A map of resource manager tag keys and values to - // be attached to the nodes. + // ResourceManagerTags: A map of resource manager tag keys and values to be + // attached to the nodes. ResourceManagerTags *ResourceManagerTags `json:"resourceManagerTags,omitempty"` - // SandboxConfig: Sandbox configuration for this node. SandboxConfig *SandboxConfig `json:"sandboxConfig,omitempty"` - // SecondaryBootDiskUpdateStrategy: Secondary boot disk update strategy. SecondaryBootDiskUpdateStrategy *SecondaryBootDiskUpdateStrategy `json:"secondaryBootDiskUpdateStrategy,omitempty"` - - // SecondaryBootDisks: List of secondary boot disks attached to the - // nodes. + // SecondaryBootDisks: List of secondary boot disks attached to the nodes. SecondaryBootDisks []*SecondaryBootDisk `json:"secondaryBootDisks,omitempty"` - - // ServiceAccount: The Google Cloud Platform Service Account to be used - // by the node VMs. Specify the email address of the Service Account; - // otherwise, if no Service Account is specified, the "default" service - // account is used. + // ServiceAccount: The Google Cloud Platform Service Account to be used by the + // node VMs. Specify the email address of the Service Account; otherwise, if no + // Service Account is specified, the "default" service account is used. ServiceAccount string `json:"serviceAccount,omitempty"` - // ShieldedInstanceConfig: Shielded Instance options. ShieldedInstanceConfig *ShieldedInstanceConfig `json:"shieldedInstanceConfig,omitempty"` - - // SoleTenantConfig: Parameters for node pools to be backed by shared - // sole tenant node groups. + // SoleTenantConfig: Parameters for node pools to be backed by shared sole + // tenant node groups. SoleTenantConfig *SoleTenantConfig `json:"soleTenantConfig,omitempty"` - - // Spot: Spot flag for enabling Spot VM, which is a rebrand of the - // existing preemptible flag. + // Spot: Spot flag for enabling Spot VM, which is a rebrand of the existing + // preemptible flag. Spot bool `json:"spot,omitempty"` - - // Tags: The list of instance tags applied to all nodes. Tags are used - // to identify valid sources or targets for network firewalls and are - // specified by the client during cluster or node pool creation. Each - // tag within the list must comply with RFC1035. + // Tags: The list of instance tags applied to all nodes. Tags are used to + // identify valid sources or targets for network firewalls and are specified by + // the client during cluster or node pool creation. Each tag within the list + // must comply with RFC1035. Tags []string `json:"tags,omitempty"` - - // Taints: List of kubernetes taints to be applied to each node. For - // more information, including usage and the valid values, see: + // Taints: List of kubernetes taints to be applied to each node. For more + // information, including usage and the valid values, see: // https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ Taints []*NodeTaint `json:"taints,omitempty"` - - // WindowsNodeConfig: Parameters that can be configured on Windows - // nodes. + // WindowsNodeConfig: Parameters that can be configured on Windows nodes. WindowsNodeConfig *WindowsNodeConfig `json:"windowsNodeConfig,omitempty"` - - // WorkloadMetadataConfig: The workload metadata configuration for this - // node. + // WorkloadMetadataConfig: The workload metadata configuration for this node. WorkloadMetadataConfig *WorkloadMetadataConfig `json:"workloadMetadataConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "Accelerators") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Accelerators") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Accelerators") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeConfig) MarshalJSON() ([]byte, error) { type NoMethod NodeConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NodeConfigDefaults: Subset of NodeConfig message that has defaults. type NodeConfigDefaults struct { // ContainerdConfig: Parameters for containerd customization. ContainerdConfig *ContainerdConfig `json:"containerdConfig,omitempty"` - - // GcfsConfig: GCFS (Google Container File System, also known as - // Riptide) options. + // GcfsConfig: GCFS (Google Container File System, also known as Riptide) + // options. GcfsConfig *GcfsConfig `json:"gcfsConfig,omitempty"` - // HostMaintenancePolicy: HostMaintenancePolicy contains the desired // maintenance policy for the Google Compute Engine hosts. HostMaintenancePolicy *HostMaintenancePolicy `json:"hostMaintenancePolicy,omitempty"` - // LoggingConfig: Logging configuration for node pools. LoggingConfig *NodePoolLoggingConfig `json:"loggingConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "ContainerdConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ContainerdConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ContainerdConfig") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeConfigDefaults) MarshalJSON() ([]byte, error) { type NoMethod NodeConfigDefaults - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NodeKubeletConfig: Node kubelet configs. type NodeKubeletConfig struct { - // CpuCfsQuota: Enable CPU CFS quota enforcement for containers that - // specify CPU limits. This option is enabled by default which makes - // kubelet use CFS quota - // (https://www.kernel.org/doc/Documentation/scheduler/sched-bwc.txt) to - // enforce container CPU limits. Otherwise, CPU limits will not be - // enforced at all. Disable this option to mitigate CPU throttling - // problems while still having your pods to be in Guaranteed QoS class - // by specifying the CPU limits. The default value is 'true' if - // unspecified. + // CpuCfsQuota: Enable CPU CFS quota enforcement for containers that specify + // CPU limits. This option is enabled by default which makes kubelet use CFS + // quota (https://www.kernel.org/doc/Documentation/scheduler/sched-bwc.txt) to + // enforce container CPU limits. Otherwise, CPU limits will not be enforced at + // all. Disable this option to mitigate CPU throttling problems while still + // having your pods to be in Guaranteed QoS class by specifying the CPU limits. + // The default value is 'true' if unspecified. CpuCfsQuota bool `json:"cpuCfsQuota,omitempty"` - - // CpuCfsQuotaPeriod: Set the CPU CFS quota period value - // 'cpu.cfs_period_us'. The string must be a sequence of decimal - // numbers, each with optional fraction and a unit suffix, such as - // "300ms". Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", - // "h". The value must be a positive duration. + // CpuCfsQuotaPeriod: Set the CPU CFS quota period value 'cpu.cfs_period_us'. + // The string must be a sequence of decimal numbers, each with optional + // fraction and a unit suffix, such as "300ms". Valid time units are "ns", "us" + // (or "µs"), "ms", "s", "m", "h". The value must be a positive duration. CpuCfsQuotaPeriod string `json:"cpuCfsQuotaPeriod,omitempty"` - // CpuManagerPolicy: Control the CPU management policy on the node. See // https://kubernetes.io/docs/tasks/administer-cluster/cpu-management-policies/ - // The following values are allowed. * "none": the default, which - // represents the existing scheduling behavior. * "static": allows pods - // with certain resource characteristics to be granted increased CPU - // affinity and exclusivity on the node. The default value is 'none' if - // unspecified. + // The following values are allowed. * "none": the default, which represents + // the existing scheduling behavior. * "static": allows pods with certain + // resource characteristics to be granted increased CPU affinity and + // exclusivity on the node. The default value is 'none' if unspecified. CpuManagerPolicy string `json:"cpuManagerPolicy,omitempty"` - - // InsecureKubeletReadonlyPortEnabled: Enable or disable Kubelet read - // only port. + // InsecureKubeletReadonlyPortEnabled: Enable or disable Kubelet read only + // port. InsecureKubeletReadonlyPortEnabled bool `json:"insecureKubeletReadonlyPortEnabled,omitempty"` - // PodPidsLimit: Set the Pod PID limits. See // https://kubernetes.io/docs/concepts/policy/pid-limiting/#pod-pid-limits - // Controls the maximum number of processes allowed to run in a pod. The - // value must be greater than or equal to 1024 and less than 4194304. + // Controls the maximum number of processes allowed to run in a pod. The value + // must be greater than or equal to 1024 and less than 4194304. PodPidsLimit int64 `json:"podPidsLimit,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "CpuCfsQuota") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CpuCfsQuota") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CpuCfsQuota") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeKubeletConfig) MarshalJSON() ([]byte, error) { type NoMethod NodeKubeletConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NodeLabels: Collection of node-level Kubernetes labels @@ -5784,151 +4558,119 @@ func (s *NodeKubeletConfig) MarshalJSON() ([]byte, error) { type NodeLabels struct { // Labels: Map of node label keys and node label values. Labels map[string]string `json:"labels,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Labels") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Labels") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Labels") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeLabels) MarshalJSON() ([]byte, error) { type NoMethod NodeLabels - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodeManagement: NodeManagement defines the set of node management -// services turned on for the node pool. +// NodeManagement: NodeManagement defines the set of node management services +// turned on for the node pool. type NodeManagement struct { // AutoRepair: Whether the nodes will be automatically repaired. AutoRepair bool `json:"autoRepair,omitempty"` - // AutoUpgrade: Whether the nodes will be automatically upgraded. AutoUpgrade bool `json:"autoUpgrade,omitempty"` - // UpgradeOptions: Specifies the Auto Upgrade knobs for the node pool. UpgradeOptions *AutoUpgradeOptions `json:"upgradeOptions,omitempty"` - // ForceSendFields is a list of field names (e.g. "AutoRepair") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AutoRepair") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AutoRepair") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeManagement) MarshalJSON() ([]byte, error) { type NoMethod NodeManagement - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NodeNetworkConfig: Parameters for node pool-level network config. type NodeNetworkConfig struct { - // AdditionalNodeNetworkConfigs: We specify the additional node networks - // for this node pool using this list. Each node network corresponds to - // an additional interface + // AdditionalNodeNetworkConfigs: We specify the additional node networks for + // this node pool using this list. Each node network corresponds to an + // additional interface AdditionalNodeNetworkConfigs []*AdditionalNodeNetworkConfig `json:"additionalNodeNetworkConfigs,omitempty"` - - // AdditionalPodNetworkConfigs: We specify the additional pod networks - // for this node pool using this list. Each pod network corresponds to - // an additional alias IP range for the node + // AdditionalPodNetworkConfigs: We specify the additional pod networks for this + // node pool using this list. Each pod network corresponds to an additional + // alias IP range for the node AdditionalPodNetworkConfigs []*AdditionalPodNetworkConfig `json:"additionalPodNetworkConfigs,omitempty"` - - // CreatePodRange: Input only. Whether to create a new range for pod IPs - // in this node pool. Defaults are provided for `pod_range` and + // CreatePodRange: Input only. Whether to create a new range for pod IPs in + // this node pool. Defaults are provided for `pod_range` and // `pod_ipv4_cidr_block` if they are not specified. If neither - // `create_pod_range` or `pod_range` are specified, the cluster-level - // default (`ip_allocation_policy.cluster_ipv4_cidr_block`) is used. - // Only applicable if `ip_allocation_policy.use_ip_aliases` is true. - // This field cannot be changed after the node pool has been created. + // `create_pod_range` or `pod_range` are specified, the cluster-level default + // (`ip_allocation_policy.cluster_ipv4_cidr_block`) is used. Only applicable if + // `ip_allocation_policy.use_ip_aliases` is true. This field cannot be changed + // after the node pool has been created. CreatePodRange bool `json:"createPodRange,omitempty"` - // EnablePrivateNodes: Whether nodes have internal IP addresses only. If // enable_private_nodes is not specified, then the value is derived from // cluster.privateClusterConfig.enablePrivateNodes EnablePrivateNodes bool `json:"enablePrivateNodes,omitempty"` - // NetworkPerformanceConfig: Network bandwidth tier configuration. NetworkPerformanceConfig *NetworkPerformanceConfig `json:"networkPerformanceConfig,omitempty"` - - // PodCidrOverprovisionConfig: [PRIVATE FIELD] Pod CIDR size - // overprovisioning config for the nodepool. Pod CIDR size per node - // depends on max_pods_per_node. By default, the value of - // max_pods_per_node is rounded off to next power of 2 and we then - // double that to get the size of pod CIDR block per node. Example: - // max_pods_per_node of 30 would result in 64 IPs (/26). This config can - // disable the doubling of IPs (we still round off to next power of 2) - // Example: max_pods_per_node of 30 will result in 32 IPs (/27) when - // overprovisioning is disabled. + // PodCidrOverprovisionConfig: [PRIVATE FIELD] Pod CIDR size overprovisioning + // config for the nodepool. Pod CIDR size per node depends on + // max_pods_per_node. By default, the value of max_pods_per_node is rounded off + // to next power of 2 and we then double that to get the size of pod CIDR block + // per node. Example: max_pods_per_node of 30 would result in 64 IPs (/26). + // This config can disable the doubling of IPs (we still round off to next + // power of 2) Example: max_pods_per_node of 30 will result in 32 IPs (/27) + // when overprovisioning is disabled. PodCidrOverprovisionConfig *PodCIDROverprovisionConfig `json:"podCidrOverprovisionConfig,omitempty"` - - // PodIpv4CidrBlock: The IP address range for pod IPs in this node pool. - // Only applicable if `create_pod_range` is true. Set to blank to have a - // range chosen with the default size. Set to /netmask (e.g. `/14`) to - // have a range chosen with a specific netmask. Set to a CIDR - // (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) - // notation (e.g. `10.96.0.0/14`) to pick a specific range to use. Only - // applicable if `ip_allocation_policy.use_ip_aliases` is true. This - // field cannot be changed after the node pool has been created. + // PodIpv4CidrBlock: The IP address range for pod IPs in this node pool. Only + // applicable if `create_pod_range` is true. Set to blank to have a range + // chosen with the default size. Set to /netmask (e.g. `/14`) to have a range + // chosen with a specific netmask. Set to a CIDR + // (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation + // (e.g. `10.96.0.0/14`) to pick a specific range to use. Only applicable if + // `ip_allocation_policy.use_ip_aliases` is true. This field cannot be changed + // after the node pool has been created. PodIpv4CidrBlock string `json:"podIpv4CidrBlock,omitempty"` - - // PodIpv4RangeUtilization: Output only. [Output only] The utilization - // of the IPv4 range for the pod. The ratio is Usage/[Total number of - // IPs in the secondary range], Usage=numNodes*numZones*podIPsPerNode. + // PodIpv4RangeUtilization: Output only. [Output only] The utilization of the + // IPv4 range for the pod. The ratio is Usage/[Total number of IPs in the + // secondary range], Usage=numNodes*numZones*podIPsPerNode. PodIpv4RangeUtilization float64 `json:"podIpv4RangeUtilization,omitempty"` - - // PodRange: The ID of the secondary range for pod IPs. If - // `create_pod_range` is true, this ID is used for the new range. If - // `create_pod_range` is false, uses an existing secondary range with - // this ID. Only applicable if `ip_allocation_policy.use_ip_aliases` is - // true. This field cannot be changed after the node pool has been - // created. + // PodRange: The ID of the secondary range for pod IPs. If `create_pod_range` + // is true, this ID is used for the new range. If `create_pod_range` is false, + // uses an existing secondary range with this ID. Only applicable if + // `ip_allocation_policy.use_ip_aliases` is true. This field cannot be changed + // after the node pool has been created. PodRange string `json:"podRange,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "AdditionalNodeNetworkConfigs") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // "AdditionalNodeNetworkConfigs") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields + // for more details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "AdditionalNodeNetworkConfigs") to include in API requests with the - // JSON null value. By default, fields with empty values are omitted - // from API requests. However, any field with an empty value appearing - // in NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "AdditionalNodeNetworkConfigs") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeNetworkConfig) MarshalJSON() ([]byte, error) { type NoMethod NodeNetworkConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } func (s *NodeNetworkConfig) UnmarshalJSON(data []byte) error { @@ -5945,313 +4687,247 @@ func (s *NodeNetworkConfig) UnmarshalJSON(data []byte) error { return nil } -// NodePool: NodePool contains the name and configuration for a -// cluster's node pool. Node pools are a set of nodes (i.e. VM's), with -// a common configuration and specification, under the control of the -// cluster master. They may have a set of Kubernetes labels applied to -// them, which may be used to reference them during pod scheduling. They -// may also be resized up or down, to accommodate the workload. +// NodePool: NodePool contains the name and configuration for a cluster's node +// pool. Node pools are a set of nodes (i.e. VM's), with a common configuration +// and specification, under the control of the cluster master. They may have a +// set of Kubernetes labels applied to them, which may be used to reference +// them during pod scheduling. They may also be resized up or down, to +// accommodate the workload. type NodePool struct { - // Autoscaling: Autoscaler configuration for this NodePool. Autoscaler - // is enabled only if a valid configuration is present. + // Autoscaling: Autoscaler configuration for this NodePool. Autoscaler is + // enabled only if a valid configuration is present. Autoscaling *NodePoolAutoscaling `json:"autoscaling,omitempty"` - // BestEffortProvisioning: Enable best effort provisioning for nodes BestEffortProvisioning *BestEffortProvisioning `json:"bestEffortProvisioning,omitempty"` - // Conditions: Which conditions caused the current node pool state. Conditions []*StatusCondition `json:"conditions,omitempty"` - // Config: The node configuration of the pool. Config *NodeConfig `json:"config,omitempty"` - - // Etag: This checksum is computed by the server based on the value of - // node pool fields, and may be sent on update requests to ensure the - // client has an up-to-date value before proceeding. + // Etag: This checksum is computed by the server based on the value of node + // pool fields, and may be sent on update requests to ensure the client has an + // up-to-date value before proceeding. Etag string `json:"etag,omitempty"` - - // InitialNodeCount: The initial node count for the pool. You must - // ensure that your Compute Engine resource quota - // (https://cloud.google.com/compute/quotas) is sufficient for this - // number of instances. You must also have available firewall and routes - // quota. + // InitialNodeCount: The initial node count for the pool. You must ensure that + // your Compute Engine resource quota (https://cloud.google.com/compute/quotas) + // is sufficient for this number of instances. You must also have available + // firewall and routes quota. InitialNodeCount int64 `json:"initialNodeCount,omitempty"` - - // InstanceGroupUrls: [Output only] The resource URLs of the managed - // instance groups + // InstanceGroupUrls: [Output only] The resource URLs of the managed instance + // groups // (https://cloud.google.com/compute/docs/instance-groups/creating-groups-of-managed-instances) - // associated with this node pool. During the node pool blue-green - // upgrade operation, the URLs contain both blue and green resources. + // associated with this node pool. During the node pool blue-green upgrade + // operation, the URLs contain both blue and green resources. InstanceGroupUrls []string `json:"instanceGroupUrls,omitempty"` - // Locations: The list of Google Compute Engine zones // (https://cloud.google.com/compute/docs/zones#available) in which the - // NodePool's nodes should be located. If this value is unspecified - // during node pool creation, the Cluster.Locations + // NodePool's nodes should be located. If this value is unspecified during node + // pool creation, the Cluster.Locations // (https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1/projects.locations.clusters#Cluster.FIELDS.locations) - // value will be used, instead. Warning: changing node pool locations - // will result in nodes being added and/or removed. + // value will be used, instead. Warning: changing node pool locations will + // result in nodes being added and/or removed. Locations []string `json:"locations,omitempty"` - // Management: NodeManagement configuration for this NodePool. Management *NodeManagement `json:"management,omitempty"` - - // MaxPodsConstraint: The constraint on the maximum number of pods that - // can be run simultaneously on a node in the node pool. + // MaxPodsConstraint: The constraint on the maximum number of pods that can be + // run simultaneously on a node in the node pool. MaxPodsConstraint *MaxPodsConstraint `json:"maxPodsConstraint,omitempty"` - // Name: The name of the node pool. Name string `json:"name,omitempty"` - - // NetworkConfig: Networking configuration for this NodePool. If - // specified, it overrides the cluster-level defaults. + // NetworkConfig: Networking configuration for this NodePool. If specified, it + // overrides the cluster-level defaults. NetworkConfig *NodeNetworkConfig `json:"networkConfig,omitempty"` - // PlacementPolicy: Specifies the node placement policy. PlacementPolicy *PlacementPolicy `json:"placementPolicy,omitempty"` - - // PodIpv4CidrSize: [Output only] The pod CIDR block size per node in - // this node pool. + // PodIpv4CidrSize: [Output only] The pod CIDR block size per node in this node + // pool. PodIpv4CidrSize int64 `json:"podIpv4CidrSize,omitempty"` - - // QueuedProvisioning: Specifies the configuration of queued - // provisioning. + // QueuedProvisioning: Specifies the configuration of queued provisioning. QueuedProvisioning *QueuedProvisioning `json:"queuedProvisioning,omitempty"` - // SelfLink: [Output only] Server-defined URL for the resource. SelfLink string `json:"selfLink,omitempty"` - // Status: [Output only] The status of the nodes in this pool instance. // // Possible values: // "STATUS_UNSPECIFIED" - Not set. - // "PROVISIONING" - The PROVISIONING state indicates the node pool is - // being created. - // "RUNNING" - The RUNNING state indicates the node pool has been - // created and is fully usable. - // "RUNNING_WITH_ERROR" - The RUNNING_WITH_ERROR state indicates the - // node pool has been created and is partially usable. Some error state - // has occurred and some functionality may be impaired. Customer may - // need to reissue a request or trigger a new update. - // "RECONCILING" - The RECONCILING state indicates that some work is - // actively being done on the node pool, such as upgrading node - // software. Details can be found in the `statusMessage` field. - // "STOPPING" - The STOPPING state indicates the node pool is being - // deleted. - // "ERROR" - The ERROR state indicates the node pool may be unusable. - // Details can be found in the `statusMessage` field. + // "PROVISIONING" - The PROVISIONING state indicates the node pool is being + // created. + // "RUNNING" - The RUNNING state indicates the node pool has been created and + // is fully usable. + // "RUNNING_WITH_ERROR" - The RUNNING_WITH_ERROR state indicates the node + // pool has been created and is partially usable. Some error state has occurred + // and some functionality may be impaired. Customer may need to reissue a + // request or trigger a new update. + // "RECONCILING" - The RECONCILING state indicates that some work is actively + // being done on the node pool, such as upgrading node software. Details can be + // found in the `statusMessage` field. + // "STOPPING" - The STOPPING state indicates the node pool is being deleted. + // "ERROR" - The ERROR state indicates the node pool may be unusable. Details + // can be found in the `statusMessage` field. Status string `json:"status,omitempty"` - - // StatusMessage: [Output only] Deprecated. Use conditions instead. - // Additional information about the current status of this node pool - // instance, if available. + // StatusMessage: [Output only] Deprecated. Use conditions instead. Additional + // information about the current status of this node pool instance, if + // available. StatusMessage string `json:"statusMessage,omitempty"` - // UpdateInfo: Output only. [Output only] Update info contains relevant // information during a node pool update. UpdateInfo *UpdateInfo `json:"updateInfo,omitempty"` - // UpgradeSettings: Upgrade settings control disruption and speed of the // upgrade. UpgradeSettings *UpgradeSettings `json:"upgradeSettings,omitempty"` - - // Version: The version of Kubernetes running on this NodePool's nodes. - // If unspecified, it defaults as described here + // Version: The version of Kubernetes running on this NodePool's nodes. If + // unspecified, it defaults as described here // (https://cloud.google.com/kubernetes-engine/versioning#specifying_node_version). Version string `json:"version,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Autoscaling") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Autoscaling") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Autoscaling") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodePool) MarshalJSON() ([]byte, error) { type NoMethod NodePool - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodePoolAutoConfig: node pool configs that apply to all -// auto-provisioned node pools in autopilot clusters and node -// auto-provisioning enabled clusters +// NodePoolAutoConfig: node pool configs that apply to all auto-provisioned +// node pools in autopilot clusters and node auto-provisioning enabled clusters type NodePoolAutoConfig struct { - // NetworkTags: The list of instance tags applied to all nodes. Tags are - // used to identify valid sources or targets for network firewalls and - // are specified by the client during cluster creation. Each tag within - // the list must comply with RFC1035. + // NetworkTags: The list of instance tags applied to all nodes. Tags are used + // to identify valid sources or targets for network firewalls and are specified + // by the client during cluster creation. Each tag within the list must comply + // with RFC1035. NetworkTags *NetworkTags `json:"networkTags,omitempty"` - - // ResourceManagerTags: Resource manager tag keys and values to be - // attached to the nodes for managing Compute Engine firewalls using - // Network Firewall Policies. + // ResourceManagerTags: Resource manager tag keys and values to be attached to + // the nodes for managing Compute Engine firewalls using Network Firewall + // Policies. ResourceManagerTags *ResourceManagerTags `json:"resourceManagerTags,omitempty"` - // ForceSendFields is a list of field names (e.g. "NetworkTags") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NetworkTags") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "NetworkTags") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodePoolAutoConfig) MarshalJSON() ([]byte, error) { type NoMethod NodePoolAutoConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodePoolAutoscaling: NodePoolAutoscaling contains information -// required by cluster autoscaler to adjust the size of the node pool to -// the current cluster usage. +// NodePoolAutoscaling: NodePoolAutoscaling contains information required by +// cluster autoscaler to adjust the size of the node pool to the current +// cluster usage. type NodePoolAutoscaling struct { // Autoprovisioned: Can this node pool be deleted automatically. Autoprovisioned bool `json:"autoprovisioned,omitempty"` - // Enabled: Is autoscaling enabled for this node pool. Enabled bool `json:"enabled,omitempty"` - // LocationPolicy: Location policy used when scaling up a nodepool. // // Possible values: // "LOCATION_POLICY_UNSPECIFIED" - Not set. - // "BALANCED" - BALANCED is a best effort policy that aims to balance - // the sizes of different zones. - // "ANY" - ANY policy picks zones that have the highest capacity - // available. + // "BALANCED" - BALANCED is a best effort policy that aims to balance the + // sizes of different zones. + // "ANY" - ANY policy picks zones that have the highest capacity available. LocationPolicy string `json:"locationPolicy,omitempty"` - - // MaxNodeCount: Maximum number of nodes for one location in the - // NodePool. Must be >= min_node_count. There has to be enough quota to - // scale up the cluster. + // MaxNodeCount: Maximum number of nodes for one location in the NodePool. Must + // be >= min_node_count. There has to be enough quota to scale up the cluster. MaxNodeCount int64 `json:"maxNodeCount,omitempty"` - - // MinNodeCount: Minimum number of nodes for one location in the - // NodePool. Must be >= 1 and <= max_node_count. + // MinNodeCount: Minimum number of nodes for one location in the NodePool. Must + // be >= 1 and <= max_node_count. MinNodeCount int64 `json:"minNodeCount,omitempty"` - - // TotalMaxNodeCount: Maximum number of nodes in the node pool. Must be - // greater than total_min_node_count. There has to be enough quota to - // scale up the cluster. The total_*_node_count fields are mutually - // exclusive with the *_node_count fields. + // TotalMaxNodeCount: Maximum number of nodes in the node pool. Must be greater + // than total_min_node_count. There has to be enough quota to scale up the + // cluster. The total_*_node_count fields are mutually exclusive with the + // *_node_count fields. TotalMaxNodeCount int64 `json:"totalMaxNodeCount,omitempty"` - - // TotalMinNodeCount: Minimum number of nodes in the node pool. Must be - // greater than 1 less than total_max_node_count. The total_*_node_count - // fields are mutually exclusive with the *_node_count fields. + // TotalMinNodeCount: Minimum number of nodes in the node pool. Must be greater + // than 1 less than total_max_node_count. The total_*_node_count fields are + // mutually exclusive with the *_node_count fields. TotalMinNodeCount int64 `json:"totalMinNodeCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "Autoprovisioned") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Autoprovisioned") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Autoprovisioned") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodePoolAutoscaling) MarshalJSON() ([]byte, error) { type NoMethod NodePoolAutoscaling - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NodePoolDefaults: Subset of Nodepool message that has defaults. type NodePoolDefaults struct { // NodeConfigDefaults: Subset of NodeConfig message that has defaults. NodeConfigDefaults *NodeConfigDefaults `json:"nodeConfigDefaults,omitempty"` - - // ForceSendFields is a list of field names (e.g. "NodeConfigDefaults") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "NodeConfigDefaults") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NodeConfigDefaults") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "NodeConfigDefaults") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodePoolDefaults) MarshalJSON() ([]byte, error) { type NoMethod NodePoolDefaults - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodePoolLoggingConfig: NodePoolLoggingConfig specifies logging -// configuration for nodepools. +// NodePoolLoggingConfig: NodePoolLoggingConfig specifies logging configuration +// for nodepools. type NodePoolLoggingConfig struct { // VariantConfig: Logging variant configuration. VariantConfig *LoggingVariantConfig `json:"variantConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "VariantConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "VariantConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "VariantConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodePoolLoggingConfig) MarshalJSON() ([]byte, error) { type NoMethod NodePoolLoggingConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NodeTaint: Kubernetes taint is composed of three fields: key, value, -// and effect. Effect can only be one of three types: NoSchedule, -// PreferNoSchedule or NoExecute. See here -// (https://kubernetes.io/docs/concepts/configuration/taint-and-toleration) -// for more information, including usage and the valid values. +// NodeTaint: Kubernetes taint is composed of three fields: key, value, and +// effect. Effect can only be one of three types: NoSchedule, PreferNoSchedule +// or NoExecute. See here +// (https://kubernetes.io/docs/concepts/configuration/taint-and-toleration) for +// more information, including usage and the valid values. type NodeTaint struct { // Effect: Effect for taint. // @@ -6261,34 +4937,26 @@ type NodeTaint struct { // "PREFER_NO_SCHEDULE" - PreferNoSchedule // "NO_EXECUTE" - NoExecute Effect string `json:"effect,omitempty"` - // Key: Key for taint. Key string `json:"key,omitempty"` - // Value: Value for taint. Value string `json:"value,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Effect") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Effect") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Effect") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeTaint) MarshalJSON() ([]byte, error) { type NoMethod NodeTaint - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NodeTaints: Collection of Kubernetes node taints @@ -6296,28 +4964,22 @@ func (s *NodeTaint) MarshalJSON() ([]byte, error) { type NodeTaints struct { // Taints: List of node taints. Taints []*NodeTaint `json:"taints,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Taints") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Taints") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Taints") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NodeTaints) MarshalJSON() ([]byte, error) { type NoMethod NodeTaints - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // NotificationConfig: NotificationConfig is the configuration of @@ -6325,164 +4987,138 @@ func (s *NodeTaints) MarshalJSON() ([]byte, error) { type NotificationConfig struct { // Pubsub: Notification config for Pub/Sub. Pubsub *PubSub `json:"pubsub,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Pubsub") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Pubsub") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Pubsub") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *NotificationConfig) MarshalJSON() ([]byte, error) { type NoMethod NotificationConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// Operation: This operation resource represents operations that may -// have happened or are happening on the cluster. All fields are output -// only. +// Operation: This operation resource represents operations that may have +// happened or are happening on the cluster. All fields are output only. type Operation struct { // ClusterConditions: Which conditions caused the current cluster state. // Deprecated. Use field error instead. ClusterConditions []*StatusCondition `json:"clusterConditions,omitempty"` - // Detail: Detailed operation progress, if available. Detail string `json:"detail,omitempty"` - // EndTime: [Output only] The time the operation completed, in RFC3339 // (https://www.ietf.org/rfc/rfc3339.txt) text format. EndTime string `json:"endTime,omitempty"` - // Error: The error result of the operation in case of failure. Error *Status `json:"error,omitempty"` - // Location: [Output only] The name of the Google Compute Engine zone // (https://cloud.google.com/compute/docs/regions-zones/regions-zones#available) // or region // (https://cloud.google.com/compute/docs/regions-zones/regions-zones#available) // in which the cluster resides. Location string `json:"location,omitempty"` - // Name: The server-assigned ID for the operation. Name string `json:"name,omitempty"` - - // NodepoolConditions: Which conditions caused the current node pool - // state. Deprecated. Use field error instead. + // NodepoolConditions: Which conditions caused the current node pool state. + // Deprecated. Use field error instead. NodepoolConditions []*StatusCondition `json:"nodepoolConditions,omitempty"` - // OperationType: The operation type. // // Possible values: // "TYPE_UNSPECIFIED" - Not set. - // "CREATE_CLUSTER" - The cluster is being created. The cluster should - // be assumed to be unusable until the operation finishes. In the event - // of the operation failing, the cluster will enter the ERROR state and - // eventually be deleted. - // "DELETE_CLUSTER" - The cluster is being deleted. The cluster should - // be assumed to be unusable as soon as this operation starts. In the - // event of the operation failing, the cluster will enter the ERROR - // state and the deletion will be automatically retried until completed. - // "UPGRADE_MASTER" - The cluster version is being updated. Note that - // this includes "upgrades" to the same version, which are simply a - // recreation. This also includes - // [auto-upgrades](https://cloud.google.com/kubernetes-engine/docs/concep - // ts/cluster-upgrades#upgrading_automatically). For more details, see - // [documentation on cluster - // upgrades](https://cloud.google.com/kubernetes-engine/docs/concepts/clu - // ster-upgrades#cluster_upgrades). - // "UPGRADE_NODES" - A node pool is being updated. Despite calling - // this an "upgrade", this includes most forms of updates to node pools. - // This also includes - // [auto-upgrades](https://cloud.google.com/kubernetes-engine/docs/how-to - // /node-auto-upgrades). This operation sets the progress field and may - // be canceled. The upgrade strategy depends on [node pool - // configuration](https://cloud.google.com/kubernetes-engine/docs/concept - // s/node-pool-upgrade-strategies). The nodes are generally still usable - // during this operation. - // "REPAIR_CLUSTER" - A problem has been detected with the control - // plane and is being repaired. This operation type is initiated by GKE. - // For more details, see [documentation on - // repairs](https://cloud.google.com/kubernetes-engine/docs/concepts/main - // tenance-windows-and-exclusions#repairs). - // "UPDATE_CLUSTER" - The cluster is being updated. This is a broad - // category of operations and includes operations that only change - // metadata as well as those that must recreate the entire cluster. If - // the control plane must be recreated, this will cause temporary - // downtime for zonal clusters. Some features require recreating the - // nodes as well. Those will be recreated as separate operations and the - // update may not be completely functional until the node pools - // recreations finish. Node recreations will generally follow + // "CREATE_CLUSTER" - The cluster is being created. The cluster should be + // assumed to be unusable until the operation finishes. In the event of the + // operation failing, the cluster will enter the ERROR state and eventually be + // deleted. + // "DELETE_CLUSTER" - The cluster is being deleted. The cluster should be + // assumed to be unusable as soon as this operation starts. In the event of the + // operation failing, the cluster will enter the ERROR state and the deletion + // will be automatically retried until completed. + // "UPGRADE_MASTER" - The cluster version is being updated. Note that this + // includes "upgrades" to the same version, which are simply a recreation. This + // also includes + // [auto-upgrades](https://cloud.google.com/kubernetes-engine/docs/concepts/clus + // ter-upgrades#upgrading_automatically). For more details, see [documentation + // on cluster + // upgrades](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-up + // grades#cluster_upgrades). + // "UPGRADE_NODES" - A node pool is being updated. Despite calling this an + // "upgrade", this includes most forms of updates to node pools. This also + // includes + // [auto-upgrades](https://cloud.google.com/kubernetes-engine/docs/how-to/node-a + // uto-upgrades). This operation sets the progress field and may be canceled. + // The upgrade strategy depends on [node pool + // configuration](https://cloud.google.com/kubernetes-engine/docs/concepts/node- + // pool-upgrade-strategies). The nodes are generally still usable during this + // operation. + // "REPAIR_CLUSTER" - A problem has been detected with the control plane and + // is being repaired. This operation type is initiated by GKE. For more + // details, see [documentation on + // repairs](https://cloud.google.com/kubernetes-engine/docs/concepts/maintenance + // -windows-and-exclusions#repairs). + // "UPDATE_CLUSTER" - The cluster is being updated. This is a broad category + // of operations and includes operations that only change metadata as well as + // those that must recreate the entire cluster. If the control plane must be + // recreated, this will cause temporary downtime for zonal clusters. Some + // features require recreating the nodes as well. Those will be recreated as + // separate operations and the update may not be completely functional until + // the node pools recreations finish. Node recreations will generally follow // [maintenance - // policies](https://cloud.google.com/kubernetes-engine/docs/concepts/mai - // ntenance-windows-and-exclusions). Some GKE-initiated operations use - // this type. This includes certain types of auto-upgrades and incident - // mitigations. - // "CREATE_NODE_POOL" - A node pool is being created. The node pool - // should be assumed to be unusable until this operation finishes. In - // the event of an error, the node pool may be partially created. If - // enabled, [node - // autoprovisioning](https://cloud.google.com/kubernetes-engine/docs/how- - // to/node-auto-provisioning) may have automatically initiated such - // operations. - // "DELETE_NODE_POOL" - The node pool is being deleted. The node pool - // should be assumed to be unusable as soon as this operation starts. - // "SET_NODE_POOL_MANAGEMENT" - The node pool's manamagent field is - // being updated. These operations only update metadata and may be - // concurrent with most other operations. - // "AUTO_REPAIR_NODES" - A problem has been detected with nodes and - // [they are being - // repaired](https://cloud.google.com/kubernetes-engine/docs/how-to/node- - // auto-repair). This operation type is initiated by GKE, typically - // automatically. This operation may be concurrent with other operations - // and there may be multiple repairs occurring on the same node pool. - // "AUTO_UPGRADE_NODES" - Unused. Automatic node upgrade uses - // UPGRADE_NODES. + // policies](https://cloud.google.com/kubernetes-engine/docs/concepts/maintenanc + // e-windows-and-exclusions). Some GKE-initiated operations use this type. This + // includes certain types of auto-upgrades and incident mitigations. + // "CREATE_NODE_POOL" - A node pool is being created. The node pool should be + // assumed to be unusable until this operation finishes. In the event of an + // error, the node pool may be partially created. If enabled, [node + // autoprovisioning](https://cloud.google.com/kubernetes-engine/docs/how-to/node + // -auto-provisioning) may have automatically initiated such operations. + // "DELETE_NODE_POOL" - The node pool is being deleted. The node pool should + // be assumed to be unusable as soon as this operation starts. + // "SET_NODE_POOL_MANAGEMENT" - The node pool's manamagent field is being + // updated. These operations only update metadata and may be concurrent with + // most other operations. + // "AUTO_REPAIR_NODES" - A problem has been detected with nodes and [they are + // being + // repaired](https://cloud.google.com/kubernetes-engine/docs/how-to/node-auto-re + // pair). This operation type is initiated by GKE, typically automatically. + // This operation may be concurrent with other operations and there may be + // multiple repairs occurring on the same node pool. + // "AUTO_UPGRADE_NODES" - Unused. Automatic node upgrade uses UPGRADE_NODES. // "SET_LABELS" - Unused. Updating labels uses UPDATE_CLUSTER. - // "SET_MASTER_AUTH" - Unused. Updating master auth uses - // UPDATE_CLUSTER. - // "SET_NODE_POOL_SIZE" - The node pool is being resized. With the - // exception of resizing to or from size zero, the node pool is - // generally usable during this operation. + // "SET_MASTER_AUTH" - Unused. Updating master auth uses UPDATE_CLUSTER. + // "SET_NODE_POOL_SIZE" - The node pool is being resized. With the exception + // of resizing to or from size zero, the node pool is generally usable during + // this operation. // "SET_NETWORK_POLICY" - Unused. Updating network policy uses // UPDATE_CLUSTER. // "SET_MAINTENANCE_POLICY" - Unused. Updating maintenance policy uses // UPDATE_CLUSTER. - // "RESIZE_CLUSTER" - The control plane is being resized. This - // operation type is initiated by GKE. These operations are often - // performed preemptively to ensure that the control plane has - // sufficient resources and is not typically an indication of issues. - // For more details, see [documentation on - // resizes](https://cloud.google.com/kubernetes-engine/docs/concepts/main - // tenance-windows-and-exclusions#repairs). - // "FLEET_FEATURE_UPGRADE" - Fleet features of GKE Enterprise are - // being upgraded. The cluster should be assumed to be blocked for other - // upgrades until the operation finishes. + // "RESIZE_CLUSTER" - The control plane is being resized. This operation type + // is initiated by GKE. These operations are often performed preemptively to + // ensure that the control plane has sufficient resources and is not typically + // an indication of issues. For more details, see [documentation on + // resizes](https://cloud.google.com/kubernetes-engine/docs/concepts/maintenance + // -windows-and-exclusions#repairs). + // "FLEET_FEATURE_UPGRADE" - Fleet features of GKE Enterprise are being + // upgraded. The cluster should be assumed to be blocked for other upgrades + // until the operation finishes. OperationType string `json:"operationType,omitempty"` - - // Progress: Output only. [Output only] Progress information for an - // operation. + // Progress: Output only. [Output only] Progress information for an operation. Progress *OperationProgress `json:"progress,omitempty"` - // SelfLink: Server-defined URI for the operation. Example: - // `https://container.googleapis.com/v1alpha1/projects/123/locations/us-c - // entral1/operations/operation-123`. + // `https://container.googleapis.com/v1alpha1/projects/123/locations/us-central1 + // /operations/operation-123`. SelfLink string `json:"selfLink,omitempty"` - // StartTime: [Output only] The time the operation started, in RFC3339 // (https://www.ietf.org/rfc/rfc3339.txt) text format. StartTime string `json:"startTime,omitempty"` - // Status: The current status of the operation. // // Possible values: @@ -6492,56 +5128,43 @@ type Operation struct { // "DONE" - The operation is done, either cancelled or completed. // "ABORTING" - The operation is aborting. Status string `json:"status,omitempty"` - - // StatusMessage: Output only. If an error has occurred, a textual - // description of the error. Deprecated. Use field error instead. + // StatusMessage: Output only. If an error has occurred, a textual description + // of the error. Deprecated. Use field error instead. StatusMessage string `json:"statusMessage,omitempty"` - - // TargetLink: Server-defined URI for the target of the operation. The - // format of this is a URI to the resource being modified (such as a - // cluster, node pool, or node). For node pool repairs, there may be - // multiple nodes being repaired, but only one will be the target. - // Examples: - ## - // `https://container.googleapis.com/v1/projects/123/locations/us-central - // 1/clusters/my-cluster` ## - // `https://container.googleapis.com/v1/projects/123/zones/us-central1-c/ - // clusters/my-cluster/nodePools/my-np` - // `https://container.googleapis.com/v1/projects/123/zones/us-central1-c/ - // clusters/my-cluster/nodePools/my-np/node/my-node` + // TargetLink: Server-defined URI for the target of the operation. The format + // of this is a URI to the resource being modified (such as a cluster, node + // pool, or node). For node pool repairs, there may be multiple nodes being + // repaired, but only one will be the target. Examples: - ## + // `https://container.googleapis.com/v1/projects/123/locations/us-central1/clust + // ers/my-cluster` ## + // `https://container.googleapis.com/v1/projects/123/zones/us-central1-c/cluster + // s/my-cluster/nodePools/my-np` + // `https://container.googleapis.com/v1/projects/123/zones/us-central1-c/cluster + // s/my-cluster/nodePools/my-np/node/my-node` TargetLink string `json:"targetLink,omitempty"` - // Zone: The name of the Google Compute Engine zone // (https://cloud.google.com/compute/docs/zones#available) in which the - // operation is taking place. This field is deprecated, use location - // instead. + // operation is taking place. This field is deprecated, use location instead. Zone string `json:"zone,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "ClusterConditions") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "ClusterConditions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterConditions") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ClusterConditions") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Operation) MarshalJSON() ([]byte, error) { type NoMethod Operation - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // OperationError: OperationError records errors seen from CloudKMS keys @@ -6549,54 +5172,42 @@ func (s *Operation) MarshalJSON() ([]byte, error) { type OperationError struct { // ErrorMessage: Description of the error seen during the operation. ErrorMessage string `json:"errorMessage,omitempty"` - // KeyName: CloudKMS key resource that had the error. KeyName string `json:"keyName,omitempty"` - // Timestamp: Time when the CloudKMS error was seen. Timestamp string `json:"timestamp,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorMessage") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ErrorMessage") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ErrorMessage") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *OperationError) MarshalJSON() ([]byte, error) { type NoMethod OperationError - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // OperationProgress: Information about operation (or operation stage) // progress. type OperationProgress struct { - // Metrics: Progress metric bundle, for example: metrics: [{name: "nodes - // done", int_value: 15}, {name: "nodes total", int_value: 32}] or - // metrics: [{name: "progress", double_value: 0.56}, {name: "progress - // scale", double_value: 1.0}] + // Metrics: Progress metric bundle, for example: metrics: [{name: "nodes done", + // int_value: 15}, {name: "nodes total", int_value: 32}] or metrics: [{name: + // "progress", double_value: 0.56}, {name: "progress scale", double_value: + // 1.0}] Metrics []*Metric `json:"metrics,omitempty"` - - // Name: A non-parameterized string describing an operation stage. Unset - // for single-stage operations. + // Name: A non-parameterized string describing an operation stage. Unset for + // single-stage operations. Name string `json:"name,omitempty"` - // Stages: Substages of an operation or a stage. Stages []*OperationProgress `json:"stages,omitempty"` - - // Status: Status of an operation stage. Unset for single-stage - // operations. + // Status: Status of an operation stage. Unset for single-stage operations. // // Possible values: // "STATUS_UNSPECIFIED" - Not set. @@ -6605,513 +5216,400 @@ type OperationProgress struct { // "DONE" - The operation is done, either cancelled or completed. // "ABORTING" - The operation is aborting. Status string `json:"status,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Metrics") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Metrics") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Metrics") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Metrics") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *OperationProgress) MarshalJSON() ([]byte, error) { type NoMethod OperationProgress - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// OpportunisticMaintenanceStrategy: Strategy that will trigger -// maintenance on behalf of the customer. +// OpportunisticMaintenanceStrategy: Strategy that will trigger maintenance on +// behalf of the customer. type OpportunisticMaintenanceStrategy struct { // MaintenanceAvailabilityWindow: The window of time that opportunistic // maintenance can run. Example: A setting of 14 days implies that - // opportunistic maintenance can only be ran in the 2 weeks leading up - // to the scheduled maintenance date. Setting 28 days allows - // opportunistic maintenance to run at any time in the scheduled - // maintenance window (all `PERIODIC` maintenance is set 28 days in - // advance). + // opportunistic maintenance can only be ran in the 2 weeks leading up to the + // scheduled maintenance date. Setting 28 days allows opportunistic maintenance + // to run at any time in the scheduled maintenance window (all `PERIODIC` + // maintenance is set 28 days in advance). MaintenanceAvailabilityWindow string `json:"maintenanceAvailabilityWindow,omitempty"` - - // MinNodesPerPool: The minimum nodes required to be available in a - // pool. Blocks maintenance if it would cause the number of running - // nodes to dip below this value. + // MinNodesPerPool: The minimum nodes required to be available in a pool. + // Blocks maintenance if it would cause the number of running nodes to dip + // below this value. MinNodesPerPool int64 `json:"minNodesPerPool,omitempty,string"` - - // NodeIdleTimeWindow: The amount of time that a node can remain idle - // (no customer owned workloads running), before triggering maintenance. + // NodeIdleTimeWindow: The amount of time that a node can remain idle (no + // customer owned workloads running), before triggering maintenance. NodeIdleTimeWindow string `json:"nodeIdleTimeWindow,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "MaintenanceAvailabilityWindow") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // "MaintenanceAvailabilityWindow") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields + // for more details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "MaintenanceAvailabilityWindow") to include in API requests with the - // JSON null value. By default, fields with empty values are omitted - // from API requests. However, any field with an empty value appearing - // in NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "MaintenanceAvailabilityWindow") + // to include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *OpportunisticMaintenanceStrategy) MarshalJSON() ([]byte, error) { type NoMethod OpportunisticMaintenanceStrategy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ParentProductConfig: ParentProductConfig is the configuration of the -// parent product of the cluster. This field is used by Google internal -// products that are built on top of a GKE cluster and take the -// ownership of the cluster. +// ParentProductConfig: ParentProductConfig is the configuration of the parent +// product of the cluster. This field is used by Google internal products that +// are built on top of a GKE cluster and take the ownership of the cluster. type ParentProductConfig struct { // Labels: Labels contain the configuration of the parent product. Labels map[string]string `json:"labels,omitempty"` - // ProductName: Name of the parent product associated with the cluster. ProductName string `json:"productName,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Labels") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Labels") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Labels") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ParentProductConfig) MarshalJSON() ([]byte, error) { type NoMethod ParentProductConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// PlacementPolicy: PlacementPolicy defines the placement policy used by -// the node pool. +// PlacementPolicy: PlacementPolicy defines the placement policy used by the +// node pool. type PlacementPolicy struct { - // PolicyName: If set, refers to the name of a custom resource policy - // supplied by the user. The resource policy must be in the same project - // and region as the node pool. If not found, InvalidArgument error is - // returned. + // PolicyName: If set, refers to the name of a custom resource policy supplied + // by the user. The resource policy must be in the same project and region as + // the node pool. If not found, InvalidArgument error is returned. PolicyName string `json:"policyName,omitempty"` - // TpuTopology: TPU placement topology for pod slice node pool. // https://cloud.google.com/tpu/docs/types-topologies#tpu_topologies TpuTopology string `json:"tpuTopology,omitempty"` - // Type: The type of placement. // // Possible values: - // "TYPE_UNSPECIFIED" - TYPE_UNSPECIFIED specifies no requirements on - // nodes placement. - // "COMPACT" - COMPACT specifies node placement in the same - // availability domain to ensure low communication latency. + // "TYPE_UNSPECIFIED" - TYPE_UNSPECIFIED specifies no requirements on nodes + // placement. + // "COMPACT" - COMPACT specifies node placement in the same availability + // domain to ensure low communication latency. Type string `json:"type,omitempty"` - // ForceSendFields is a list of field names (e.g. "PolicyName") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "PolicyName") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "PolicyName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PlacementPolicy) MarshalJSON() ([]byte, error) { type NoMethod PlacementPolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // PodCIDROverprovisionConfig: [PRIVATE FIELD] Config for pod CIDR size // overprovisioning. type PodCIDROverprovisionConfig struct { - // Disable: Whether Pod CIDR overprovisioning is disabled. Note: Pod - // CIDR overprovisioning is enabled by default. + // Disable: Whether Pod CIDR overprovisioning is disabled. Note: Pod CIDR + // overprovisioning is enabled by default. Disable bool `json:"disable,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Disable") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Disable") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Disable") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Disable") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PodCIDROverprovisionConfig) MarshalJSON() ([]byte, error) { type NoMethod PodCIDROverprovisionConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// PodSecurityPolicyConfig: Configuration for the PodSecurityPolicy -// feature. +// PodSecurityPolicyConfig: Configuration for the PodSecurityPolicy feature. type PodSecurityPolicyConfig struct { // Enabled: Enable the PodSecurityPolicy controller for this cluster. If // enabled, pods must be valid under a PodSecurityPolicy to be created. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PodSecurityPolicyConfig) MarshalJSON() ([]byte, error) { type NoMethod PodSecurityPolicyConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // PolicyBinding: Binauthz policy that applies to this cluster. type PolicyBinding struct { // Name: The relative resource name of the binauthz platform policy to - // audit. GKE platform policies have the following format: + // evaluate. GKE platform policies have the following format: // `projects/{project_number}/platforms/gke/policies/{policy_id}`. Name string `json:"name,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Name") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Name") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Name") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Name") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PolicyBinding) MarshalJSON() ([]byte, error) { type NoMethod PolicyBinding - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // PrivateClusterConfig: Configuration options for private clusters. type PrivateClusterConfig struct { - // EnablePrivateEndpoint: Whether the master's internal IP address is - // used as the cluster endpoint. + // EnablePrivateEndpoint: Whether the master's internal IP address is used as + // the cluster endpoint. EnablePrivateEndpoint bool `json:"enablePrivateEndpoint,omitempty"` - // EnablePrivateNodes: Whether nodes have internal IP addresses only. If - // enabled, all nodes are given only RFC 1918 private addresses and - // communicate with the master via private networking. + // enabled, all nodes are given only RFC 1918 private addresses and communicate + // with the master via private networking. EnablePrivateNodes bool `json:"enablePrivateNodes,omitempty"` - // MasterGlobalAccessConfig: Controls master global access settings. MasterGlobalAccessConfig *PrivateClusterMasterGlobalAccessConfig `json:"masterGlobalAccessConfig,omitempty"` - - // MasterIpv4CidrBlock: The IP range in CIDR notation to use for the - // hosted master network. This range will be used for assigning internal - // IP addresses to the master or set of masters, as well as the ILB VIP. - // This range must not overlap with any other ranges in use within the - // cluster's network. + // MasterIpv4CidrBlock: The IP range in CIDR notation to use for the hosted + // master network. This range will be used for assigning internal IP addresses + // to the master or set of masters, as well as the ILB VIP. This range must not + // overlap with any other ranges in use within the cluster's network. MasterIpv4CidrBlock string `json:"masterIpv4CidrBlock,omitempty"` - - // PeeringName: Output only. The peering name in the customer VPC used - // by this cluster. + // PeeringName: Output only. The peering name in the customer VPC used by this + // cluster. PeeringName string `json:"peeringName,omitempty"` - - // PrivateEndpoint: Output only. The internal IP address of this - // cluster's master endpoint. + // PrivateEndpoint: Output only. The internal IP address of this cluster's + // master endpoint. PrivateEndpoint string `json:"privateEndpoint,omitempty"` - - // PrivateEndpointSubnetwork: Subnet to provision the master's private - // endpoint during cluster creation. Specified in - // projects/*/regions/*/subnetworks/* format. + // PrivateEndpointSubnetwork: Subnet to provision the master's private endpoint + // during cluster creation. Specified in projects/*/regions/*/subnetworks/* + // format. PrivateEndpointSubnetwork string `json:"privateEndpointSubnetwork,omitempty"` - - // PublicEndpoint: Output only. The external IP address of this - // cluster's master endpoint. + // PublicEndpoint: Output only. The external IP address of this cluster's + // master endpoint. PublicEndpoint string `json:"publicEndpoint,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "EnablePrivateEndpoint") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "EnablePrivateEndpoint") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EnablePrivateEndpoint") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PrivateClusterConfig) MarshalJSON() ([]byte, error) { type NoMethod PrivateClusterConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// PrivateClusterMasterGlobalAccessConfig: Configuration for controlling -// master global access settings. +// PrivateClusterMasterGlobalAccessConfig: Configuration for controlling master +// global access settings. type PrivateClusterMasterGlobalAccessConfig struct { // Enabled: Whenever master is accessible globally or not. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PrivateClusterMasterGlobalAccessConfig) MarshalJSON() ([]byte, error) { type NoMethod PrivateClusterMasterGlobalAccessConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// PrivateRegistryAccessConfig: PrivateRegistryAccessConfig contains -// access configuration for private container registries. +// PrivateRegistryAccessConfig: PrivateRegistryAccessConfig contains access +// configuration for private container registries. type PrivateRegistryAccessConfig struct { - // CertificateAuthorityDomainConfig: Private registry access - // configuration. + // CertificateAuthorityDomainConfig: Private registry access configuration. CertificateAuthorityDomainConfig []*CertificateAuthorityDomainConfig `json:"certificateAuthorityDomainConfig,omitempty"` - // Enabled: Private registry access is enabled. Enabled bool `json:"enabled,omitempty"` - // ForceSendFields is a list of field names (e.g. // "CertificateAuthorityDomainConfig") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // requests. By default, fields with empty or default values are omitted from + // API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. - // "CertificateAuthorityDomainConfig") to include in API requests with - // the JSON null value. By default, fields with empty values are omitted - // from API requests. However, any field with an empty value appearing - // in NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // "CertificateAuthorityDomainConfig") to include in API requests with the JSON + // null value. By default, fields with empty values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-NullFields for + // more details. NullFields []string `json:"-"` } func (s *PrivateRegistryAccessConfig) MarshalJSON() ([]byte, error) { type NoMethod PrivateRegistryAccessConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ProtectConfig: ProtectConfig defines the flags needed to -// enable/disable features for the Protect API. +// ProtectConfig: ProtectConfig defines the flags needed to enable/disable +// features for the Protect API. type ProtectConfig struct { - // WorkloadConfig: WorkloadConfig defines which actions are enabled for - // a cluster's workload configurations. + // WorkloadConfig: WorkloadConfig defines which actions are enabled for a + // cluster's workload configurations. WorkloadConfig *WorkloadConfig `json:"workloadConfig,omitempty"` - - // WorkloadVulnerabilityMode: Sets which mode to use for Protect - // workload vulnerability scanning feature. + // WorkloadVulnerabilityMode: Sets which mode to use for Protect workload + // vulnerability scanning feature. // // Possible values: - // "WORKLOAD_VULNERABILITY_MODE_UNSPECIFIED" - Default value not - // specified. - // "DISABLED" - Disables Workload Vulnerability Scanning feature on - // the cluster. + // "WORKLOAD_VULNERABILITY_MODE_UNSPECIFIED" - Default value not specified. + // "DISABLED" - Disables Workload Vulnerability Scanning feature on the + // cluster. // "BASIC" - Applies basic vulnerability scanning settings for cluster // workloads. WorkloadVulnerabilityMode string `json:"workloadVulnerabilityMode,omitempty"` - // ForceSendFields is a list of field names (e.g. "WorkloadConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "WorkloadConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "WorkloadConfig") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ProtectConfig) MarshalJSON() ([]byte, error) { type NoMethod ProtectConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // PubSub: Pub/Sub specific notification config. type PubSub struct { // Enabled: Enable notifications for Pub/Sub. Enabled bool `json:"enabled,omitempty"` - - // Filter: Allows filtering to one or more specific event types. If no - // filter is specified, or if a filter is specified with no event types, - // all event types will be sent + // Filter: Allows filtering to one or more specific event types. If no filter + // is specified, or if a filter is specified with no event types, all event + // types will be sent Filter *Filter `json:"filter,omitempty"` - - // Topic: The desired Pub/Sub topic to which notifications will be sent - // by GKE. Format is `projects/{project}/topics/{topic}`. + // Topic: The desired Pub/Sub topic to which notifications will be sent by GKE. + // Format is `projects/{project}/topics/{topic}`. Topic string `json:"topic,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PubSub) MarshalJSON() ([]byte, error) { type NoMethod PubSub - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// QueuedProvisioning: QueuedProvisioning defines the queued -// provisioning used by the node pool. +// QueuedProvisioning: QueuedProvisioning defines the queued provisioning used +// by the node pool. type QueuedProvisioning struct { - // Enabled: Denotes that this nodepool is QRM specific, meaning nodes - // can be only obtained through queuing via the Cluster Autoscaler - // ProvisioningRequest API. + // Enabled: Denotes that this nodepool is QRM specific, meaning nodes can be + // only obtained through queuing via the Cluster Autoscaler ProvisioningRequest + // API. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *QueuedProvisioning) MarshalJSON() ([]byte, error) { type NoMethod QueuedProvisioning - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// RangeInfo: RangeInfo contains the range name and the range -// utilization by this cluster. +// RangeInfo: RangeInfo contains the range name and the range utilization by +// this cluster. type RangeInfo struct { // RangeName: Output only. [Output only] Name of a range. RangeName string `json:"rangeName,omitempty"` - // Utilization: Output only. [Output only] The utilization of the range. Utilization float64 `json:"utilization,omitempty"` - // ForceSendFields is a list of field names (e.g. "RangeName") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "RangeName") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "RangeName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *RangeInfo) MarshalJSON() ([]byte, error) { type NoMethod RangeInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } func (s *RangeInfo) UnmarshalJSON(data []byte) error { @@ -7128,202 +5626,164 @@ func (s *RangeInfo) UnmarshalJSON(data []byte) error { return nil } -// RecurringTimeWindow: Represents an arbitrary window of time that -// recurs. +// RecurringTimeWindow: Represents an arbitrary window of time that recurs. type RecurringTimeWindow struct { - // Recurrence: An RRULE - // (https://tools.ietf.org/html/rfc5545#section-3.8.5.3) for how this - // window reccurs. They go on for the span of time between the start and - // end time. For example, to have something repeat every weekday, you'd - // use: `FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR` To repeat some window daily - // (equivalent to the DailyMaintenanceWindow): `FREQ=DAILY` For the - // first weekend of every month: `FREQ=MONTHLY;BYSETPOS=1;BYDAY=SA,SU` - // This specifies how frequently the window starts. Eg, if you wanted to - // have a 9-5 UTC-4 window every weekday, you'd use something like: ``` - // start time = 2019-01-01T09:00:00-0400 end time = - // 2019-01-01T17:00:00-0400 recurrence = - // FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR ``` Windows can span multiple days. - // Eg, to make the window encompass every weekend from midnight Saturday - // till the last minute of Sunday UTC: ``` start time = - // 2019-01-05T00:00:00Z end time = 2019-01-07T23:59:00Z recurrence = - // FREQ=WEEKLY;BYDAY=SA ``` Note the start and end time's specific dates - // are largely arbitrary except to specify duration of the window and - // when it first starts. The FREQ values of HOURLY, MINUTELY, and - // SECONDLY are not supported. + // Recurrence: An RRULE (https://tools.ietf.org/html/rfc5545#section-3.8.5.3) + // for how this window reccurs. They go on for the span of time between the + // start and end time. For example, to have something repeat every weekday, + // you'd use: `FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR` To repeat some window daily + // (equivalent to the DailyMaintenanceWindow): `FREQ=DAILY` For the first + // weekend of every month: `FREQ=MONTHLY;BYSETPOS=1;BYDAY=SA,SU` This specifies + // how frequently the window starts. Eg, if you wanted to have a 9-5 UTC-4 + // window every weekday, you'd use something like: ``` start time = + // 2019-01-01T09:00:00-0400 end time = 2019-01-01T17:00:00-0400 recurrence = + // FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR ``` Windows can span multiple days. Eg, to + // make the window encompass every weekend from midnight Saturday till the last + // minute of Sunday UTC: ``` start time = 2019-01-05T00:00:00Z end time = + // 2019-01-07T23:59:00Z recurrence = FREQ=WEEKLY;BYDAY=SA ``` Note the start + // and end time's specific dates are largely arbitrary except to specify + // duration of the window and when it first starts. The FREQ values of HOURLY, + // MINUTELY, and SECONDLY are not supported. Recurrence string `json:"recurrence,omitempty"` - // Window: The window of the first recurrence. Window *TimeWindow `json:"window,omitempty"` - // ForceSendFields is a list of field names (e.g. "Recurrence") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Recurrence") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Recurrence") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *RecurringTimeWindow) MarshalJSON() ([]byte, error) { type NoMethod RecurringTimeWindow - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ReleaseChannel: ReleaseChannel indicates which release channel a -// cluster is subscribed to. Release channels are arranged in order of -// risk. When a cluster is subscribed to a release channel, Google -// maintains both the master version and the node version. Node -// auto-upgrade defaults to true and cannot be disabled. +// ReleaseChannel: ReleaseChannel indicates which release channel a cluster is +// subscribed to. Release channels are arranged in order of risk. When a +// cluster is subscribed to a release channel, Google maintains both the master +// version and the node version. Node auto-upgrade defaults to true and cannot +// be disabled. type ReleaseChannel struct { - // Channel: channel specifies which release channel the cluster is - // subscribed to. + // Channel: channel specifies which release channel the cluster is subscribed + // to. // // Possible values: // "UNSPECIFIED" - No channel specified. - // "RAPID" - RAPID channel is offered on an early access basis for - // customers who want to test new releases. WARNING: Versions available - // in the RAPID Channel may be subject to unresolved issues with no - // known workaround and are not subject to any SLAs. - // "REGULAR" - Clusters subscribed to REGULAR receive versions that - // are considered GA quality. REGULAR is intended for production users - // who want to take advantage of new features. - // "STABLE" - Clusters subscribed to STABLE receive versions that are - // known to be stable and reliable in production. + // "RAPID" - RAPID channel is offered on an early access basis for customers + // who want to test new releases. WARNING: Versions available in the RAPID + // Channel may be subject to unresolved issues with no known workaround and are + // not subject to any SLAs. + // "REGULAR" - Clusters subscribed to REGULAR receive versions that are + // considered GA quality. REGULAR is intended for production users who want to + // take advantage of new features. + // "STABLE" - Clusters subscribed to STABLE receive versions that are known + // to be stable and reliable in production. Channel string `json:"channel,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Channel") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Channel") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Channel") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Channel") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ReleaseChannel) MarshalJSON() ([]byte, error) { type NoMethod ReleaseChannel - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ReleaseChannelConfig: ReleaseChannelConfig exposes configuration for -// a release channel. +// ReleaseChannelConfig: ReleaseChannelConfig exposes configuration for a +// release channel. type ReleaseChannelConfig struct { - // AvailableVersions: Deprecated. This field has been deprecated and - // replaced with the valid_versions field. + // AvailableVersions: Deprecated. This field has been deprecated and replaced + // with the valid_versions field. AvailableVersions []*AvailableVersion `json:"availableVersions,omitempty"` - // Channel: The release channel this configuration applies to. // // Possible values: // "UNSPECIFIED" - No channel specified. - // "RAPID" - RAPID channel is offered on an early access basis for - // customers who want to test new releases. WARNING: Versions available - // in the RAPID Channel may be subject to unresolved issues with no - // known workaround and are not subject to any SLAs. - // "REGULAR" - Clusters subscribed to REGULAR receive versions that - // are considered GA quality. REGULAR is intended for production users - // who want to take advantage of new features. - // "STABLE" - Clusters subscribed to STABLE receive versions that are - // known to be stable and reliable in production. + // "RAPID" - RAPID channel is offered on an early access basis for customers + // who want to test new releases. WARNING: Versions available in the RAPID + // Channel may be subject to unresolved issues with no known workaround and are + // not subject to any SLAs. + // "REGULAR" - Clusters subscribed to REGULAR receive versions that are + // considered GA quality. REGULAR is intended for production users who want to + // take advantage of new features. + // "STABLE" - Clusters subscribed to STABLE receive versions that are known + // to be stable and reliable in production. Channel string `json:"channel,omitempty"` - // DefaultVersion: The default version for newly created clusters on the // channel. DefaultVersion string `json:"defaultVersion,omitempty"` - // ValidVersions: List of valid versions for the channel. ValidVersions []string `json:"validVersions,omitempty"` - - // ForceSendFields is a list of field names (e.g. "AvailableVersions") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AvailableVersions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AvailableVersions") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AvailableVersions") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ReleaseChannelConfig) MarshalJSON() ([]byte, error) { type NoMethod ReleaseChannelConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ReservationAffinity: ReservationAffinity // (https://cloud.google.com/compute/docs/instances/reserving-zonal-resources) -// is the configuration of desired reservation which instances could -// take capacity from. +// is the configuration of desired reservation which instances could take +// capacity from. type ReservationAffinity struct { - // ConsumeReservationType: Corresponds to the type of reservation - // consumption. + // ConsumeReservationType: Corresponds to the type of reservation consumption. // // Possible values: // "UNSPECIFIED" - Default value. This should not be used. // "NO_RESERVATION" - Do not consume from any reserved capacity. // "ANY_RESERVATION" - Consume any reservation available. - // "SPECIFIC_RESERVATION" - Must consume from a specific reservation. - // Must specify key value fields for specifying the reservations. + // "SPECIFIC_RESERVATION" - Must consume from a specific reservation. Must + // specify key value fields for specifying the reservations. ConsumeReservationType string `json:"consumeReservationType,omitempty"` - - // Key: Corresponds to the label key of a reservation resource. To - // target a SPECIFIC_RESERVATION by name, specify - // "compute.googleapis.com/reservation-name" as the key and specify the - // name of your reservation as its value. + // Key: Corresponds to the label key of a reservation resource. To target a + // SPECIFIC_RESERVATION by name, specify + // "compute.googleapis.com/reservation-name" as the key and specify the name of + // your reservation as its value. Key string `json:"key,omitempty"` - // Values: Corresponds to the label value(s) of reservation resource(s). Values []string `json:"values,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "ConsumeReservationType") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "ConsumeReservationType") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ConsumeReservationType") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ConsumeReservationType") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ReservationAffinity) MarshalJSON() ([]byte, error) { type NoMethod ReservationAffinity - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ResourceLabels: Collection of GCP labels @@ -7331,275 +5791,218 @@ func (s *ReservationAffinity) MarshalJSON() ([]byte, error) { type ResourceLabels struct { // Labels: Map of node label keys and node label values. Labels map[string]string `json:"labels,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Labels") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Labels") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Labels") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ResourceLabels) MarshalJSON() ([]byte, error) { type NoMethod ResourceLabels - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ResourceLimit: Contains information about amount of some resource in -// the cluster. For memory, value should be in GB. +// ResourceLimit: Contains information about amount of some resource in the +// cluster. For memory, value should be in GB. type ResourceLimit struct { // Maximum: Maximum amount of the resource in the cluster. Maximum int64 `json:"maximum,omitempty,string"` - // Minimum: Minimum amount of the resource in the cluster. Minimum int64 `json:"minimum,omitempty,string"` - // ResourceType: Resource name "cpu", "memory" or gpu-specific string. ResourceType string `json:"resourceType,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Maximum") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Maximum") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Maximum") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Maximum") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ResourceLimit) MarshalJSON() ([]byte, error) { type NoMethod ResourceLimit - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ResourceManagerTags: A map of resource manager tag keys and values to -// be attached to the nodes for managing Compute Engine firewalls using -// Network Firewall Policies. Tags must be according to specifications -// in -// https://cloud.google.com/vpc/docs/tags-firewalls-overview#specifications. -// A maximum of 5 tag key-value pairs can be specified. Existing tags -// will be replaced with new values. +// ResourceManagerTags: A map of resource manager tag keys and values to be +// attached to the nodes for managing Compute Engine firewalls using Network +// Firewall Policies. Tags must be according to specifications in +// https://cloud.google.com/vpc/docs/tags-firewalls-overview#specifications. A +// maximum of 5 tag key-value pairs can be specified. Existing tags will be +// replaced with new values. type ResourceManagerTags struct { // Tags: Tags must be in one of the following formats ([KEY]=[VALUE]) 1. // `tagKeys/{tag_key_id}=tagValues/{tag_value_id}` 2. // `{org_id}/{tag_key_name}={tag_value_name}` 3. // `{project_id}/{tag_key_name}={tag_value_name}` Tags map[string]string `json:"tags,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Tags") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Tags") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Tags") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Tags") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ResourceManagerTags) MarshalJSON() ([]byte, error) { type NoMethod ResourceManagerTags - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ResourceUsageExportConfig: Configuration for exporting cluster -// resource usages. +// ResourceUsageExportConfig: Configuration for exporting cluster resource +// usages. type ResourceUsageExportConfig struct { // BigqueryDestination: Configuration to use BigQuery as usage export // destination. BigqueryDestination *BigQueryDestination `json:"bigqueryDestination,omitempty"` - - // ConsumptionMeteringConfig: Configuration to enable resource - // consumption metering. + // ConsumptionMeteringConfig: Configuration to enable resource consumption + // metering. ConsumptionMeteringConfig *ConsumptionMeteringConfig `json:"consumptionMeteringConfig,omitempty"` - - // EnableNetworkEgressMetering: Whether to enable network egress - // metering for this cluster. If enabled, a daemonset will be created in - // the cluster to meter network egress traffic. + // EnableNetworkEgressMetering: Whether to enable network egress metering for + // this cluster. If enabled, a daemonset will be created in the cluster to + // meter network egress traffic. EnableNetworkEgressMetering bool `json:"enableNetworkEgressMetering,omitempty"` - - // ForceSendFields is a list of field names (e.g. "BigqueryDestination") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "BigqueryDestination") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "BigqueryDestination") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "BigqueryDestination") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ResourceUsageExportConfig) MarshalJSON() ([]byte, error) { type NoMethod ResourceUsageExportConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// RollbackNodePoolUpgradeRequest: RollbackNodePoolUpgradeRequest -// rollbacks the previously Aborted or Failed NodePool upgrade. This -// will be an no-op if the last upgrade successfully completed. +// RollbackNodePoolUpgradeRequest: RollbackNodePoolUpgradeRequest rollbacks the +// previously Aborted or Failed NodePool upgrade. This will be an no-op if the +// last upgrade successfully completed. type RollbackNodePoolUpgradeRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to rollback. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to rollback. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster, node pool id) of the node - // poll to rollback upgrade. Specified in the format + // Name: The name (project, location, cluster, node pool id) of the node poll + // to rollback upgrade. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. Name string `json:"name,omitempty"` - - // NodePoolId: Required. Deprecated. The name of the node pool to - // rollback. This field has been deprecated and replaced by the name - // field. + // NodePoolId: Required. Deprecated. The name of the node pool to rollback. + // This field has been deprecated and replaced by the name field. NodePoolId string `json:"nodePoolId,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // RespectPdb: Option for rollback to ignore the PodDisruptionBudget. - // Default value is false. + // RespectPdb: Option for rollback to ignore the PodDisruptionBudget. Default + // value is false. RespectPdb bool `json:"respectPdb,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *RollbackNodePoolUpgradeRequest) MarshalJSON() ([]byte, error) { type NoMethod RollbackNodePoolUpgradeRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SandboxConfig: SandboxConfig contains configurations of the sandbox -// to use for the node. +// SandboxConfig: SandboxConfig contains configurations of the sandbox to use +// for the node. type SandboxConfig struct { // SandboxType: Type of the sandbox to use for the node (e.g. 'gvisor') SandboxType string `json:"sandboxType,omitempty"` - // Type: Type of the sandbox to use for the node. // // Possible values: // "UNSPECIFIED" - Default value. This should not be used. // "GVISOR" - Run sandbox using gvisor. Type string `json:"type,omitempty"` - // ForceSendFields is a list of field names (e.g. "SandboxType") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "SandboxType") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "SandboxType") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SandboxConfig) MarshalJSON() ([]byte, error) { type NoMethod SandboxConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SecondaryBootDisk: SecondaryBootDisk represents a persistent disk -// attached to a node with special configurations based on its mode. +// SecondaryBootDisk: SecondaryBootDisk represents a persistent disk attached +// to a node with special configurations based on its mode. type SecondaryBootDisk struct { // DiskImage: Fully-qualified resource ID for an existing disk image. DiskImage string `json:"diskImage,omitempty"` - // Mode: Disk mode (container image cache, etc.) // // Possible values: // "MODE_UNSPECIFIED" - MODE_UNSPECIFIED is when mode is not set. - // "CONTAINER_IMAGE_CACHE" - CONTAINER_IMAGE_CACHE is for using the - // secondary boot disk as a container image cache. + // "CONTAINER_IMAGE_CACHE" - CONTAINER_IMAGE_CACHE is for using the secondary + // boot disk as a container image cache. Mode string `json:"mode,omitempty"` - // ForceSendFields is a list of field names (e.g. "DiskImage") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DiskImage") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DiskImage") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SecondaryBootDisk) MarshalJSON() ([]byte, error) { type NoMethod SecondaryBootDisk - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // SecondaryBootDiskUpdateStrategy: SecondaryBootDiskUpdateStrategy is a -// placeholder which will be extended in the future to define different -// options for updating secondary boot disks. +// placeholder which will be extended in the future to define different options +// for updating secondary boot disks. type SecondaryBootDiskUpdateStrategy struct { } @@ -7609,106 +6012,79 @@ type SecretManagerConfig struct { // Enabled: Whether the cluster is configured to use secret manager CSI // component. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SecretManagerConfig) MarshalJSON() ([]byte, error) { type NoMethod SecretManagerConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SecurityBulletinEvent: SecurityBulletinEvent is a notification sent -// to customers when a security bulletin has been posted that they are -// vulnerable to. +// SecurityBulletinEvent: SecurityBulletinEvent is a notification sent to +// customers when a security bulletin has been posted that they are vulnerable +// to. type SecurityBulletinEvent struct { // AffectedSupportedMinors: The GKE minor versions affected by this // vulnerability. AffectedSupportedMinors []string `json:"affectedSupportedMinors,omitempty"` - - // BriefDescription: A brief description of the bulletin. See the - // bulletin pointed to by the bulletin_uri field for an expanded - // description. + // BriefDescription: A brief description of the bulletin. See the bulletin + // pointed to by the bulletin_uri field for an expanded description. BriefDescription string `json:"briefDescription,omitempty"` - - // BulletinId: The ID of the bulletin corresponding to the - // vulnerability. + // BulletinId: The ID of the bulletin corresponding to the vulnerability. BulletinId string `json:"bulletinId,omitempty"` - // BulletinUri: The URI link to the bulletin on the website for more // information. BulletinUri string `json:"bulletinUri,omitempty"` - // CveIds: The CVEs associated with this bulletin. CveIds []string `json:"cveIds,omitempty"` - - // ManualStepsRequired: If this field is specified, it means there are - // manual steps that the user must take to make their clusters safe. + // ManualStepsRequired: If this field is specified, it means there are manual + // steps that the user must take to make their clusters safe. ManualStepsRequired bool `json:"manualStepsRequired,omitempty"` - - // PatchedVersions: The GKE versions where this vulnerability is - // patched. + // PatchedVersions: The GKE versions where this vulnerability is patched. PatchedVersions []string `json:"patchedVersions,omitempty"` - - // ResourceTypeAffected: The resource type (node/control plane) that has - // the vulnerability. Multiple notifications (1 notification per - // resource type) will be sent for a vulnerability that affects > 1 - // resource type. + // ResourceTypeAffected: The resource type (node/control plane) that has the + // vulnerability. Multiple notifications (1 notification per resource type) + // will be sent for a vulnerability that affects > 1 resource type. ResourceTypeAffected string `json:"resourceTypeAffected,omitempty"` - // Severity: The severity of this bulletin as it relates to GKE. Severity string `json:"severity,omitempty"` - // SuggestedUpgradeTarget: This represents a version selected from the - // patched_versions field that the cluster receiving this notification - // should most likely want to upgrade to based on its current version. - // Note that if this notification is being received by a given cluster, - // it means that this version is currently available as an upgrade - // target in that cluster's location. + // patched_versions field that the cluster receiving this notification should + // most likely want to upgrade to based on its current version. Note that if + // this notification is being received by a given cluster, it means that this + // version is currently available as an upgrade target in that cluster's + // location. SuggestedUpgradeTarget string `json:"suggestedUpgradeTarget,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "AffectedSupportedMinors") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "AffectedSupportedMinors") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AffectedSupportedMinors") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AffectedSupportedMinors") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SecurityBulletinEvent) MarshalJSON() ([]byte, error) { type NoMethod SecurityBulletinEvent - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SecurityPostureConfig: SecurityPostureConfig defines the flags needed -// to enable/disable features for the Security Posture API. +// SecurityPostureConfig: SecurityPostureConfig defines the flags needed to +// enable/disable features for the Security Posture API. type SecurityPostureConfig struct { // Mode: Sets which mode to use for Security Posture features. // @@ -7716,395 +6092,307 @@ type SecurityPostureConfig struct { // "MODE_UNSPECIFIED" - Default value not specified. // "DISABLED" - Disables Security Posture features on the cluster. // "BASIC" - Applies Security Posture features on the cluster. + // "ENTERPRISE" - Applies the Security Posture off cluster Enterprise level + // features. Mode string `json:"mode,omitempty"` - // VulnerabilityMode: Sets which mode to use for vulnerability scanning. // // Possible values: // "VULNERABILITY_MODE_UNSPECIFIED" - Default value not specified. - // "VULNERABILITY_DISABLED" - Disables vulnerability scanning on the - // cluster. + // "VULNERABILITY_DISABLED" - Disables vulnerability scanning on the cluster. // "VULNERABILITY_BASIC" - Applies basic vulnerability scanning on the // cluster. - // "VULNERABILITY_ENTERPRISE" - Applies the Security Posture's - // vulnerability on cluster Enterprise level features. + // "VULNERABILITY_ENTERPRISE" - Applies the Security Posture's vulnerability + // on cluster Enterprise level features. VulnerabilityMode string `json:"vulnerabilityMode,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Mode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Mode") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Mode") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Mode") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SecurityPostureConfig) MarshalJSON() ([]byte, error) { type NoMethod SecurityPostureConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ServerConfig: Kubernetes Engine service configuration. type ServerConfig struct { // Channels: List of release channel configurations. Channels []*ReleaseChannelConfig `json:"channels,omitempty"` - - // DefaultClusterVersion: Version of Kubernetes the service deploys by - // default. + // DefaultClusterVersion: Version of Kubernetes the service deploys by default. DefaultClusterVersion string `json:"defaultClusterVersion,omitempty"` - // DefaultImageType: Default image type. DefaultImageType string `json:"defaultImageType,omitempty"` - // ValidImageTypes: List of valid image types. ValidImageTypes []string `json:"validImageTypes,omitempty"` - - // ValidMasterVersions: List of valid master versions, in descending - // order. + // ValidMasterVersions: List of valid master versions, in descending order. ValidMasterVersions []string `json:"validMasterVersions,omitempty"` - - // ValidNodeVersions: List of valid node upgrade target versions, in - // descending order. + // ValidNodeVersions: List of valid node upgrade target versions, in descending + // order. ValidNodeVersions []string `json:"validNodeVersions,omitempty"` - - // WindowsVersionMaps: Maps of Kubernetes version and supported Windows - // server versions. + // WindowsVersionMaps: Maps of Kubernetes version and supported Windows server + // versions. WindowsVersionMaps map[string]WindowsVersions `json:"windowsVersionMaps,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Channels") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Channels") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Channels") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ServerConfig) MarshalJSON() ([]byte, error) { type NoMethod ServerConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ServiceExternalIPsConfig: Config to block services with externalIPs -// field. +// ServiceExternalIPsConfig: Config to block services with externalIPs field. type ServiceExternalIPsConfig struct { // Enabled: Whether Services with ExternalIPs field are allowed or not. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ServiceExternalIPsConfig) MarshalJSON() ([]byte, error) { type NoMethod ServiceExternalIPsConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetAddonsConfigRequest: SetAddonsRequest sets the addons associated -// with the cluster. +// SetAddonsConfigRequest: SetAddonsRequest sets the addons associated with the +// cluster. type SetAddonsConfigRequest struct { - // AddonsConfig: Required. The desired configurations for the various - // addons available to run in the cluster. + // AddonsConfig: Required. The desired configurations for the various addons + // available to run in the cluster. AddonsConfig *AddonsConfig `json:"addonsConfig,omitempty"` - - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster) of the cluster to set - // addons. Specified in the format `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster) of the cluster to set addons. + // Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "AddonsConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AddonsConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AddonsConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetAddonsConfigRequest) MarshalJSON() ([]byte, error) { type NoMethod SetAddonsConfigRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetLabelsRequest: SetLabelsRequest sets the Google Cloud Platform -// labels on a Google Container Engine cluster, which will in turn set -// them for Google Compute Engine resources used by that cluster +// SetLabelsRequest: SetLabelsRequest sets the Google Cloud Platform labels on +// a Google Container Engine cluster, which will in turn set them for Google +// Compute Engine resources used by that cluster type SetLabelsRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster. This field - // has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster. This field has + // been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // LabelFingerprint: Required. The fingerprint of the previous set of - // labels for this resource, used to detect conflicts. The fingerprint - // is initially generated by Kubernetes Engine and changes after every - // request to modify or update labels. You must always provide an - // up-to-date fingerprint hash when updating or changing labels. Make a - // `get()` request to the resource to get the latest fingerprint. + // LabelFingerprint: Required. The fingerprint of the previous set of labels + // for this resource, used to detect conflicts. The fingerprint is initially + // generated by Kubernetes Engine and changes after every request to modify or + // update labels. You must always provide an up-to-date fingerprint hash when + // updating or changing labels. Make a `get()` request to the resource to get + // the latest fingerprint. LabelFingerprint string `json:"labelFingerprint,omitempty"` - - // Name: The name (project, location, cluster name) of the cluster to - // set labels. Specified in the format - // `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster name) of the cluster to set + // labels. Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - // ResourceLabels: Required. The labels to set for that cluster. ResourceLabels map[string]string `json:"resourceLabels,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetLabelsRequest) MarshalJSON() ([]byte, error) { type NoMethod SetLabelsRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetLegacyAbacRequest: SetLegacyAbacRequest enables or disables the -// ABAC authorization mechanism for a cluster. +// SetLegacyAbacRequest: SetLegacyAbacRequest enables or disables the ABAC +// authorization mechanism for a cluster. type SetLegacyAbacRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to update. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to update. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - // Enabled: Required. Whether ABAC authorization will be enabled in the // cluster. Enabled bool `json:"enabled,omitempty"` - - // Name: The name (project, location, cluster name) of the cluster to - // set legacy abac. Specified in the format - // `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster name) of the cluster to set + // legacy abac. Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetLegacyAbacRequest) MarshalJSON() ([]byte, error) { type NoMethod SetLegacyAbacRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetLocationsRequest: SetLocationsRequest sets the locations of the -// cluster. +// SetLocationsRequest: SetLocationsRequest sets the locations of the cluster. type SetLocationsRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - // Locations: Required. The desired list of Google Compute Engine zones // (https://cloud.google.com/compute/docs/zones#available) in which the - // cluster's nodes should be located. Changing the locations a cluster - // is in will result in nodes being either created or removed from the - // cluster, depending on whether locations are being added or removed. - // This list must always include the cluster's primary zone. + // cluster's nodes should be located. Changing the locations a cluster is in + // will result in nodes being either created or removed from the cluster, + // depending on whether locations are being added or removed. This list must + // always include the cluster's primary zone. Locations []string `json:"locations,omitempty"` - - // Name: The name (project, location, cluster) of the cluster to set - // locations. Specified in the format - // `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster) of the cluster to set locations. + // Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetLocationsRequest) MarshalJSON() ([]byte, error) { type NoMethod SetLocationsRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetLoggingServiceRequest: SetLoggingServiceRequest sets the logging -// service of a cluster. +// SetLoggingServiceRequest: SetLoggingServiceRequest sets the logging service +// of a cluster. type SetLoggingServiceRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // LoggingService: Required. The logging service the cluster should use - // to write logs. Currently available options: * - // `logging.googleapis.com/kubernetes` - The Cloud Logging service with - // a Kubernetes-native resource model * `logging.googleapis.com` - The - // legacy Cloud Logging service (no longer available as of GKE 1.15). * - // `none` - no logs will be exported from the cluster. If left as an - // empty string,`logging.googleapis.com/kubernetes` will be used for GKE - // 1.14+ or `logging.googleapis.com` for earlier versions. + // LoggingService: Required. The logging service the cluster should use to + // write logs. Currently available options: * + // `logging.googleapis.com/kubernetes` - The Cloud Logging service with a + // Kubernetes-native resource model * `logging.googleapis.com` - The legacy + // Cloud Logging service (no longer available as of GKE 1.15). * `none` - no + // logs will be exported from the cluster. If left as an empty + // string,`logging.googleapis.com/kubernetes` will be used for GKE 1.14+ or + // `logging.googleapis.com` for earlier versions. LoggingService string `json:"loggingService,omitempty"` - - // Name: The name (project, location, cluster) of the cluster to set - // logging. Specified in the format `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster) of the cluster to set logging. + // Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetLoggingServiceRequest) MarshalJSON() ([]byte, error) { type NoMethod SetLoggingServiceRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // SetMaintenancePolicyRequest: SetMaintenancePolicyRequest sets the @@ -8112,218 +6400,171 @@ func (s *SetLoggingServiceRequest) MarshalJSON() ([]byte, error) { type SetMaintenancePolicyRequest struct { // ClusterId: Required. The name of the cluster to update. ClusterId string `json:"clusterId,omitempty"` - // MaintenancePolicy: Required. The maintenance policy to be set for the // cluster. An empty field clears the existing maintenance policy. MaintenancePolicy *MaintenancePolicy `json:"maintenancePolicy,omitempty"` - - // Name: The name (project, location, cluster name) of the cluster to - // set maintenance policy. Specified in the format + // Name: The name (project, location, cluster name) of the cluster to set + // maintenance policy. Specified in the format // `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. The Google Developers Console project ID or - // project number + // ProjectId: Required. The Google Developers Console project ID or project + // number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). ProjectId string `json:"projectId,omitempty"` - // Zone: Required. The name of the Google Compute Engine zone - // (https://cloud.google.com/compute/docs/zones#available) in which the - // cluster resides. + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetMaintenancePolicyRequest) MarshalJSON() ([]byte, error) { type NoMethod SetMaintenancePolicyRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetMasterAuthRequest: SetMasterAuthRequest updates the admin password -// of a cluster. +// SetMasterAuthRequest: SetMasterAuthRequest updates the admin password of a +// cluster. type SetMasterAuthRequest struct { - // Action: Required. The exact form of action to be taken on the master - // auth. + // Action: Required. The exact form of action to be taken on the master auth. // // Possible values: // "UNKNOWN" - Operation is unknown and will error out. // "SET_PASSWORD" - Set the password to a user generated value. // "GENERATE_PASSWORD" - Generate a new password and set it to that. - // "SET_USERNAME" - Set the username. If an empty username is - // provided, basic authentication is disabled for the cluster. If a - // non-empty username is provided, basic authentication is enabled, with - // either a provided password or a generated one. + // "SET_USERNAME" - Set the username. If an empty username is provided, basic + // authentication is disabled for the cluster. If a non-empty username is + // provided, basic authentication is enabled, with either a provided password + // or a generated one. Action string `json:"action,omitempty"` - - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster) of the cluster to set - // auth. Specified in the format `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster) of the cluster to set auth. + // Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - // Update: Required. A description of the update. Update *MasterAuth `json:"update,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Action") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Action") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Action") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetMasterAuthRequest) MarshalJSON() ([]byte, error) { type NoMethod SetMasterAuthRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetMonitoringServiceRequest: SetMonitoringServiceRequest sets the -// monitoring service of a cluster. +// SetMonitoringServiceRequest: SetMonitoringServiceRequest sets the monitoring +// service of a cluster. type SetMonitoringServiceRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // MonitoringService: Required. The monitoring service the cluster - // should use to write metrics. Currently available options: * - // "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service - // with a Kubernetes-native resource model * `monitoring.googleapis.com` - // - The legacy Cloud Monitoring service (no longer available as of GKE - // 1.15). * `none` - No metrics will be exported from the cluster. If - // left as an empty string,`monitoring.googleapis.com/kubernetes` will - // be used for GKE 1.14+ or `monitoring.googleapis.com` for earlier - // versions. + // MonitoringService: Required. The monitoring service the cluster should use + // to write metrics. Currently available options: * + // "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service with a + // Kubernetes-native resource model * `monitoring.googleapis.com` - The legacy + // Cloud Monitoring service (no longer available as of GKE 1.15). * `none` - No + // metrics will be exported from the cluster. If left as an empty + // string,`monitoring.googleapis.com/kubernetes` will be used for GKE 1.14+ or + // `monitoring.googleapis.com` for earlier versions. MonitoringService string `json:"monitoringService,omitempty"` - // Name: The name (project, location, cluster) of the cluster to set - // monitoring. Specified in the format - // `projects/*/locations/*/clusters/*`. + // monitoring. Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetMonitoringServiceRequest) MarshalJSON() ([]byte, error) { type NoMethod SetMonitoringServiceRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetNetworkPolicyRequest: SetNetworkPolicyRequest enables/disables -// network policy for a cluster. +// SetNetworkPolicyRequest: SetNetworkPolicyRequest enables/disables network +// policy for a cluster. type SetNetworkPolicyRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster. This field - // has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster. This field has + // been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster name) of the cluster to - // set networking policy. Specified in the format + // Name: The name (project, location, cluster name) of the cluster to set + // networking policy. Specified in the format // `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - // NetworkPolicy: Required. Configuration options for the NetworkPolicy // feature. NetworkPolicy *NetworkPolicy `json:"networkPolicy,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetNetworkPolicyRequest) MarshalJSON() ([]byte, error) { type NoMethod SetNetworkPolicyRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // SetNodePoolAutoscalingRequest: SetNodePoolAutoscalingRequest sets the @@ -8331,303 +6572,230 @@ func (s *SetNetworkPolicyRequest) MarshalJSON() ([]byte, error) { type SetNodePoolAutoscalingRequest struct { // Autoscaling: Required. Autoscaling configuration for the node pool. Autoscaling *NodePoolAutoscaling `json:"autoscaling,omitempty"` - - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster, node pool) of the node - // pool to set autoscaler settings. Specified in the format + // Name: The name (project, location, cluster, node pool) of the node pool to + // set autoscaler settings. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. Name string `json:"name,omitempty"` - - // NodePoolId: Required. Deprecated. The name of the node pool to - // upgrade. This field has been deprecated and replaced by the name - // field. + // NodePoolId: Required. Deprecated. The name of the node pool to upgrade. This + // field has been deprecated and replaced by the name field. NodePoolId string `json:"nodePoolId,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "Autoscaling") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Autoscaling") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Autoscaling") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetNodePoolAutoscalingRequest) MarshalJSON() ([]byte, error) { type NoMethod SetNodePoolAutoscalingRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetNodePoolManagementRequest: SetNodePoolManagementRequest sets the -// node management properties of a node pool. +// SetNodePoolManagementRequest: SetNodePoolManagementRequest sets the node +// management properties of a node pool. type SetNodePoolManagementRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to update. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to update. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - // Management: Required. NodeManagement configuration for the node pool. Management *NodeManagement `json:"management,omitempty"` - - // Name: The name (project, location, cluster, node pool id) of the node - // pool to set management properties. Specified in the format + // Name: The name (project, location, cluster, node pool id) of the node pool + // to set management properties. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. Name string `json:"name,omitempty"` - - // NodePoolId: Required. Deprecated. The name of the node pool to - // update. This field has been deprecated and replaced by the name - // field. + // NodePoolId: Required. Deprecated. The name of the node pool to update. This + // field has been deprecated and replaced by the name field. NodePoolId string `json:"nodePoolId,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetNodePoolManagementRequest) MarshalJSON() ([]byte, error) { type NoMethod SetNodePoolManagementRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SetNodePoolSizeRequest: SetNodePoolSizeRequest sets the size of a -// node pool. +// SetNodePoolSizeRequest: SetNodePoolSizeRequest sets the size of a node pool. type SetNodePoolSizeRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to update. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to update. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster, node pool id) of the node - // pool to set size. Specified in the format + // Name: The name (project, location, cluster, node pool id) of the node pool + // to set size. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. Name string `json:"name,omitempty"` - // NodeCount: Required. The desired node count for the pool. NodeCount int64 `json:"nodeCount,omitempty"` - - // NodePoolId: Required. Deprecated. The name of the node pool to - // update. This field has been deprecated and replaced by the name - // field. + // NodePoolId: Required. Deprecated. The name of the node pool to update. This + // field has been deprecated and replaced by the name field. NodePoolId string `json:"nodePoolId,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SetNodePoolSizeRequest) MarshalJSON() ([]byte, error) { type NoMethod SetNodePoolSizeRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ShieldedInstanceConfig: A set of Shielded Instance options. type ShieldedInstanceConfig struct { // EnableIntegrityMonitoring: Defines whether the instance has integrity - // monitoring enabled. Enables monitoring and attestation of the boot - // integrity of the instance. The attestation is performed against the - // integrity policy baseline. This baseline is initially derived from - // the implicitly trusted boot image when the instance is created. + // monitoring enabled. Enables monitoring and attestation of the boot integrity + // of the instance. The attestation is performed against the integrity policy + // baseline. This baseline is initially derived from the implicitly trusted + // boot image when the instance is created. EnableIntegrityMonitoring bool `json:"enableIntegrityMonitoring,omitempty"` - - // EnableSecureBoot: Defines whether the instance has Secure Boot - // enabled. Secure Boot helps ensure that the system only runs authentic - // software by verifying the digital signature of all boot components, - // and halting the boot process if signature verification fails. + // EnableSecureBoot: Defines whether the instance has Secure Boot enabled. + // Secure Boot helps ensure that the system only runs authentic software by + // verifying the digital signature of all boot components, and halting the boot + // process if signature verification fails. EnableSecureBoot bool `json:"enableSecureBoot,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "EnableIntegrityMonitoring") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "EnableIntegrityMonitoring") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. - // "EnableIntegrityMonitoring") to include in API requests with the JSON - // null value. By default, fields with empty values are omitted from API - // requests. However, any field with an empty value appearing in - // NullFields will be sent to the server as null. It is an error if a - // field in this list has a non-empty value. This may be used to include - // null fields in Patch requests. + // NullFields is a list of field names (e.g. "EnableIntegrityMonitoring") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ShieldedInstanceConfig) MarshalJSON() ([]byte, error) { type NoMethod ShieldedInstanceConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ShieldedNodes: Configuration of Shielded Nodes feature. type ShieldedNodes struct { - // Enabled: Whether Shielded Nodes features are enabled on all nodes in - // this cluster. + // Enabled: Whether Shielded Nodes features are enabled on all nodes in this + // cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ShieldedNodes) MarshalJSON() ([]byte, error) { type NoMethod ShieldedNodes - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// SoleTenantConfig: SoleTenantConfig contains the NodeAffinities to -// specify what shared sole tenant node groups should back the node -// pool. +// SoleTenantConfig: SoleTenantConfig contains the NodeAffinities to specify +// what shared sole tenant node groups should back the node pool. type SoleTenantConfig struct { - // NodeAffinities: NodeAffinities used to match to a shared sole tenant - // node group. + // NodeAffinities: NodeAffinities used to match to a shared sole tenant node + // group. NodeAffinities []*NodeAffinity `json:"nodeAffinities,omitempty"` - // ForceSendFields is a list of field names (e.g. "NodeAffinities") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NodeAffinities") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "NodeAffinities") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SoleTenantConfig) MarshalJSON() ([]byte, error) { type NoMethod SoleTenantConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// StandardRolloutPolicy: Standard rollout policy is the default policy -// for blue-green. +// StandardRolloutPolicy: Standard rollout policy is the default policy for +// blue-green. type StandardRolloutPolicy struct { // BatchNodeCount: Number of blue nodes to drain in a batch. BatchNodeCount int64 `json:"batchNodeCount,omitempty"` - - // BatchPercentage: Percentage of the blue pool nodes to drain in a - // batch. The range of this field should be (0.0, 1.0]. + // BatchPercentage: Percentage of the blue pool nodes to drain in a batch. The + // range of this field should be (0.0, 1.0]. BatchPercentage float64 `json:"batchPercentage,omitempty"` - - // BatchSoakDuration: Soak time after each batch gets drained. Default - // to zero. + // BatchSoakDuration: Soak time after each batch gets drained. Default to zero. BatchSoakDuration string `json:"batchSoakDuration,omitempty"` - // ForceSendFields is a list of field names (e.g. "BatchNodeCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "BatchNodeCount") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "BatchNodeCount") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *StandardRolloutPolicy) MarshalJSON() ([]byte, error) { type NoMethod StandardRolloutPolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } func (s *StandardRolloutPolicy) UnmarshalJSON(data []byte) error { @@ -8644,696 +6812,545 @@ func (s *StandardRolloutPolicy) UnmarshalJSON(data []byte) error { return nil } -// StartIPRotationRequest: StartIPRotationRequest creates a new IP for -// the cluster and then performs a node upgrade on each node pool to -// point to the new IP. +// StartIPRotationRequest: StartIPRotationRequest creates a new IP for the +// cluster and then performs a node upgrade on each node pool to point to the +// new IP. type StartIPRotationRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster. This field - // has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster. This field has + // been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // Name: The name (project, location, cluster name) of the cluster to - // start IP rotation. Specified in the format - // `projects/*/locations/*/clusters/*`. + // Name: The name (project, location, cluster name) of the cluster to start IP + // rotation. Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - // RotateCredentials: Whether to rotate credentials during IP rotation. RotateCredentials bool `json:"rotateCredentials,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *StartIPRotationRequest) MarshalJSON() ([]byte, error) { type NoMethod StartIPRotationRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // StatefulHAConfig: Configuration for the Stateful HA add-on. type StatefulHAConfig struct { // Enabled: Whether the Stateful HA add-on is enabled for this cluster. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *StatefulHAConfig) MarshalJSON() ([]byte, error) { type NoMethod StatefulHAConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// Status: The `Status` type defines a logical error model that is -// suitable for different programming environments, including REST APIs -// and RPC APIs. It is used by gRPC (https://github.com/grpc). Each -// `Status` message contains three pieces of data: error code, error -// message, and error details. You can find out more about this error -// model and how to work with it in the API Design Guide -// (https://cloud.google.com/apis/design/errors). +// Status: The `Status` type defines a logical error model that is suitable for +// different programming environments, including REST APIs and RPC APIs. It is +// used by gRPC (https://github.com/grpc). Each `Status` message contains three +// pieces of data: error code, error message, and error details. You can find +// out more about this error model and how to work with it in the API Design +// Guide (https://cloud.google.com/apis/design/errors). type Status struct { - // Code: The status code, which should be an enum value of - // google.rpc.Code. + // Code: The status code, which should be an enum value of google.rpc.Code. Code int64 `json:"code,omitempty"` - - // Details: A list of messages that carry the error details. There is a - // common set of message types for APIs to use. + // Details: A list of messages that carry the error details. There is a common + // set of message types for APIs to use. Details []googleapi.RawMessage `json:"details,omitempty"` - - // Message: A developer-facing error message, which should be in - // English. Any user-facing error message should be localized and sent - // in the google.rpc.Status.details field, or localized by the client. + // Message: A developer-facing error message, which should be in English. Any + // user-facing error message should be localized and sent in the + // google.rpc.Status.details field, or localized by the client. Message string `json:"message,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Code") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Code") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Code") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Code") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Status) MarshalJSON() ([]byte, error) { type NoMethod Status - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// StatusCondition: StatusCondition describes why a cluster or a node -// pool has a certain status (e.g., ERROR or DEGRADED). +// StatusCondition: StatusCondition describes why a cluster or a node pool has +// a certain status (e.g., ERROR or DEGRADED). type StatusCondition struct { // CanonicalCode: Canonical code of the condition. // // Possible values: // "OK" - Not an error; returned on success. HTTP Mapping: 200 OK - // "CANCELLED" - The operation was cancelled, typically by the caller. - // HTTP Mapping: 499 Client Closed Request - // "UNKNOWN" - Unknown error. For example, this error may be returned - // when a `Status` value received from another address space belongs to - // an error space that is not known in this address space. Also errors - // raised by APIs that do not return enough error information may be - // converted to this error. HTTP Mapping: 500 Internal Server Error - // "INVALID_ARGUMENT" - The client specified an invalid argument. Note - // that this differs from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` - // indicates arguments that are problematic regardless of the state of - // the system (e.g., a malformed file name). HTTP Mapping: 400 Bad - // Request - // "DEADLINE_EXCEEDED" - The deadline expired before the operation - // could complete. For operations that change the state of the system, - // this error may be returned even if the operation has completed - // successfully. For example, a successful response from a server could - // have been delayed long enough for the deadline to expire. HTTP - // Mapping: 504 Gateway Timeout - // "NOT_FOUND" - Some requested entity (e.g., file or directory) was - // not found. Note to server developers: if a request is denied for an - // entire class of users, such as gradual feature rollout or - // undocumented allowlist, `NOT_FOUND` may be used. If a request is - // denied for some users within a class of users, such as user-based - // access control, `PERMISSION_DENIED` must be used. HTTP Mapping: 404 - // Not Found - // "ALREADY_EXISTS" - The entity that a client attempted to create - // (e.g., file or directory) already exists. HTTP Mapping: 409 Conflict - // "PERMISSION_DENIED" - The caller does not have permission to - // execute the specified operation. `PERMISSION_DENIED` must not be used - // for rejections caused by exhausting some resource (use - // `RESOURCE_EXHAUSTED` instead for those errors). `PERMISSION_DENIED` - // must not be used if the caller can not be identified (use - // `UNAUTHENTICATED` instead for those errors). This error code does not - // imply the request is valid or the requested entity exists or + // "CANCELLED" - The operation was cancelled, typically by the caller. HTTP + // Mapping: 499 Client Closed Request + // "UNKNOWN" - Unknown error. For example, this error may be returned when a + // `Status` value received from another address space belongs to an error space + // that is not known in this address space. Also errors raised by APIs that do + // not return enough error information may be converted to this error. HTTP + // Mapping: 500 Internal Server Error + // "INVALID_ARGUMENT" - The client specified an invalid argument. Note that + // this differs from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates + // arguments that are problematic regardless of the state of the system (e.g., + // a malformed file name). HTTP Mapping: 400 Bad Request + // "DEADLINE_EXCEEDED" - The deadline expired before the operation could + // complete. For operations that change the state of the system, this error may + // be returned even if the operation has completed successfully. For example, a + // successful response from a server could have been delayed long enough for + // the deadline to expire. HTTP Mapping: 504 Gateway Timeout + // "NOT_FOUND" - Some requested entity (e.g., file or directory) was not + // found. Note to server developers: if a request is denied for an entire class + // of users, such as gradual feature rollout or undocumented allowlist, + // `NOT_FOUND` may be used. If a request is denied for some users within a + // class of users, such as user-based access control, `PERMISSION_DENIED` must + // be used. HTTP Mapping: 404 Not Found + // "ALREADY_EXISTS" - The entity that a client attempted to create (e.g., + // file or directory) already exists. HTTP Mapping: 409 Conflict + // "PERMISSION_DENIED" - The caller does not have permission to execute the + // specified operation. `PERMISSION_DENIED` must not be used for rejections + // caused by exhausting some resource (use `RESOURCE_EXHAUSTED` instead for + // those errors). `PERMISSION_DENIED` must not be used if the caller can not be + // identified (use `UNAUTHENTICATED` instead for those errors). This error code + // does not imply the request is valid or the requested entity exists or // satisfies other pre-conditions. HTTP Mapping: 403 Forbidden // "UNAUTHENTICATED" - The request does not have valid authentication // credentials for the operation. HTTP Mapping: 401 Unauthorized // "RESOURCE_EXHAUSTED" - Some resource has been exhausted, perhaps a - // per-user quota, or perhaps the entire file system is out of space. - // HTTP Mapping: 429 Too Many Requests - // "FAILED_PRECONDITION" - The operation was rejected because the - // system is not in a state required for the operation's execution. For - // example, the directory to be deleted is non-empty, an rmdir operation - // is applied to a non-directory, etc. Service implementors can use the - // following guidelines to decide between `FAILED_PRECONDITION`, - // `ABORTED`, and `UNAVAILABLE`: (a) Use `UNAVAILABLE` if the client can - // retry just the failing call. (b) Use `ABORTED` if the client should - // retry at a higher level. For example, when a client-specified - // test-and-set fails, indicating the client should restart a - // read-modify-write sequence. (c) Use `FAILED_PRECONDITION` if the - // client should not retry until the system state has been explicitly - // fixed. For example, if an "rmdir" fails because the directory is - // non-empty, `FAILED_PRECONDITION` should be returned since the client - // should not retry unless the files are deleted from the directory. - // HTTP Mapping: 400 Bad Request - // "ABORTED" - The operation was aborted, typically due to a - // concurrency issue such as a sequencer check failure or transaction - // abort. See the guidelines above for deciding between - // `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`. HTTP Mapping: - // 409 Conflict - // "OUT_OF_RANGE" - The operation was attempted past the valid range. - // E.g., seeking or reading past end-of-file. Unlike `INVALID_ARGUMENT`, - // this error indicates a problem that may be fixed if the system state - // changes. For example, a 32-bit file system will generate - // `INVALID_ARGUMENT` if asked to read at an offset that is not in the - // range [0,2^32-1], but it will generate `OUT_OF_RANGE` if asked to - // read from an offset past the current file size. There is a fair bit - // of overlap between `FAILED_PRECONDITION` and `OUT_OF_RANGE`. We - // recommend using `OUT_OF_RANGE` (the more specific error) when it - // applies so that callers who are iterating through a space can easily - // look for an `OUT_OF_RANGE` error to detect when they are done. HTTP - // Mapping: 400 Bad Request + // per-user quota, or perhaps the entire file system is out of space. HTTP + // Mapping: 429 Too Many Requests + // "FAILED_PRECONDITION" - The operation was rejected because the system is + // not in a state required for the operation's execution. For example, the + // directory to be deleted is non-empty, an rmdir operation is applied to a + // non-directory, etc. Service implementors can use the following guidelines to + // decide between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`: (a) Use + // `UNAVAILABLE` if the client can retry just the failing call. (b) Use + // `ABORTED` if the client should retry at a higher level. For example, when a + // client-specified test-and-set fails, indicating the client should restart a + // read-modify-write sequence. (c) Use `FAILED_PRECONDITION` if the client + // should not retry until the system state has been explicitly fixed. For + // example, if an "rmdir" fails because the directory is non-empty, + // `FAILED_PRECONDITION` should be returned since the client should not retry + // unless the files are deleted from the directory. HTTP Mapping: 400 Bad + // Request + // "ABORTED" - The operation was aborted, typically due to a concurrency + // issue such as a sequencer check failure or transaction abort. See the + // guidelines above for deciding between `FAILED_PRECONDITION`, `ABORTED`, and + // `UNAVAILABLE`. HTTP Mapping: 409 Conflict + // "OUT_OF_RANGE" - The operation was attempted past the valid range. E.g., + // seeking or reading past end-of-file. Unlike `INVALID_ARGUMENT`, this error + // indicates a problem that may be fixed if the system state changes. For + // example, a 32-bit file system will generate `INVALID_ARGUMENT` if asked to + // read at an offset that is not in the range [0,2^32-1], but it will generate + // `OUT_OF_RANGE` if asked to read from an offset past the current file size. + // There is a fair bit of overlap between `FAILED_PRECONDITION` and + // `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific error) + // when it applies so that callers who are iterating through a space can easily + // look for an `OUT_OF_RANGE` error to detect when they are done. HTTP Mapping: + // 400 Bad Request // "UNIMPLEMENTED" - The operation is not implemented or is not // supported/enabled in this service. HTTP Mapping: 501 Not Implemented - // "INTERNAL" - Internal errors. This means that some invariants - // expected by the underlying system have been broken. This error code - // is reserved for serious errors. HTTP Mapping: 500 Internal Server - // Error - // "UNAVAILABLE" - The service is currently unavailable. This is most - // likely a transient condition, which can be corrected by retrying with - // a backoff. Note that it is not always safe to retry non-idempotent - // operations. See the guidelines above for deciding between - // `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`. HTTP Mapping: - // 503 Service Unavailable - // "DATA_LOSS" - Unrecoverable data loss or corruption. HTTP Mapping: - // 500 Internal Server Error + // "INTERNAL" - Internal errors. This means that some invariants expected by + // the underlying system have been broken. This error code is reserved for + // serious errors. HTTP Mapping: 500 Internal Server Error + // "UNAVAILABLE" - The service is currently unavailable. This is most likely + // a transient condition, which can be corrected by retrying with a backoff. + // Note that it is not always safe to retry non-idempotent operations. See the + // guidelines above for deciding between `FAILED_PRECONDITION`, `ABORTED`, and + // `UNAVAILABLE`. HTTP Mapping: 503 Service Unavailable + // "DATA_LOSS" - Unrecoverable data loss or corruption. HTTP Mapping: 500 + // Internal Server Error CanonicalCode string `json:"canonicalCode,omitempty"` - - // Code: Machine-friendly representation of the condition Deprecated. - // Use canonical_code instead. + // Code: Machine-friendly representation of the condition Deprecated. Use + // canonical_code instead. // // Possible values: // "UNKNOWN" - UNKNOWN indicates a generic condition. // "GCE_STOCKOUT" - GCE_STOCKOUT indicates that Google Compute Engine // resources are temporarily unavailable. - // "GKE_SERVICE_ACCOUNT_DELETED" - GKE_SERVICE_ACCOUNT_DELETED - // indicates that the user deleted their robot service account. + // "GKE_SERVICE_ACCOUNT_DELETED" - GKE_SERVICE_ACCOUNT_DELETED indicates that + // the user deleted their robot service account. // "GCE_QUOTA_EXCEEDED" - Google Compute Engine quota was exceeded. - // "SET_BY_OPERATOR" - Cluster state was manually changed by an SRE - // due to a system logic error. - // "CLOUD_KMS_KEY_ERROR" - Unable to perform an encrypt operation - // against the CloudKMS key used for etcd level encryption. + // "SET_BY_OPERATOR" - Cluster state was manually changed by an SRE due to a + // system logic error. + // "CLOUD_KMS_KEY_ERROR" - Unable to perform an encrypt operation against the + // CloudKMS key used for etcd level encryption. // "CA_EXPIRING" - Cluster CA is expiring soon. More codes TBA Code string `json:"code,omitempty"` - // Message: Human-friendly representation of the condition Message string `json:"message,omitempty"` - // ForceSendFields is a list of field names (e.g. "CanonicalCode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CanonicalCode") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CanonicalCode") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *StatusCondition) MarshalJSON() ([]byte, error) { type NoMethod StatusCondition - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // TimeWindow: Represents an arbitrary window of time. type TimeWindow struct { - // EndTime: The time that the window ends. The end time should take - // place after the start time. + // EndTime: The time that the window ends. The end time should take place after + // the start time. EndTime string `json:"endTime,omitempty"` - // MaintenanceExclusionOptions: MaintenanceExclusionOptions provides // maintenance exclusion related options. MaintenanceExclusionOptions *MaintenanceExclusionOptions `json:"maintenanceExclusionOptions,omitempty"` - // StartTime: The time that the window first starts. StartTime string `json:"startTime,omitempty"` - - // ForceSendFields is a list of field names (e.g. "EndTime") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EndTime") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EndTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *TimeWindow) MarshalJSON() ([]byte, error) { type NoMethod TimeWindow - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // TpuConfig: Configuration for Cloud TPU. type TpuConfig struct { // Enabled: Whether Cloud TPU integration is enabled or not. Enabled bool `json:"enabled,omitempty"` - // Ipv4CidrBlock: IPv4 CIDR block reserved for Cloud TPU in the VPC. Ipv4CidrBlock string `json:"ipv4CidrBlock,omitempty"` - - // UseServiceNetworking: Whether to use service networking for Cloud TPU - // or not. + // UseServiceNetworking: Whether to use service networking for Cloud TPU or + // not. UseServiceNetworking bool `json:"useServiceNetworking,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *TpuConfig) MarshalJSON() ([]byte, error) { type NoMethod TpuConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // UpdateClusterRequest: UpdateClusterRequest updates the settings of a // cluster. type UpdateClusterRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - // Name: The name (project, location, cluster) of the cluster to update. // Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - // Update: Required. A description of the update. Update *ClusterUpdate `json:"update,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpdateClusterRequest) MarshalJSON() ([]byte, error) { type NoMethod UpdateClusterRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// UpdateInfo: UpdateInfo contains resource (instance groups, etc), -// status and other intermediate information relevant to a node pool -// upgrade. +// UpdateInfo: UpdateInfo contains resource (instance groups, etc), status and +// other intermediate information relevant to a node pool upgrade. type UpdateInfo struct { // BlueGreenInfo: Information of a blue-green upgrade. BlueGreenInfo *BlueGreenInfo `json:"blueGreenInfo,omitempty"` - // ForceSendFields is a list of field names (e.g. "BlueGreenInfo") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "BlueGreenInfo") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "BlueGreenInfo") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpdateInfo) MarshalJSON() ([]byte, error) { type NoMethod UpdateInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// UpdateMasterRequest: UpdateMasterRequest updates the master of the -// cluster. +// UpdateMasterRequest: UpdateMasterRequest updates the master of the cluster. type UpdateMasterRequest struct { - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // MasterVersion: Required. The Kubernetes version to change the master - // to. Users may specify either explicit versions offered by Kubernetes - // Engine or version aliases, which have the following behavior: - - // "latest": picks the highest valid Kubernetes version - "1.X": picks - // the highest valid patch+gke.N patch in the 1.X version - "1.X.Y": - // picks the highest valid gke.N patch in the 1.X.Y version - - // "1.X.Y-gke.N": picks an explicit Kubernetes version - "-": picks the - // default Kubernetes version + // MasterVersion: Required. The Kubernetes version to change the master to. + // Users may specify either explicit versions offered by Kubernetes Engine or + // version aliases, which have the following behavior: - "latest": picks the + // highest valid Kubernetes version - "1.X": picks the highest valid + // patch+gke.N patch in the 1.X version - "1.X.Y": picks the highest valid + // gke.N patch in the 1.X.Y version - "1.X.Y-gke.N": picks an explicit + // Kubernetes version - "-": picks the default Kubernetes version MasterVersion string `json:"masterVersion,omitempty"` - // Name: The name (project, location, cluster) of the cluster to update. // Specified in the format `projects/*/locations/*/clusters/*`. Name string `json:"name,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "ClusterId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ClusterId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ClusterId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpdateMasterRequest) MarshalJSON() ([]byte, error) { type NoMethod UpdateMasterRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// UpdateNodePoolRequest: SetNodePoolVersionRequest updates the version -// of a node pool. +// UpdateNodePoolRequest: SetNodePoolVersionRequest updates the version of a +// node pool. type UpdateNodePoolRequest struct { - // Accelerators: A list of hardware accelerators to be attached to each - // node. See https://cloud.google.com/compute/docs/gpus for more - // information about support for GPUs. + // Accelerators: A list of hardware accelerators to be attached to each node. + // See https://cloud.google.com/compute/docs/gpus for more information about + // support for GPUs. Accelerators []*AcceleratorConfig `json:"accelerators,omitempty"` - - // ClusterId: Required. Deprecated. The name of the cluster to upgrade. - // This field has been deprecated and replaced by the name field. + // ClusterId: Required. Deprecated. The name of the cluster to upgrade. This + // field has been deprecated and replaced by the name field. ClusterId string `json:"clusterId,omitempty"` - - // ConfidentialNodes: Confidential nodes config. All the nodes in the - // node pool will be Confidential VM once enabled. + // ConfidentialNodes: Confidential nodes config. All the nodes in the node pool + // will be Confidential VM once enabled. ConfidentialNodes *ConfidentialNodes `json:"confidentialNodes,omitempty"` - - // ContainerdConfig: The desired containerd config for nodes in the node - // pool. Initiates an upgrade operation that recreates the nodes with - // the new config. + // ContainerdConfig: The desired containerd config for nodes in the node pool. + // Initiates an upgrade operation that recreates the nodes with the new config. ContainerdConfig *ContainerdConfig `json:"containerdConfig,omitempty"` - - // DiskSizeGb: Optional. The desired disk size for nodes in the node - // pool. Initiates an upgrade operation that migrates the nodes in the - // node pool to the specified disk size. + // DiskSizeGb: Optional. The desired disk size for nodes in the node pool. + // Initiates an upgrade operation that migrates the nodes in the node pool to + // the specified disk size. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` - // DiskType: Optional. The desired disk type for nodes in the node pool. - // Initiates an upgrade operation that migrates the nodes in the node - // pool to the specified disk type. + // Initiates an upgrade operation that migrates the nodes in the node pool to + // the specified disk type. DiskType string `json:"diskType,omitempty"` - - // Etag: The current etag of the node pool. If an etag is provided and - // does not match the current etag of the node pool, update will be - // blocked and an ABORTED error will be returned. + // Etag: The current etag of the node pool. If an etag is provided and does not + // match the current etag of the node pool, update will be blocked and an + // ABORTED error will be returned. Etag string `json:"etag,omitempty"` - // FastSocket: Enable or disable NCCL fast socket for the node pool. FastSocket *FastSocket `json:"fastSocket,omitempty"` - // GcfsConfig: GCFS config. GcfsConfig *GcfsConfig `json:"gcfsConfig,omitempty"` - // Gvnic: Enable or disable gvnic on the node pool. Gvnic *VirtualNIC `json:"gvnic,omitempty"` - - // ImageType: Required. The desired image type for the node pool. Please - // see - // https://cloud.google.com/kubernetes-engine/docs/concepts/node-images - // for available image types. + // ImageType: Required. The desired image type for the node pool. Please see + // https://cloud.google.com/kubernetes-engine/docs/concepts/node-images for + // available image types. ImageType string `json:"imageType,omitempty"` - // KubeletConfig: Node kubelet configs. KubeletConfig *NodeKubeletConfig `json:"kubeletConfig,omitempty"` - - // Labels: The desired node labels to be applied to all nodes in the - // node pool. If this field is not present, the labels will not be - // changed. Otherwise, the existing node labels will be *replaced* with - // the provided labels. + // Labels: The desired node labels to be applied to all nodes in the node pool. + // If this field is not present, the labels will not be changed. Otherwise, the + // existing node labels will be *replaced* with the provided labels. Labels *NodeLabels `json:"labels,omitempty"` - // LinuxNodeConfig: Parameters that can be configured on Linux nodes. LinuxNodeConfig *LinuxNodeConfig `json:"linuxNodeConfig,omitempty"` - // Locations: The desired list of Google Compute Engine zones - // (https://cloud.google.com/compute/docs/zones#available) in which the - // node pool's nodes should be located. Changing the locations for a - // node pool will result in nodes being either created or removed from - // the node pool, depending on whether locations are being added or - // removed. + // (https://cloud.google.com/compute/docs/zones#available) in which the node + // pool's nodes should be located. Changing the locations for a node pool will + // result in nodes being either created or removed from the node pool, + // depending on whether locations are being added or removed. Locations []string `json:"locations,omitempty"` - // LoggingConfig: Logging configuration. LoggingConfig *NodePoolLoggingConfig `json:"loggingConfig,omitempty"` - - // MachineType: Optional. The desired machine type for nodes in the node - // pool. Initiates an upgrade operation that migrates the nodes in the - // node pool to the specified machine type. + // MachineType: Optional. The desired machine type for nodes in the node pool. + // Initiates an upgrade operation that migrates the nodes in the node pool to + // the specified machine type. MachineType string `json:"machineType,omitempty"` - - // Name: The name (project, location, cluster, node pool) of the node - // pool to update. Specified in the format + // Name: The name (project, location, cluster, node pool) of the node pool to + // update. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. Name string `json:"name,omitempty"` - // NodeNetworkConfig: Node network config. NodeNetworkConfig *NodeNetworkConfig `json:"nodeNetworkConfig,omitempty"` - - // NodePoolId: Required. Deprecated. The name of the node pool to - // upgrade. This field has been deprecated and replaced by the name - // field. + // NodePoolId: Required. Deprecated. The name of the node pool to upgrade. This + // field has been deprecated and replaced by the name field. NodePoolId string `json:"nodePoolId,omitempty"` - // NodeVersion: Required. The Kubernetes version to change the nodes to - // (typically an upgrade). Users may specify either explicit versions - // offered by Kubernetes Engine or version aliases, which have the - // following behavior: - "latest": picks the highest valid Kubernetes - // version - "1.X": picks the highest valid patch+gke.N patch in the 1.X - // version - "1.X.Y": picks the highest valid gke.N patch in the 1.X.Y - // version - "1.X.Y-gke.N": picks an explicit Kubernetes version - "-": - // picks the Kubernetes master version + // (typically an upgrade). Users may specify either explicit versions offered + // by Kubernetes Engine or version aliases, which have the following behavior: + // - "latest": picks the highest valid Kubernetes version - "1.X": picks the + // highest valid patch+gke.N patch in the 1.X version - "1.X.Y": picks the + // highest valid gke.N patch in the 1.X.Y version - "1.X.Y-gke.N": picks an + // explicit Kubernetes version - "-": picks the Kubernetes master version NodeVersion string `json:"nodeVersion,omitempty"` - - // ProjectId: Required. Deprecated. The Google Developers Console - // project ID or project number + // ProjectId: Required. Deprecated. The Google Developers Console project ID or + // project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. ProjectId string `json:"projectId,omitempty"` - - // QueuedProvisioning: Specifies the configuration of queued - // provisioning. + // QueuedProvisioning: Specifies the configuration of queued provisioning. QueuedProvisioning *QueuedProvisioning `json:"queuedProvisioning,omitempty"` - - // ResourceLabels: The resource labels for the node pool to use to - // annotate any related Google Compute Engine resources. + // ResourceLabels: The resource labels for the node pool to use to annotate any + // related Google Compute Engine resources. ResourceLabels *ResourceLabels `json:"resourceLabels,omitempty"` - - // ResourceManagerTags: Desired resource manager tag keys and values to - // be attached to the nodes for managing Compute Engine firewalls using - // Network Firewall Policies. Existing tags will be replaced with new - // values. + // ResourceManagerTags: Desired resource manager tag keys and values to be + // attached to the nodes for managing Compute Engine firewalls using Network + // Firewall Policies. Existing tags will be replaced with new values. ResourceManagerTags *ResourceManagerTags `json:"resourceManagerTags,omitempty"` - - // Tags: The desired network tags to be applied to all nodes in the node - // pool. If this field is not present, the tags will not be changed. - // Otherwise, the existing network tags will be *replaced* with the - // provided tags. + // Tags: The desired network tags to be applied to all nodes in the node pool. + // If this field is not present, the tags will not be changed. Otherwise, the + // existing network tags will be *replaced* with the provided tags. Tags *NetworkTags `json:"tags,omitempty"` - - // Taints: The desired node taints to be applied to all nodes in the - // node pool. If this field is not present, the taints will not be - // changed. Otherwise, the existing node taints will be *replaced* with - // the provided taints. + // Taints: The desired node taints to be applied to all nodes in the node pool. + // If this field is not present, the taints will not be changed. Otherwise, the + // existing node taints will be *replaced* with the provided taints. Taints *NodeTaints `json:"taints,omitempty"` - // UpgradeSettings: Upgrade settings control disruption and speed of the // upgrade. UpgradeSettings *UpgradeSettings `json:"upgradeSettings,omitempty"` - - // WindowsNodeConfig: Parameters that can be configured on Windows - // nodes. + // WindowsNodeConfig: Parameters that can be configured on Windows nodes. WindowsNodeConfig *WindowsNodeConfig `json:"windowsNodeConfig,omitempty"` - - // WorkloadMetadataConfig: The desired workload metadata config for the - // node pool. + // WorkloadMetadataConfig: The desired workload metadata config for the node + // pool. WorkloadMetadataConfig *WorkloadMetadataConfig `json:"workloadMetadataConfig,omitempty"` - - // Zone: Required. Deprecated. The name of the Google Compute Engine - // zone (https://cloud.google.com/compute/docs/zones#available) in which - // the cluster resides. This field has been deprecated and replaced by - // the name field. + // Zone: Required. Deprecated. The name of the Google Compute Engine zone + // (https://cloud.google.com/compute/docs/zones#available) in which the cluster + // resides. This field has been deprecated and replaced by the name field. Zone string `json:"zone,omitempty"` - // ForceSendFields is a list of field names (e.g. "Accelerators") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Accelerators") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Accelerators") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpdateNodePoolRequest) MarshalJSON() ([]byte, error) { type NoMethod UpdateNodePoolRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// UpgradeAvailableEvent: UpgradeAvailableEvent is a notification sent -// to customers when a new available version is released. +// UpgradeAvailableEvent: UpgradeAvailableEvent is a notification sent to +// customers when a new available version is released. type UpgradeAvailableEvent struct { - // ReleaseChannel: The release channel of the version. If empty, it - // means a non-channel release. + // ReleaseChannel: The release channel of the version. If empty, it means a + // non-channel release. ReleaseChannel *ReleaseChannel `json:"releaseChannel,omitempty"` - - // Resource: Optional relative path to the resource. For example, the - // relative path of the node pool. + // Resource: Optional relative path to the resource. For example, the relative + // path of the node pool. Resource string `json:"resource,omitempty"` - // ResourceType: The resource type of the release version. // // Possible values: - // "UPGRADE_RESOURCE_TYPE_UNSPECIFIED" - Default value. This shouldn't - // be used. + // "UPGRADE_RESOURCE_TYPE_UNSPECIFIED" - Default value. This shouldn't be + // used. // "MASTER" - Master / control plane // "NODE_POOL" - Node pool ResourceType string `json:"resourceType,omitempty"` - // Version: The release version available for upgrade. Version string `json:"version,omitempty"` - // WindowsVersions: Windows node versions info. WindowsVersions *WindowsVersions `json:"windowsVersions,omitempty"` - // ForceSendFields is a list of field names (e.g. "ReleaseChannel") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ReleaseChannel") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ReleaseChannel") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpgradeAvailableEvent) MarshalJSON() ([]byte, error) { type NoMethod UpgradeAvailableEvent - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // UpgradeEvent: UpgradeEvent is a notification sent to customers by the @@ -9341,636 +7358,505 @@ func (s *UpgradeAvailableEvent) MarshalJSON() ([]byte, error) { type UpgradeEvent struct { // CurrentVersion: The current version before the upgrade. CurrentVersion string `json:"currentVersion,omitempty"` - // Operation: The operation associated with this upgrade. Operation string `json:"operation,omitempty"` - // OperationStartTime: The time when the operation was started. OperationStartTime string `json:"operationStartTime,omitempty"` - - // Resource: Optional relative path to the resource. For example in node - // pool upgrades, the relative path of the node pool. + // Resource: Optional relative path to the resource. For example in node pool + // upgrades, the relative path of the node pool. Resource string `json:"resource,omitempty"` - // ResourceType: The resource type that is upgrading. // // Possible values: - // "UPGRADE_RESOURCE_TYPE_UNSPECIFIED" - Default value. This shouldn't - // be used. + // "UPGRADE_RESOURCE_TYPE_UNSPECIFIED" - Default value. This shouldn't be + // used. // "MASTER" - Master / control plane // "NODE_POOL" - Node pool ResourceType string `json:"resourceType,omitempty"` - // TargetVersion: The target version for the upgrade. TargetVersion string `json:"targetVersion,omitempty"` - // ForceSendFields is a list of field names (e.g. "CurrentVersion") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CurrentVersion") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "CurrentVersion") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpgradeEvent) MarshalJSON() ([]byte, error) { type NoMethod UpgradeEvent - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// UpgradeSettings: These upgrade settings control the level of -// parallelism and the level of disruption caused by an upgrade. -// maxUnavailable controls the number of nodes that can be -// simultaneously unavailable. maxSurge controls the number of -// additional nodes that can be added to the node pool temporarily for -// the time of the upgrade to increase the number of available nodes. -// (maxUnavailable + maxSurge) determines the level of parallelism (how -// many nodes are being upgraded at the same time). Note: upgrades -// inevitably introduce some disruption since workloads need to be moved -// from old nodes to new, upgraded ones. Even if maxUnavailable=0, this -// holds true. (Disruption stays within the limits of -// PodDisruptionBudget, if it is configured.) Consider a hypothetical -// node pool with 5 nodes having maxSurge=2, maxUnavailable=1. This -// means the upgrade process upgrades 3 nodes simultaneously. It creates -// 2 additional (upgraded) nodes, then it brings down 3 old (not yet -// upgraded) nodes at the same time. This ensures that there are always -// at least 4 nodes available. These upgrade settings configure the -// upgrade strategy for the node pool. Use strategy to switch between -// the strategies applied to the node pool. If the strategy is SURGE, -// use max_surge and max_unavailable to control the level of parallelism -// and the level of disruption caused by upgrade. 1. maxSurge controls + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// UpgradeSettings: These upgrade settings control the level of parallelism and +// the level of disruption caused by an upgrade. maxUnavailable controls the +// number of nodes that can be simultaneously unavailable. maxSurge controls // the number of additional nodes that can be added to the node pool -// temporarily for the time of the upgrade to increase the number of -// available nodes. 2. maxUnavailable controls the number of nodes that -// can be simultaneously unavailable. 3. (maxUnavailable + maxSurge) -// determines the level of parallelism (how many nodes are being -// upgraded at the same time). If the strategy is BLUE_GREEN, use -// blue_green_settings to configure the blue-green upgrade related -// settings. 1. standard_rollout_policy is the default policy. The -// policy is used to control the way blue pool gets drained. The -// draining is executed in the batch mode. The batch size could be -// specified as either percentage of the node pool size or the number of -// nodes. batch_soak_duration is the soak time after each batch gets -// drained. 2. node_pool_soak_duration is the soak time after all blue -// nodes are drained. After this period, the blue pool nodes will be -// deleted. +// temporarily for the time of the upgrade to increase the number of available +// nodes. (maxUnavailable + maxSurge) determines the level of parallelism (how +// many nodes are being upgraded at the same time). Note: upgrades inevitably +// introduce some disruption since workloads need to be moved from old nodes to +// new, upgraded ones. Even if maxUnavailable=0, this holds true. (Disruption +// stays within the limits of PodDisruptionBudget, if it is configured.) +// Consider a hypothetical node pool with 5 nodes having maxSurge=2, +// maxUnavailable=1. This means the upgrade process upgrades 3 nodes +// simultaneously. It creates 2 additional (upgraded) nodes, then it brings +// down 3 old (not yet upgraded) nodes at the same time. This ensures that +// there are always at least 4 nodes available. These upgrade settings +// configure the upgrade strategy for the node pool. Use strategy to switch +// between the strategies applied to the node pool. If the strategy is SURGE, +// use max_surge and max_unavailable to control the level of parallelism and +// the level of disruption caused by upgrade. 1. maxSurge controls the number +// of additional nodes that can be added to the node pool temporarily for the +// time of the upgrade to increase the number of available nodes. 2. +// maxUnavailable controls the number of nodes that can be simultaneously +// unavailable. 3. (maxUnavailable + maxSurge) determines the level of +// parallelism (how many nodes are being upgraded at the same time). If the +// strategy is BLUE_GREEN, use blue_green_settings to configure the blue-green +// upgrade related settings. 1. standard_rollout_policy is the default policy. +// The policy is used to control the way blue pool gets drained. The draining +// is executed in the batch mode. The batch size could be specified as either +// percentage of the node pool size or the number of nodes. batch_soak_duration +// is the soak time after each batch gets drained. 2. node_pool_soak_duration +// is the soak time after all blue nodes are drained. After this period, the +// blue pool nodes will be deleted. type UpgradeSettings struct { // BlueGreenSettings: Settings for blue-green upgrade strategy. BlueGreenSettings *BlueGreenSettings `json:"blueGreenSettings,omitempty"` - - // MaxSurge: The maximum number of nodes that can be created beyond the - // current size of the node pool during the upgrade process. + // MaxSurge: The maximum number of nodes that can be created beyond the current + // size of the node pool during the upgrade process. MaxSurge int64 `json:"maxSurge,omitempty"` - - // MaxUnavailable: The maximum number of nodes that can be - // simultaneously unavailable during the upgrade process. A node is - // considered available if its status is Ready. + // MaxUnavailable: The maximum number of nodes that can be simultaneously + // unavailable during the upgrade process. A node is considered available if + // its status is Ready. MaxUnavailable int64 `json:"maxUnavailable,omitempty"` - // Strategy: Update strategy of the node pool. // // Possible values: - // "NODE_POOL_UPDATE_STRATEGY_UNSPECIFIED" - Default value if unset. - // GKE internally defaults the update strategy to SURGE for unspecified - // strategies. + // "NODE_POOL_UPDATE_STRATEGY_UNSPECIFIED" - Default value if unset. GKE + // internally defaults the update strategy to SURGE for unspecified strategies. // "BLUE_GREEN" - blue-green upgrade. - // "SURGE" - SURGE is the traditional way of upgrading a node pool. - // max_surge and max_unavailable determines the level of upgrade - // parallelism. + // "SURGE" - SURGE is the traditional way of upgrading a node pool. max_surge + // and max_unavailable determines the level of upgrade parallelism. Strategy string `json:"strategy,omitempty"` - - // ForceSendFields is a list of field names (e.g. "BlueGreenSettings") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "BlueGreenSettings") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // ForceSendFields is a list of field names (e.g. "BlueGreenSettings") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "BlueGreenSettings") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UpgradeSettings) MarshalJSON() ([]byte, error) { type NoMethod UpgradeSettings - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// UsableSubnetwork: UsableSubnetwork resource returns the subnetwork -// name, its associated network and the primary CIDR range. +// UsableSubnetwork: UsableSubnetwork resource returns the subnetwork name, its +// associated network and the primary CIDR range. type UsableSubnetwork struct { // IpCidrRange: The range of internal addresses that are owned by this // subnetwork. IpCidrRange string `json:"ipCidrRange,omitempty"` - // Network: Network Name. Example: // projects/my-project/global/networks/my-network Network string `json:"network,omitempty"` - // SecondaryIpRanges: Secondary IP ranges. SecondaryIpRanges []*UsableSubnetworkSecondaryRange `json:"secondaryIpRanges,omitempty"` - - // StatusMessage: A human readable status message representing the - // reasons for cases where the caller cannot use the secondary ranges - // under the subnet. For example if the secondary_ip_ranges is empty due - // to a permission issue, an insufficient permission message will be - // given by status_message. + // StatusMessage: A human readable status message representing the reasons for + // cases where the caller cannot use the secondary ranges under the subnet. For + // example if the secondary_ip_ranges is empty due to a permission issue, an + // insufficient permission message will be given by status_message. StatusMessage string `json:"statusMessage,omitempty"` - // Subnetwork: Subnetwork Name. Example: // projects/my-project/regions/us-central1/subnetworks/my-subnet Subnetwork string `json:"subnetwork,omitempty"` - // ForceSendFields is a list of field names (e.g. "IpCidrRange") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "IpCidrRange") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "IpCidrRange") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UsableSubnetwork) MarshalJSON() ([]byte, error) { type NoMethod UsableSubnetwork - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// UsableSubnetworkSecondaryRange: Secondary IP range of a usable -// subnetwork. +// UsableSubnetworkSecondaryRange: Secondary IP range of a usable subnetwork. type UsableSubnetworkSecondaryRange struct { // IpCidrRange: The range of IP addresses belonging to this subnetwork // secondary range. IpCidrRange string `json:"ipCidrRange,omitempty"` - - // RangeName: The name associated with this subnetwork secondary range, - // used when adding an alias IP range to a VM instance. + // RangeName: The name associated with this subnetwork secondary range, used + // when adding an alias IP range to a VM instance. RangeName string `json:"rangeName,omitempty"` - // Status: This field is to determine the status of the secondary range // programmably. // // Possible values: - // "UNKNOWN" - UNKNOWN is the zero value of the Status enum. It's not - // a valid status. - // "UNUSED" - UNUSED denotes that this range is unclaimed by any - // cluster. - // "IN_USE_SERVICE" - IN_USE_SERVICE denotes that this range is - // claimed by a cluster for services. It cannot be used for other - // clusters. - // "IN_USE_SHAREABLE_POD" - IN_USE_SHAREABLE_POD denotes this range - // was created by the network admin and is currently claimed by a - // cluster for pods. It can only be used by other clusters as a pod - // range. - // "IN_USE_MANAGED_POD" - IN_USE_MANAGED_POD denotes this range was - // created by GKE and is claimed for pods. It cannot be used for other - // clusters. + // "UNKNOWN" - UNKNOWN is the zero value of the Status enum. It's not a valid + // status. + // "UNUSED" - UNUSED denotes that this range is unclaimed by any cluster. + // "IN_USE_SERVICE" - IN_USE_SERVICE denotes that this range is claimed by a + // cluster for services. It cannot be used for other clusters. + // "IN_USE_SHAREABLE_POD" - IN_USE_SHAREABLE_POD denotes this range was + // created by the network admin and is currently claimed by a cluster for pods. + // It can only be used by other clusters as a pod range. + // "IN_USE_MANAGED_POD" - IN_USE_MANAGED_POD denotes this range was created + // by GKE and is claimed for pods. It cannot be used for other clusters. Status string `json:"status,omitempty"` - // ForceSendFields is a list of field names (e.g. "IpCidrRange") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "IpCidrRange") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "IpCidrRange") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *UsableSubnetworkSecondaryRange) MarshalJSON() ([]byte, error) { type NoMethod UsableSubnetworkSecondaryRange - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// VerticalPodAutoscaling: VerticalPodAutoscaling contains global, -// per-cluster information required by Vertical Pod Autoscaler to -// automatically adjust the resources of pods controlled by it. +// VerticalPodAutoscaling: VerticalPodAutoscaling contains global, per-cluster +// information required by Vertical Pod Autoscaler to automatically adjust the +// resources of pods controlled by it. type VerticalPodAutoscaling struct { // Enabled: Enables vertical pod autoscaling. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *VerticalPodAutoscaling) MarshalJSON() ([]byte, error) { type NoMethod VerticalPodAutoscaling - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // VirtualNIC: Configuration of gVNIC feature. type VirtualNIC struct { // Enabled: Whether gVNIC features are enabled in the node pool. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *VirtualNIC) MarshalJSON() ([]byte, error) { type NoMethod VirtualNIC - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// WindowsNodeConfig: Parameters that can be configured on Windows -// nodes. Windows Node Config that define the parameters that will be -// used to configure the Windows node pool settings +// WindowsNodeConfig: Parameters that can be configured on Windows nodes. +// Windows Node Config that define the parameters that will be used to +// configure the Windows node pool settings type WindowsNodeConfig struct { - // OsVersion: OSVersion specifies the Windows node config to be used on - // the node + // OsVersion: OSVersion specifies the Windows node config to be used on the + // node // // Possible values: // "OS_VERSION_UNSPECIFIED" - When OSVersion is not specified - // "OS_VERSION_LTSC2019" - LTSC2019 specifies to use LTSC2019 as the - // Windows Servercore Base Image - // "OS_VERSION_LTSC2022" - LTSC2022 specifies to use LTSC2022 as the - // Windows Servercore Base Image + // "OS_VERSION_LTSC2019" - LTSC2019 specifies to use LTSC2019 as the Windows + // Servercore Base Image + // "OS_VERSION_LTSC2022" - LTSC2022 specifies to use LTSC2022 as the Windows + // Servercore Base Image OsVersion string `json:"osVersion,omitempty"` - // ForceSendFields is a list of field names (e.g. "OsVersion") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "OsVersion") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "OsVersion") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WindowsNodeConfig) MarshalJSON() ([]byte, error) { type NoMethod WindowsNodeConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // WindowsVersion: Windows server version. type WindowsVersion struct { // ImageType: Windows server image type ImageType string `json:"imageType,omitempty"` - // OsVersion: Windows server build number OsVersion string `json:"osVersion,omitempty"` - // SupportEndDate: Mainstream support end date SupportEndDate *Date `json:"supportEndDate,omitempty"` - // ForceSendFields is a list of field names (e.g. "ImageType") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ImageType") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ImageType") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WindowsVersion) MarshalJSON() ([]byte, error) { type NoMethod WindowsVersion - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // WindowsVersions: Windows server versions. type WindowsVersions struct { // WindowsVersions: List of Windows server versions. WindowsVersions []*WindowsVersion `json:"windowsVersions,omitempty"` - // ForceSendFields is a list of field names (e.g. "WindowsVersions") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "WindowsVersions") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "WindowsVersions") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WindowsVersions) MarshalJSON() ([]byte, error) { type NoMethod WindowsVersions - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// WorkloadALTSConfig: Configuration for direct-path (via ALTS) with -// workload identity. +// WorkloadALTSConfig: Configuration for direct-path (via ALTS) with workload +// identity. type WorkloadALTSConfig struct { - // EnableAlts: enable_alts controls whether the alts handshaker should - // be enabled or not for direct-path. Requires Workload Identity - // (workload_pool must be non-empty). + // EnableAlts: enable_alts controls whether the alts handshaker should be + // enabled or not for direct-path. Requires Workload Identity (workload_pool + // must be non-empty). EnableAlts bool `json:"enableAlts,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnableAlts") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnableAlts") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EnableAlts") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WorkloadALTSConfig) MarshalJSON() ([]byte, error) { type NoMethod WorkloadALTSConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // WorkloadCertificates: Configuration for issuance of mTLS keys and // certificates to Kubernetes pods. type WorkloadCertificates struct { - // EnableCertificates: enable_certificates controls issuance of workload - // mTLS certificates. If set, the GKE Workload Identity Certificates - // controller and node agent will be deployed in the cluster, which can - // then be configured by creating a WorkloadCertificateConfig Custom - // Resource. Requires Workload Identity (workload_pool must be - // non-empty). + // EnableCertificates: enable_certificates controls issuance of workload mTLS + // certificates. If set, the GKE Workload Identity Certificates controller and + // node agent will be deployed in the cluster, which can then be configured by + // creating a WorkloadCertificateConfig Custom Resource. Requires Workload + // Identity (workload_pool must be non-empty). EnableCertificates bool `json:"enableCertificates,omitempty"` - - // ForceSendFields is a list of field names (e.g. "EnableCertificates") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "EnableCertificates") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EnableCertificates") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EnableCertificates") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WorkloadCertificates) MarshalJSON() ([]byte, error) { type NoMethod WorkloadCertificates - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// WorkloadConfig: WorkloadConfig defines the flags to enable or disable -// the workload configurations for the cluster. +// WorkloadConfig: WorkloadConfig defines the flags to enable or disable the +// workload configurations for the cluster. type WorkloadConfig struct { - // AuditMode: Sets which mode of auditing should be used for the - // cluster's workloads. + // AuditMode: Sets which mode of auditing should be used for the cluster's + // workloads. // // Possible values: // "MODE_UNSPECIFIED" - Default value meaning that no mode has been // specified. - // "DISABLED" - This disables Workload Configuration auditing on the - // cluster, meaning that nothing is surfaced. + // "DISABLED" - This disables Workload Configuration auditing on the cluster, + // meaning that nothing is surfaced. // "BASIC" - Applies the default set of policy auditing to a cluster's // workloads. - // "BASELINE" - Surfaces configurations that are not in line with the - // Pod Security Standard Baseline policy. - // "RESTRICTED" - Surfaces configurations that are not in line with - // the Pod Security Standard Restricted policy. + // "BASELINE" - Surfaces configurations that are not in line with the Pod + // Security Standard Baseline policy. + // "RESTRICTED" - Surfaces configurations that are not in line with the Pod + // Security Standard Restricted policy. AuditMode string `json:"auditMode,omitempty"` - // ForceSendFields is a list of field names (e.g. "AuditMode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AuditMode") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AuditMode") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WorkloadConfig) MarshalJSON() ([]byte, error) { type NoMethod WorkloadConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// WorkloadIdentityConfig: Configuration for the use of Kubernetes -// Service Accounts in GCP IAM policies. +// WorkloadIdentityConfig: Configuration for the use of Kubernetes Service +// Accounts in GCP IAM policies. type WorkloadIdentityConfig struct { - // IdentityNamespace: IAM Identity Namespace to attach all Kubernetes - // Service Accounts to. + // IdentityNamespace: IAM Identity Namespace to attach all Kubernetes Service + // Accounts to. IdentityNamespace string `json:"identityNamespace,omitempty"` - - // IdentityProvider: identity provider is the third party identity - // provider. + // IdentityProvider: identity provider is the third party identity provider. IdentityProvider string `json:"identityProvider,omitempty"` - - // WorkloadPool: The workload pool to attach all Kubernetes service - // accounts to. + // WorkloadPool: The workload pool to attach all Kubernetes service accounts + // to. WorkloadPool string `json:"workloadPool,omitempty"` - - // ForceSendFields is a list of field names (e.g. "IdentityNamespace") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "IdentityNamespace") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "IdentityNamespace") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "IdentityNamespace") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WorkloadIdentityConfig) MarshalJSON() ([]byte, error) { type NoMethod WorkloadIdentityConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // WorkloadMetadataConfig: WorkloadMetadataConfig defines the metadata // configuration to expose to workloads on the node pool. type WorkloadMetadataConfig struct { - // Mode: Mode is the configuration for how to expose metadata to - // workloads running on the node pool. + // Mode: Mode is the configuration for how to expose metadata to workloads + // running on the node pool. // // Possible values: // "MODE_UNSPECIFIED" - Not set. // "GCE_METADATA" - Expose all Compute Engine metadata to pods. // "GKE_METADATA" - Run the GKE Metadata Server on this node. The GKE - // Metadata Server exposes a metadata API to workloads that is - // compatible with the V1 Compute Metadata APIs exposed by the Compute - // Engine and App Engine Metadata Servers. This feature can only be - // enabled if Workload Identity is enabled at the cluster level. + // Metadata Server exposes a metadata API to workloads that is compatible with + // the V1 Compute Metadata APIs exposed by the Compute Engine and App Engine + // Metadata Servers. This feature can only be enabled if Workload Identity is + // enabled at the cluster level. Mode string `json:"mode,omitempty"` - - // NodeMetadata: NodeMetadata is the configuration for how to expose - // metadata to the workloads running on the node. + // NodeMetadata: NodeMetadata is the configuration for how to expose metadata + // to the workloads running on the node. // // Possible values: // "UNSPECIFIED" - Not set. - // "SECURE" - Prevent workloads not in hostNetwork from accessing - // certain VM metadata, specifically kube-env, which contains Kubelet - // credentials, and the instance identity token. Metadata concealment is - // a temporary security solution available while the bootstrapping - // process for cluster nodes is being redesigned with significant - // security improvements. This feature is scheduled to be deprecated in - // the future and later removed. + // "SECURE" - Prevent workloads not in hostNetwork from accessing certain VM + // metadata, specifically kube-env, which contains Kubelet credentials, and the + // instance identity token. Metadata concealment is a temporary security + // solution available while the bootstrapping process for cluster nodes is + // being redesigned with significant security improvements. This feature is + // scheduled to be deprecated in the future and later removed. // "EXPOSE" - Expose all VM metadata to pods. - // "GKE_METADATA_SERVER" - Run the GKE Metadata Server on this node. - // The GKE Metadata Server exposes a metadata API to workloads that is - // compatible with the V1 Compute Metadata APIs exposed by the Compute - // Engine and App Engine Metadata Servers. This feature can only be - // enabled if Workload Identity is enabled at the cluster level. + // "GKE_METADATA_SERVER" - Run the GKE Metadata Server on this node. The GKE + // Metadata Server exposes a metadata API to workloads that is compatible with + // the V1 Compute Metadata APIs exposed by the Compute Engine and App Engine + // Metadata Servers. This feature can only be enabled if Workload Identity is + // enabled at the cluster level. NodeMetadata string `json:"nodeMetadata,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Mode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Mode") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Mode") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Mode") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WorkloadMetadataConfig) MarshalJSON() ([]byte, error) { type NoMethod WorkloadMetadataConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// WorkloadPolicyConfig: WorkloadPolicyConfig is the configuration of -// workload policy for autopilot clusters. +// WorkloadPolicyConfig: WorkloadPolicyConfig is the configuration of workload +// policy for autopilot clusters. type WorkloadPolicyConfig struct { // AllowNetAdmin: If true, workloads can use NET_ADMIN capability. AllowNetAdmin bool `json:"allowNetAdmin,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllowNetAdmin") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AllowNetAdmin") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AllowNetAdmin") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *WorkloadPolicyConfig) MarshalJSON() ([]byte, error) { type NoMethod WorkloadPolicyConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// method id "container.projects.aggregated.usableSubnetworks.list": - type ProjectsAggregatedUsableSubnetworksListCall struct { s *Service parent string @@ -9980,11 +7866,10 @@ type ProjectsAggregatedUsableSubnetworksListCall struct { header_ http.Header } -// List: Lists subnetworks that can be used for creating clusters in a -// project. +// List: Lists subnetworks that can be used for creating clusters in a project. // -// - parent: The parent project where subnetworks are usable. Specified -// in the format `projects/*`. +// - parent: The parent project where subnetworks are usable. Specified in the +// format `projects/*`. func (r *ProjectsAggregatedUsableSubnetworksService) List(parent string) *ProjectsAggregatedUsableSubnetworksListCall { c := &ProjectsAggregatedUsableSubnetworksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -9993,60 +7878,55 @@ func (r *ProjectsAggregatedUsableSubnetworksService) List(parent string) *Projec // Filter sets the optional parameter "filter": Filtering currently only // supports equality on the networkProjectId and must be in the form: -// "networkProjectId=[PROJECTID]", where `networkProjectId` is the -// project which owns the listed subnetworks. This defaults to the -// parent project ID. +// "networkProjectId=[PROJECTID]", where `networkProjectId` is the project +// which owns the listed subnetworks. This defaults to the parent project ID. func (c *ProjectsAggregatedUsableSubnetworksListCall) Filter(filter string) *ProjectsAggregatedUsableSubnetworksListCall { c.urlParams_.Set("filter", filter) return c } -// PageSize sets the optional parameter "pageSize": The max number of -// results per page that should be returned. If the number of available -// results is larger than `page_size`, a `next_page_token` is returned -// which can be used to get the next page of results in subsequent -// requests. Acceptable values are 0 to 500, inclusive. (Default: 500) +// PageSize sets the optional parameter "pageSize": The max number of results +// per page that should be returned. If the number of available results is +// larger than `page_size`, a `next_page_token` is returned which can be used +// to get the next page of results in subsequent requests. Acceptable values +// are 0 to 500, inclusive. (Default: 500) func (c *ProjectsAggregatedUsableSubnetworksListCall) PageSize(pageSize int64) *ProjectsAggregatedUsableSubnetworksListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": Specifies a page -// token to use. Set this to the nextPageToken returned by previous list -// requests to get the next page of results. +// PageToken sets the optional parameter "pageToken": Specifies a page token to +// use. Set this to the nextPageToken returned by previous list requests to get +// the next page of results. func (c *ProjectsAggregatedUsableSubnetworksListCall) PageToken(pageToken string) *ProjectsAggregatedUsableSubnetworksListCall { c.urlParams_.Set("pageToken", pageToken) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsAggregatedUsableSubnetworksListCall) Fields(s ...googleapi.Field) *ProjectsAggregatedUsableSubnetworksListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsAggregatedUsableSubnetworksListCall) IfNoneMatch(entityTag string) *ProjectsAggregatedUsableSubnetworksListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsAggregatedUsableSubnetworksListCall) Context(ctx context.Context) *ProjectsAggregatedUsableSubnetworksListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsAggregatedUsableSubnetworksListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10055,12 +7935,7 @@ func (c *ProjectsAggregatedUsableSubnetworksListCall) Header() http.Header { } func (c *ProjectsAggregatedUsableSubnetworksListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10081,12 +7956,11 @@ func (c *ProjectsAggregatedUsableSubnetworksListCall) doRequest(alt string) (*ht } // Do executes the "container.projects.aggregated.usableSubnetworks.list" call. -// Exactly one of *ListUsableSubnetworksResponse or error will be -// non-nil. Any non-2xx status code is an error. Response headers are in -// either *ListUsableSubnetworksResponse.ServerResponse.Header or (if a -// response was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListUsableSubnetworksResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ProjectsAggregatedUsableSubnetworksListCall) Do(opts ...googleapi.CallOption) (*ListUsableSubnetworksResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10117,48 +7991,6 @@ func (c *ProjectsAggregatedUsableSubnetworksListCall) Do(opts ...googleapi.CallO return nil, err } return ret, nil - // { - // "description": "Lists subnetworks that can be used for creating clusters in a project.", - // "flatPath": "v1beta1/projects/{projectsId}/aggregated/usableSubnetworks", - // "httpMethod": "GET", - // "id": "container.projects.aggregated.usableSubnetworks.list", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "filter": { - // "description": "Filtering currently only supports equality on the networkProjectId and must be in the form: \"networkProjectId=[PROJECTID]\", where `networkProjectId` is the project which owns the listed subnetworks. This defaults to the parent project ID.", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "The max number of results per page that should be returned. If the number of available results is larger than `page_size`, a `next_page_token` is returned which can be used to get the next page of results in subsequent requests. Acceptable values are 0 to 500, inclusive. (Default: 500)", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "Specifies a page token to use. Set this to the nextPageToken returned by previous list requests to get the next page of results.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The parent project where subnetworks are usable. Specified in the format `projects/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/aggregated/usableSubnetworks", - // "response": { - // "$ref": "ListUsableSubnetworksResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - } // Pages invokes f for each page of results. @@ -10166,7 +7998,7 @@ func (c *ProjectsAggregatedUsableSubnetworksListCall) Do(opts ...googleapi.CallO // The provided context supersedes any context provided to the Context method. func (c *ProjectsAggregatedUsableSubnetworksListCall) Pages(ctx context.Context, f func(*ListUsableSubnetworksResponse) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -10182,8 +8014,6 @@ func (c *ProjectsAggregatedUsableSubnetworksListCall) Pages(ctx context.Context, } } -// method id "container.projects.locations.getServerConfig": - type ProjectsLocationsGetServerConfigCall struct { s *Service name string @@ -10193,8 +8023,8 @@ type ProjectsLocationsGetServerConfigCall struct { header_ http.Header } -// GetServerConfig: Returns configuration info about the Google -// Kubernetes Engine service. +// GetServerConfig: Returns configuration info about the Google Kubernetes +// Engine service. // // - name: The name (project and location) of the server config to get, // specified in the format `projects/*/locations/*`. @@ -10204,9 +8034,8 @@ func (r *ProjectsLocationsService) GetServerConfig(name string) *ProjectsLocatio return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsGetServerConfigCall) ProjectId(projectId string) *ProjectsLocationsGetServerConfigCall { @@ -10214,44 +8043,39 @@ func (c *ProjectsLocationsGetServerConfigCall) ProjectId(projectId string) *Proj return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) to return -// operations for. This field has been deprecated and replaced by the -// name field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) to return operations +// for. This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsGetServerConfigCall) Zone(zone string) *ProjectsLocationsGetServerConfigCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsGetServerConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetServerConfigCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsGetServerConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetServerConfigCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsGetServerConfigCall) Context(ctx context.Context) *ProjectsLocationsGetServerConfigCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsGetServerConfigCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10260,12 +8084,7 @@ func (c *ProjectsLocationsGetServerConfigCall) Header() http.Header { } func (c *ProjectsLocationsGetServerConfigCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10286,12 +8105,10 @@ func (c *ProjectsLocationsGetServerConfigCall) doRequest(alt string) (*http.Resp } // Do executes the "container.projects.locations.getServerConfig" call. -// Exactly one of *ServerConfig or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *ServerConfig.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ServerConfig.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsGetServerConfigCall) Do(opts ...googleapi.CallOption) (*ServerConfig, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10322,47 +8139,7 @@ func (c *ProjectsLocationsGetServerConfigCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Returns configuration info about the Google Kubernetes Engine service.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverConfig", - // "httpMethod": "GET", - // "id": "container.projects.locations.getServerConfig", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project and location) of the server config to get, specified in the format `projects/*/locations/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) to return operations for. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}/serverConfig", - // "response": { - // "$ref": "ServerConfig" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.list": +} type ProjectsLocationsListCall struct { s *Service @@ -10375,8 +8152,8 @@ type ProjectsLocationsListCall struct { // List: Fetches locations that offer Google Kubernetes Engine. // -// - parent: Contains the name of the resource requested. Specified in -// the format `projects/*`. +// - parent: Contains the name of the resource requested. Specified in the +// format `projects/*`. func (r *ProjectsLocationsService) List(parent string) *ProjectsLocationsListCall { c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -10384,33 +8161,29 @@ func (r *ProjectsLocationsService) List(parent string) *ProjectsLocationsListCal } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10419,12 +8192,7 @@ func (c *ProjectsLocationsListCall) Header() http.Header { } func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10445,12 +8213,11 @@ func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error } // Do executes the "container.projects.locations.list" call. -// Exactly one of *ListLocationsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListLocationsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListLocationsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10481,35 +8248,7 @@ func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocat return nil, err } return ret, nil - // { - // "description": "Fetches locations that offer Google Kubernetes Engine.", - // "flatPath": "v1beta1/projects/{projectsId}/locations", - // "httpMethod": "GET", - // "id": "container.projects.locations.list", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "Required. Contains the name of the resource requested. Specified in the format `projects/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/locations", - // "response": { - // "$ref": "ListLocationsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.checkAutopilotCompatibility": +} type ProjectsLocationsClustersCheckAutopilotCompatibilityCall struct { s *Service @@ -10520,12 +8259,11 @@ type ProjectsLocationsClustersCheckAutopilotCompatibilityCall struct { header_ http.Header } -// CheckAutopilotCompatibility: Checks the cluster compatibility with -// Autopilot mode, and returns a list of compatibility issues. +// CheckAutopilotCompatibility: Checks the cluster compatibility with Autopilot +// mode, and returns a list of compatibility issues. // -// - name: The name (project, location, cluster) of the cluster to -// retrieve. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to retrieve. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) CheckAutopilotCompatibility(name string) *ProjectsLocationsClustersCheckAutopilotCompatibilityCall { c := &ProjectsLocationsClustersCheckAutopilotCompatibilityCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -10533,33 +8271,29 @@ func (r *ProjectsLocationsClustersService) CheckAutopilotCompatibility(name stri } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersCheckAutopilotCompatibilityCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersCheckAutopilotCompatibilityCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) Context(ctx context.Context) *ProjectsLocationsClustersCheckAutopilotCompatibilityCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10568,12 +8302,7 @@ func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) Header() http } func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10594,13 +8323,11 @@ func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) doRequest(alt } // Do executes the "container.projects.locations.clusters.checkAutopilotCompatibility" call. -// Exactly one of *CheckAutopilotCompatibilityResponse or error will be -// non-nil. Any non-2xx status code is an error. Response headers are in -// either *CheckAutopilotCompatibilityResponse.ServerResponse.Header or -// (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check -// whether the returned error was because http.StatusNotModified was -// returned. +// Any non-2xx status code is an error. Response headers are in either +// *CheckAutopilotCompatibilityResponse.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) Do(opts ...googleapi.CallOption) (*CheckAutopilotCompatibilityResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10631,35 +8358,7 @@ func (c *ProjectsLocationsClustersCheckAutopilotCompatibilityCall) Do(opts ...go return nil, err } return ret, nil - // { - // "description": "Checks the cluster compatibility with Autopilot mode, and returns a list of compatibility issues.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:checkAutopilotCompatibility", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.checkAutopilotCompatibility", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to retrieve. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:checkAutopilotCompatibility", - // "response": { - // "$ref": "CheckAutopilotCompatibilityResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.completeIpRotation": +} type ProjectsLocationsClustersCompleteIpRotationCall struct { s *Service @@ -10683,23 +8382,21 @@ func (r *ProjectsLocationsClustersService) CompleteIpRotation(name string, compl } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersCompleteIpRotationCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersCompleteIpRotationCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersCompleteIpRotationCall) Context(ctx context.Context) *ProjectsLocationsClustersCompleteIpRotationCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersCompleteIpRotationCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10708,18 +8405,12 @@ func (c *ProjectsLocationsClustersCompleteIpRotationCall) Header() http.Header { } func (c *ProjectsLocationsClustersCompleteIpRotationCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.completeiprotationrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:completeIpRotation") @@ -10736,12 +8427,10 @@ func (c *ProjectsLocationsClustersCompleteIpRotationCall) doRequest(alt string) } // Do executes the "container.projects.locations.clusters.completeIpRotation" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersCompleteIpRotationCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10772,38 +8461,7 @@ func (c *ProjectsLocationsClustersCompleteIpRotationCall) Do(opts ...googleapi.C return nil, err } return ret, nil - // { - // "description": "Completes master IP rotation.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:completeIpRotation", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.completeIpRotation", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster name) of the cluster to complete IP rotation. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:completeIpRotation", - // "request": { - // "$ref": "CompleteIPRotationRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.create": +} type ProjectsLocationsClustersCreateCall struct { s *Service @@ -10814,15 +8472,15 @@ type ProjectsLocationsClustersCreateCall struct { header_ http.Header } -// Create: Creates a cluster, consisting of the specified number and -// type of Google Compute Engine instances. By default, the cluster is -// created in the project's default network -// (https://cloud.google.com/compute/docs/networks-and-firewalls#networks). -// One firewall is added for the cluster. After cluster creation, the -// Kubelet creates routes for each node to allow the containers on that -// node to communicate with all other instances in the cluster. Finally, -// an entry is added to the project's global metadata indicating which -// CIDR range the cluster is using. +// Create: Creates a cluster, consisting of the specified number and type of +// Google Compute Engine instances. By default, the cluster is created in the +// project's default network +// (https://cloud.google.com/compute/docs/networks-and-firewalls#networks). One +// firewall is added for the cluster. After cluster creation, the Kubelet +// creates routes for each node to allow the containers on that node to +// communicate with all other instances in the cluster. Finally, an entry is +// added to the project's global metadata indicating which CIDR range the +// cluster is using. // // - parent: The parent (project and location) where the cluster will be // created. Specified in the format `projects/*/locations/*`. @@ -10834,23 +8492,21 @@ func (r *ProjectsLocationsClustersService) Create(parent string, createclusterre } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersCreateCall) Context(ctx context.Context) *ProjectsLocationsClustersCreateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10859,18 +8515,12 @@ func (c *ProjectsLocationsClustersCreateCall) Header() http.Header { } func (c *ProjectsLocationsClustersCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.createclusterrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/clusters") @@ -10887,12 +8537,10 @@ func (c *ProjectsLocationsClustersCreateCall) doRequest(alt string) (*http.Respo } // Do executes the "container.projects.locations.clusters.create" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10923,38 +8571,7 @@ func (c *ProjectsLocationsClustersCreateCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Creates a cluster, consisting of the specified number and type of Google Compute Engine instances. By default, the cluster is created in the project's [default network](https://cloud.google.com/compute/docs/networks-and-firewalls#networks). One firewall is added for the cluster. After cluster creation, the Kubelet creates routes for each node to allow the containers on that node to communicate with all other instances in the cluster. Finally, an entry is added to the project's global metadata indicating which CIDR range the cluster is using.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.create", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "The parent (project and location) where the cluster will be created. Specified in the format `projects/*/locations/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/clusters", - // "request": { - // "$ref": "CreateClusterRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.delete": +} type ProjectsLocationsClustersDeleteCall struct { s *Service @@ -10964,33 +8581,30 @@ type ProjectsLocationsClustersDeleteCall struct { header_ http.Header } -// Delete: Deletes the cluster, including the Kubernetes endpoint and -// all worker nodes. Firewalls and routes that were configured during -// cluster creation are also deleted. Other Google Compute Engine -// resources that might be in use by the cluster, such as load balancer -// resources, are not deleted if they weren't present when the cluster -// was initially created. +// Delete: Deletes the cluster, including the Kubernetes endpoint and all +// worker nodes. Firewalls and routes that were configured during cluster +// creation are also deleted. Other Google Compute Engine resources that might +// be in use by the cluster, such as load balancer resources, are not deleted +// if they weren't present when the cluster was initially created. // -// - name: The name (project, location, cluster) of the cluster to -// delete. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to delete. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) Delete(name string) *ProjectsLocationsClustersDeleteCall { c := &ProjectsLocationsClustersDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// ClusterId sets the optional parameter "clusterId": Required. -// Deprecated. The name of the cluster to delete. This field has been -// deprecated and replaced by the name field. +// ClusterId sets the optional parameter "clusterId": Required. Deprecated. The +// name of the cluster to delete. This field has been deprecated and replaced +// by the name field. func (c *ProjectsLocationsClustersDeleteCall) ClusterId(clusterId string) *ProjectsLocationsClustersDeleteCall { c.urlParams_.Set("clusterId", clusterId) return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersDeleteCall) ProjectId(projectId string) *ProjectsLocationsClustersDeleteCall { @@ -10998,34 +8612,31 @@ func (c *ProjectsLocationsClustersDeleteCall) ProjectId(projectId string) *Proje return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides. This field has been deprecated and replaced by the -// name field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides. This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersDeleteCall) Zone(zone string) *ProjectsLocationsClustersDeleteCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersDeleteCall) Context(ctx context.Context) *ProjectsLocationsClustersDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11034,12 +8645,7 @@ func (c *ProjectsLocationsClustersDeleteCall) Header() http.Header { } func (c *ProjectsLocationsClustersDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -11057,12 +8663,10 @@ func (c *ProjectsLocationsClustersDeleteCall) doRequest(alt string) (*http.Respo } // Do executes the "container.projects.locations.clusters.delete" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11093,53 +8697,7 @@ func (c *ProjectsLocationsClustersDeleteCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Deletes the cluster, including the Kubernetes endpoint and all worker nodes. Firewalls and routes that were configured during cluster creation are also deleted. Other Google Compute Engine resources that might be in use by the cluster, such as load balancer resources, are not deleted if they weren't present when the cluster was initially created.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}", - // "httpMethod": "DELETE", - // "id": "container.projects.locations.clusters.delete", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "clusterId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the cluster to delete. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster) of the cluster to delete. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.get": +} type ProjectsLocationsClustersGetCall struct { s *Service @@ -11152,26 +8710,24 @@ type ProjectsLocationsClustersGetCall struct { // Get: Gets the details for a specific cluster. // -// - name: The name (project, location, cluster) of the cluster to -// retrieve. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to retrieve. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) Get(name string) *ProjectsLocationsClustersGetCall { c := &ProjectsLocationsClustersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// ClusterId sets the optional parameter "clusterId": Required. -// Deprecated. The name of the cluster to retrieve. This field has been -// deprecated and replaced by the name field. +// ClusterId sets the optional parameter "clusterId": Required. Deprecated. The +// name of the cluster to retrieve. This field has been deprecated and replaced +// by the name field. func (c *ProjectsLocationsClustersGetCall) ClusterId(clusterId string) *ProjectsLocationsClustersGetCall { c.urlParams_.Set("clusterId", clusterId) return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersGetCall) ProjectId(projectId string) *ProjectsLocationsClustersGetCall { @@ -11179,44 +8735,39 @@ func (c *ProjectsLocationsClustersGetCall) ProjectId(projectId string) *Projects return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides. This field has been deprecated and replaced by the -// name field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides. This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersGetCall) Zone(zone string) *ProjectsLocationsClustersGetCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersGetCall) Context(ctx context.Context) *ProjectsLocationsClustersGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11225,12 +8776,7 @@ func (c *ProjectsLocationsClustersGetCall) Header() http.Header { } func (c *ProjectsLocationsClustersGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -11251,12 +8797,10 @@ func (c *ProjectsLocationsClustersGetCall) doRequest(alt string) (*http.Response } // Do executes the "container.projects.locations.clusters.get" call. -// Exactly one of *Cluster or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Cluster.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Cluster.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersGetCall) Do(opts ...googleapi.CallOption) (*Cluster, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11287,53 +8831,7 @@ func (c *ProjectsLocationsClustersGetCall) Do(opts ...googleapi.CallOption) (*Cl return nil, err } return ret, nil - // { - // "description": "Gets the details for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.get", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "clusterId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the cluster to retrieve. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster) of the cluster to retrieve. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "response": { - // "$ref": "Cluster" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.getJwks": +} type ProjectsLocationsClustersGetJwksCall struct { s *Service @@ -11344,11 +8842,11 @@ type ProjectsLocationsClustersGetJwksCall struct { header_ http.Header } -// GetJwks: Gets the public component of the cluster signing keys in -// JSON Web Key format. +// GetJwks: Gets the public component of the cluster signing keys in JSON Web +// Key format. // -// - parent: The cluster (project, location, cluster name) to get keys -// for. Specified in the format `projects/*/locations/*/clusters/*`. +// - parent: The cluster (project, location, cluster name) to get keys for. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) GetJwks(parent string) *ProjectsLocationsClustersGetJwksCall { c := &ProjectsLocationsClustersGetJwksCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -11356,33 +8854,29 @@ func (r *ProjectsLocationsClustersService) GetJwks(parent string) *ProjectsLocat } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersGetJwksCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersGetJwksCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersGetJwksCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersGetJwksCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersGetJwksCall) Context(ctx context.Context) *ProjectsLocationsClustersGetJwksCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersGetJwksCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11391,12 +8885,7 @@ func (c *ProjectsLocationsClustersGetJwksCall) Header() http.Header { } func (c *ProjectsLocationsClustersGetJwksCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -11417,12 +8906,11 @@ func (c *ProjectsLocationsClustersGetJwksCall) doRequest(alt string) (*http.Resp } // Do executes the "container.projects.locations.clusters.getJwks" call. -// Exactly one of *GetJSONWebKeysResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GetJSONWebKeysResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *GetJSONWebKeysResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsLocationsClustersGetJwksCall) Do(opts ...googleapi.CallOption) (*GetJSONWebKeysResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11453,32 +8941,7 @@ func (c *ProjectsLocationsClustersGetJwksCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Gets the public component of the cluster signing keys in JSON Web Key format.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/jwks", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.getJwks", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "The cluster (project, location, cluster name) to get keys for. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/jwks", - // "response": { - // "$ref": "GetJSONWebKeysResponse" - // } - // } - -} - -// method id "container.projects.locations.clusters.list": +} type ProjectsLocationsClustersListCall struct { s *Service @@ -11489,21 +8952,20 @@ type ProjectsLocationsClustersListCall struct { header_ http.Header } -// List: Lists all clusters owned by a project in either the specified -// zone or all zones. +// List: Lists all clusters owned by a project in either the specified zone or +// all zones. // -// - parent: The parent (project and location) where the clusters will -// be listed. Specified in the format `projects/*/locations/*`. -// Location "-" matches all zones and all regions. +// - parent: The parent (project and location) where the clusters will be +// listed. Specified in the format `projects/*/locations/*`. Location "-" +// matches all zones and all regions. func (r *ProjectsLocationsClustersService) List(parent string) *ProjectsLocationsClustersListCall { c := &ProjectsLocationsClustersListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. func (c *ProjectsLocationsClustersListCall) ProjectId(projectId string) *ProjectsLocationsClustersListCall { @@ -11511,44 +8973,40 @@ func (c *ProjectsLocationsClustersListCall) ProjectId(projectId string) *Project return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides, or "-" for all zones. This field has been deprecated -// and replaced by the parent field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides, or "-" for all zones. This field has been deprecated and replaced +// by the parent field. func (c *ProjectsLocationsClustersListCall) Zone(zone string) *ProjectsLocationsClustersListCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersListCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersListCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersListCall) Context(ctx context.Context) *ProjectsLocationsClustersListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11557,12 +9015,7 @@ func (c *ProjectsLocationsClustersListCall) Header() http.Header { } func (c *ProjectsLocationsClustersListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -11583,12 +9036,11 @@ func (c *ProjectsLocationsClustersListCall) doRequest(alt string) (*http.Respons } // Do executes the "container.projects.locations.clusters.list" call. -// Exactly one of *ListClustersResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListClustersResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListClustersResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsLocationsClustersListCall) Do(opts ...googleapi.CallOption) (*ListClustersResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11619,47 +9071,7 @@ func (c *ProjectsLocationsClustersListCall) Do(opts ...googleapi.CallOption) (*L return nil, err } return ret, nil - // { - // "description": "Lists all clusters owned by a project in either the specified zone or all zones.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.list", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "The parent (project and location) where the clusters will be listed. Specified in the format `projects/*/locations/*`. Location \"-\" matches all zones and all regions.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides, or \"-\" for all zones. This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/clusters", - // "response": { - // "$ref": "ListClustersResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setAddons": +} type ProjectsLocationsClustersSetAddonsCall struct { s *Service @@ -11672,9 +9084,8 @@ type ProjectsLocationsClustersSetAddonsCall struct { // SetAddons: Sets the addons for a specific cluster. // -// - name: The name (project, location, cluster) of the cluster to set -// addons. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to set addons. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetAddons(name string, setaddonsconfigrequest *SetAddonsConfigRequest) *ProjectsLocationsClustersSetAddonsCall { c := &ProjectsLocationsClustersSetAddonsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -11683,23 +9094,21 @@ func (r *ProjectsLocationsClustersService) SetAddons(name string, setaddonsconfi } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetAddonsCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetAddonsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetAddonsCall) Context(ctx context.Context) *ProjectsLocationsClustersSetAddonsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetAddonsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11708,18 +9117,12 @@ func (c *ProjectsLocationsClustersSetAddonsCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetAddonsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setaddonsconfigrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setAddons") @@ -11736,12 +9139,10 @@ func (c *ProjectsLocationsClustersSetAddonsCall) doRequest(alt string) (*http.Re } // Do executes the "container.projects.locations.clusters.setAddons" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetAddonsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11772,38 +9173,7 @@ func (c *ProjectsLocationsClustersSetAddonsCall) Do(opts ...googleapi.CallOption return nil, err } return ret, nil - // { - // "description": "Sets the addons for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setAddons", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setAddons", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to set addons. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setAddons", - // "request": { - // "$ref": "SetAddonsConfigRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setLegacyAbac": +} type ProjectsLocationsClustersSetLegacyAbacCall struct { s *Service @@ -11814,12 +9184,11 @@ type ProjectsLocationsClustersSetLegacyAbacCall struct { header_ http.Header } -// SetLegacyAbac: Enables or disables the ABAC authorization mechanism -// on a cluster. +// SetLegacyAbac: Enables or disables the ABAC authorization mechanism on a +// cluster. // -// - name: The name (project, location, cluster name) of the cluster to -// set legacy abac. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster name) of the cluster to set +// legacy abac. Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetLegacyAbac(name string, setlegacyabacrequest *SetLegacyAbacRequest) *ProjectsLocationsClustersSetLegacyAbacCall { c := &ProjectsLocationsClustersSetLegacyAbacCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -11828,23 +9197,21 @@ func (r *ProjectsLocationsClustersService) SetLegacyAbac(name string, setlegacya } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetLegacyAbacCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetLegacyAbacCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetLegacyAbacCall) Context(ctx context.Context) *ProjectsLocationsClustersSetLegacyAbacCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetLegacyAbacCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11853,18 +9220,12 @@ func (c *ProjectsLocationsClustersSetLegacyAbacCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetLegacyAbacCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setlegacyabacrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setLegacyAbac") @@ -11881,12 +9242,10 @@ func (c *ProjectsLocationsClustersSetLegacyAbacCall) doRequest(alt string) (*htt } // Do executes the "container.projects.locations.clusters.setLegacyAbac" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetLegacyAbacCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11917,38 +9276,7 @@ func (c *ProjectsLocationsClustersSetLegacyAbacCall) Do(opts ...googleapi.CallOp return nil, err } return ret, nil - // { - // "description": "Enables or disables the ABAC authorization mechanism on a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setLegacyAbac", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setLegacyAbac", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster name) of the cluster to set legacy abac. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setLegacyAbac", - // "request": { - // "$ref": "SetLegacyAbacRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setLocations": +} type ProjectsLocationsClustersSetLocationsCall struct { s *Service @@ -11959,14 +9287,13 @@ type ProjectsLocationsClustersSetLocationsCall struct { header_ http.Header } -// SetLocations: Sets the locations for a specific cluster. Deprecated. -// Use projects.locations.clusters.update +// SetLocations: Sets the locations for a specific cluster. Deprecated. Use +// projects.locations.clusters.update // (https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters/update) // instead. // // - name: The name (project, location, cluster) of the cluster to set -// locations. Specified in the format -// `projects/*/locations/*/clusters/*`. +// locations. Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetLocations(name string, setlocationsrequest *SetLocationsRequest) *ProjectsLocationsClustersSetLocationsCall { c := &ProjectsLocationsClustersSetLocationsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -11975,23 +9302,21 @@ func (r *ProjectsLocationsClustersService) SetLocations(name string, setlocation } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetLocationsCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetLocationsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetLocationsCall) Context(ctx context.Context) *ProjectsLocationsClustersSetLocationsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetLocationsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12000,18 +9325,12 @@ func (c *ProjectsLocationsClustersSetLocationsCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetLocationsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setlocationsrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setLocations") @@ -12028,12 +9347,10 @@ func (c *ProjectsLocationsClustersSetLocationsCall) doRequest(alt string) (*http } // Do executes the "container.projects.locations.clusters.setLocations" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetLocationsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12064,39 +9381,7 @@ func (c *ProjectsLocationsClustersSetLocationsCall) Do(opts ...googleapi.CallOpt return nil, err } return ret, nil - // { - // "deprecated": true, - // "description": "Sets the locations for a specific cluster. Deprecated. Use [projects.locations.clusters.update](https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters/update) instead.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setLocations", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setLocations", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to set locations. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setLocations", - // "request": { - // "$ref": "SetLocationsRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setLogging": +} type ProjectsLocationsClustersSetLoggingCall struct { s *Service @@ -12109,9 +9394,8 @@ type ProjectsLocationsClustersSetLoggingCall struct { // SetLogging: Sets the logging service for a specific cluster. // -// - name: The name (project, location, cluster) of the cluster to set -// logging. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to set logging. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetLogging(name string, setloggingservicerequest *SetLoggingServiceRequest) *ProjectsLocationsClustersSetLoggingCall { c := &ProjectsLocationsClustersSetLoggingCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -12120,23 +9404,21 @@ func (r *ProjectsLocationsClustersService) SetLogging(name string, setloggingser } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetLoggingCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetLoggingCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetLoggingCall) Context(ctx context.Context) *ProjectsLocationsClustersSetLoggingCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetLoggingCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12145,18 +9427,12 @@ func (c *ProjectsLocationsClustersSetLoggingCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetLoggingCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setloggingservicerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setLogging") @@ -12173,12 +9449,10 @@ func (c *ProjectsLocationsClustersSetLoggingCall) doRequest(alt string) (*http.R } // Do executes the "container.projects.locations.clusters.setLogging" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetLoggingCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12209,38 +9483,7 @@ func (c *ProjectsLocationsClustersSetLoggingCall) Do(opts ...googleapi.CallOptio return nil, err } return ret, nil - // { - // "description": "Sets the logging service for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setLogging", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setLogging", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to set logging. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setLogging", - // "request": { - // "$ref": "SetLoggingServiceRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setMaintenancePolicy": +} type ProjectsLocationsClustersSetMaintenancePolicyCall struct { s *Service @@ -12253,8 +9496,8 @@ type ProjectsLocationsClustersSetMaintenancePolicyCall struct { // SetMaintenancePolicy: Sets the maintenance policy for a cluster. // -// - name: The name (project, location, cluster name) of the cluster to -// set maintenance policy. Specified in the format +// - name: The name (project, location, cluster name) of the cluster to set +// maintenance policy. Specified in the format // `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetMaintenancePolicy(name string, setmaintenancepolicyrequest *SetMaintenancePolicyRequest) *ProjectsLocationsClustersSetMaintenancePolicyCall { c := &ProjectsLocationsClustersSetMaintenancePolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -12264,23 +9507,21 @@ func (r *ProjectsLocationsClustersService) SetMaintenancePolicy(name string, set } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetMaintenancePolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) Context(ctx context.Context) *ProjectsLocationsClustersSetMaintenancePolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12289,18 +9530,12 @@ func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) Header() http.Header } func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setmaintenancepolicyrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setMaintenancePolicy") @@ -12317,12 +9552,10 @@ func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) doRequest(alt string } // Do executes the "container.projects.locations.clusters.setMaintenancePolicy" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12353,38 +9586,7 @@ func (c *ProjectsLocationsClustersSetMaintenancePolicyCall) Do(opts ...googleapi return nil, err } return ret, nil - // { - // "description": "Sets the maintenance policy for a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setMaintenancePolicy", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setMaintenancePolicy", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster name) of the cluster to set maintenance policy. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setMaintenancePolicy", - // "request": { - // "$ref": "SetMaintenancePolicyRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setMasterAuth": +} type ProjectsLocationsClustersSetMasterAuthCall struct { s *Service @@ -12395,12 +9597,12 @@ type ProjectsLocationsClustersSetMasterAuthCall struct { header_ http.Header } -// SetMasterAuth: Sets master auth materials. Currently supports -// changing the admin password or a specific cluster, either via -// password generation or explicitly setting the password. +// SetMasterAuth: Sets master auth materials. Currently supports changing the +// admin password or a specific cluster, either via password generation or +// explicitly setting the password. // -// - name: The name (project, location, cluster) of the cluster to set -// auth. Specified in the format `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to set auth. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetMasterAuth(name string, setmasterauthrequest *SetMasterAuthRequest) *ProjectsLocationsClustersSetMasterAuthCall { c := &ProjectsLocationsClustersSetMasterAuthCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -12409,23 +9611,21 @@ func (r *ProjectsLocationsClustersService) SetMasterAuth(name string, setmastera } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetMasterAuthCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetMasterAuthCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetMasterAuthCall) Context(ctx context.Context) *ProjectsLocationsClustersSetMasterAuthCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetMasterAuthCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12434,18 +9634,12 @@ func (c *ProjectsLocationsClustersSetMasterAuthCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetMasterAuthCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setmasterauthrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setMasterAuth") @@ -12462,12 +9656,10 @@ func (c *ProjectsLocationsClustersSetMasterAuthCall) doRequest(alt string) (*htt } // Do executes the "container.projects.locations.clusters.setMasterAuth" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetMasterAuthCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12498,38 +9690,7 @@ func (c *ProjectsLocationsClustersSetMasterAuthCall) Do(opts ...googleapi.CallOp return nil, err } return ret, nil - // { - // "description": "Sets master auth materials. Currently supports changing the admin password or a specific cluster, either via password generation or explicitly setting the password.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setMasterAuth", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setMasterAuth", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to set auth. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setMasterAuth", - // "request": { - // "$ref": "SetMasterAuthRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setMonitoring": +} type ProjectsLocationsClustersSetMonitoringCall struct { s *Service @@ -12543,8 +9704,7 @@ type ProjectsLocationsClustersSetMonitoringCall struct { // SetMonitoring: Sets the monitoring service for a specific cluster. // // - name: The name (project, location, cluster) of the cluster to set -// monitoring. Specified in the format -// `projects/*/locations/*/clusters/*`. +// monitoring. Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetMonitoring(name string, setmonitoringservicerequest *SetMonitoringServiceRequest) *ProjectsLocationsClustersSetMonitoringCall { c := &ProjectsLocationsClustersSetMonitoringCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -12553,23 +9713,21 @@ func (r *ProjectsLocationsClustersService) SetMonitoring(name string, setmonitor } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetMonitoringCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetMonitoringCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetMonitoringCall) Context(ctx context.Context) *ProjectsLocationsClustersSetMonitoringCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetMonitoringCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12578,18 +9736,12 @@ func (c *ProjectsLocationsClustersSetMonitoringCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetMonitoringCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setmonitoringservicerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setMonitoring") @@ -12606,12 +9758,10 @@ func (c *ProjectsLocationsClustersSetMonitoringCall) doRequest(alt string) (*htt } // Do executes the "container.projects.locations.clusters.setMonitoring" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetMonitoringCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12642,38 +9792,7 @@ func (c *ProjectsLocationsClustersSetMonitoringCall) Do(opts ...googleapi.CallOp return nil, err } return ret, nil - // { - // "description": "Sets the monitoring service for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setMonitoring", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setMonitoring", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to set monitoring. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setMonitoring", - // "request": { - // "$ref": "SetMonitoringServiceRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setNetworkPolicy": +} type ProjectsLocationsClustersSetNetworkPolicyCall struct { s *Service @@ -12686,8 +9805,8 @@ type ProjectsLocationsClustersSetNetworkPolicyCall struct { // SetNetworkPolicy: Enables or disables Network Policy for a cluster. // -// - name: The name (project, location, cluster name) of the cluster to -// set networking policy. Specified in the format +// - name: The name (project, location, cluster name) of the cluster to set +// networking policy. Specified in the format // `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetNetworkPolicy(name string, setnetworkpolicyrequest *SetNetworkPolicyRequest) *ProjectsLocationsClustersSetNetworkPolicyCall { c := &ProjectsLocationsClustersSetNetworkPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -12697,23 +9816,21 @@ func (r *ProjectsLocationsClustersService) SetNetworkPolicy(name string, setnetw } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetNetworkPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetNetworkPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetNetworkPolicyCall) Context(ctx context.Context) *ProjectsLocationsClustersSetNetworkPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetNetworkPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12722,18 +9839,12 @@ func (c *ProjectsLocationsClustersSetNetworkPolicyCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetNetworkPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnetworkpolicyrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setNetworkPolicy") @@ -12750,12 +9861,10 @@ func (c *ProjectsLocationsClustersSetNetworkPolicyCall) doRequest(alt string) (* } // Do executes the "container.projects.locations.clusters.setNetworkPolicy" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetNetworkPolicyCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12786,38 +9895,7 @@ func (c *ProjectsLocationsClustersSetNetworkPolicyCall) Do(opts ...googleapi.Cal return nil, err } return ret, nil - // { - // "description": "Enables or disables Network Policy for a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setNetworkPolicy", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setNetworkPolicy", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster name) of the cluster to set networking policy. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setNetworkPolicy", - // "request": { - // "$ref": "SetNetworkPolicyRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.setResourceLabels": +} type ProjectsLocationsClustersSetResourceLabelsCall struct { s *Service @@ -12830,9 +9908,8 @@ type ProjectsLocationsClustersSetResourceLabelsCall struct { // SetResourceLabels: Sets labels on a cluster. // -// - name: The name (project, location, cluster name) of the cluster to -// set labels. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster name) of the cluster to set +// labels. Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) SetResourceLabels(name string, setlabelsrequest *SetLabelsRequest) *ProjectsLocationsClustersSetResourceLabelsCall { c := &ProjectsLocationsClustersSetResourceLabelsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -12841,23 +9918,21 @@ func (r *ProjectsLocationsClustersService) SetResourceLabels(name string, setlab } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersSetResourceLabelsCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersSetResourceLabelsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersSetResourceLabelsCall) Context(ctx context.Context) *ProjectsLocationsClustersSetResourceLabelsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersSetResourceLabelsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12866,18 +9941,12 @@ func (c *ProjectsLocationsClustersSetResourceLabelsCall) Header() http.Header { } func (c *ProjectsLocationsClustersSetResourceLabelsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setlabelsrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setResourceLabels") @@ -12894,12 +9963,10 @@ func (c *ProjectsLocationsClustersSetResourceLabelsCall) doRequest(alt string) ( } // Do executes the "container.projects.locations.clusters.setResourceLabels" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersSetResourceLabelsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12930,38 +9997,7 @@ func (c *ProjectsLocationsClustersSetResourceLabelsCall) Do(opts ...googleapi.Ca return nil, err } return ret, nil - // { - // "description": "Sets labels on a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:setResourceLabels", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.setResourceLabels", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster name) of the cluster to set labels. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setResourceLabels", - // "request": { - // "$ref": "SetLabelsRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.startIpRotation": +} type ProjectsLocationsClustersStartIpRotationCall struct { s *Service @@ -12974,9 +10010,8 @@ type ProjectsLocationsClustersStartIpRotationCall struct { // StartIpRotation: Starts master IP rotation. // -// - name: The name (project, location, cluster name) of the cluster to -// start IP rotation. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster name) of the cluster to start +// IP rotation. Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) StartIpRotation(name string, startiprotationrequest *StartIPRotationRequest) *ProjectsLocationsClustersStartIpRotationCall { c := &ProjectsLocationsClustersStartIpRotationCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -12985,23 +10020,21 @@ func (r *ProjectsLocationsClustersService) StartIpRotation(name string, startipr } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersStartIpRotationCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersStartIpRotationCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersStartIpRotationCall) Context(ctx context.Context) *ProjectsLocationsClustersStartIpRotationCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersStartIpRotationCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13010,18 +10043,12 @@ func (c *ProjectsLocationsClustersStartIpRotationCall) Header() http.Header { } func (c *ProjectsLocationsClustersStartIpRotationCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.startiprotationrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:startIpRotation") @@ -13038,12 +10065,10 @@ func (c *ProjectsLocationsClustersStartIpRotationCall) doRequest(alt string) (*h } // Do executes the "container.projects.locations.clusters.startIpRotation" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersStartIpRotationCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13074,38 +10099,7 @@ func (c *ProjectsLocationsClustersStartIpRotationCall) Do(opts ...googleapi.Call return nil, err } return ret, nil - // { - // "description": "Starts master IP rotation.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:startIpRotation", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.startIpRotation", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster name) of the cluster to start IP rotation. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:startIpRotation", - // "request": { - // "$ref": "StartIPRotationRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.update": +} type ProjectsLocationsClustersUpdateCall struct { s *Service @@ -13118,9 +10112,8 @@ type ProjectsLocationsClustersUpdateCall struct { // Update: Updates the settings for a specific cluster. // -// - name: The name (project, location, cluster) of the cluster to -// update. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to update. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) Update(name string, updateclusterrequest *UpdateClusterRequest) *ProjectsLocationsClustersUpdateCall { c := &ProjectsLocationsClustersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -13129,23 +10122,21 @@ func (r *ProjectsLocationsClustersService) Update(name string, updateclusterrequ } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersUpdateCall) Context(ctx context.Context) *ProjectsLocationsClustersUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13154,18 +10145,12 @@ func (c *ProjectsLocationsClustersUpdateCall) Header() http.Header { } func (c *ProjectsLocationsClustersUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.updateclusterrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") @@ -13182,12 +10167,10 @@ func (c *ProjectsLocationsClustersUpdateCall) doRequest(alt string) (*http.Respo } // Do executes the "container.projects.locations.clusters.update" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13218,38 +10201,7 @@ func (c *ProjectsLocationsClustersUpdateCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Updates the settings for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}", - // "httpMethod": "PUT", - // "id": "container.projects.locations.clusters.update", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to update. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "request": { - // "$ref": "UpdateClusterRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.updateMaster": +} type ProjectsLocationsClustersUpdateMasterCall struct { s *Service @@ -13262,9 +10214,8 @@ type ProjectsLocationsClustersUpdateMasterCall struct { // UpdateMaster: Updates the master for a specific cluster. // -// - name: The name (project, location, cluster) of the cluster to -// update. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - name: The name (project, location, cluster) of the cluster to update. +// Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersService) UpdateMaster(name string, updatemasterrequest *UpdateMasterRequest) *ProjectsLocationsClustersUpdateMasterCall { c := &ProjectsLocationsClustersUpdateMasterCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -13273,23 +10224,21 @@ func (r *ProjectsLocationsClustersService) UpdateMaster(name string, updatemaste } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersUpdateMasterCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersUpdateMasterCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersUpdateMasterCall) Context(ctx context.Context) *ProjectsLocationsClustersUpdateMasterCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersUpdateMasterCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13298,18 +10247,12 @@ func (c *ProjectsLocationsClustersUpdateMasterCall) Header() http.Header { } func (c *ProjectsLocationsClustersUpdateMasterCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.updatemasterrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:updateMaster") @@ -13326,12 +10269,10 @@ func (c *ProjectsLocationsClustersUpdateMasterCall) doRequest(alt string) (*http } // Do executes the "container.projects.locations.clusters.updateMaster" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersUpdateMasterCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13362,38 +10303,7 @@ func (c *ProjectsLocationsClustersUpdateMasterCall) Do(opts ...googleapi.CallOpt return nil, err } return ret, nil - // { - // "description": "Updates the master for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:updateMaster", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.updateMaster", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster) of the cluster to update. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:updateMaster", - // "request": { - // "$ref": "UpdateMasterRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.completeUpgrade": +} type ProjectsLocationsClustersNodePoolsCompleteUpgradeCall struct { s *Service @@ -13404,11 +10314,11 @@ type ProjectsLocationsClustersNodePoolsCompleteUpgradeCall struct { header_ http.Header } -// CompleteUpgrade: CompleteNodePoolUpgrade will signal an on-going node -// pool upgrade to complete. +// CompleteUpgrade: CompleteNodePoolUpgrade will signal an on-going node pool +// upgrade to complete. // -// - name: The name (project, location, cluster, node pool id) of the -// node pool to complete upgrade. Specified in the format +// - name: The name (project, location, cluster, node pool id) of the node pool +// to complete upgrade. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) CompleteUpgrade(name string, completenodepoolupgraderequest *CompleteNodePoolUpgradeRequest) *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall { c := &ProjectsLocationsClustersNodePoolsCompleteUpgradeCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13418,23 +10328,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) CompleteUpgrade(name string, } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13443,18 +10351,12 @@ func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) Header() http.He } func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.completenodepoolupgraderequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:completeUpgrade") @@ -13471,12 +10373,10 @@ func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) doRequest(alt st } // Do executes the "container.projects.locations.clusters.nodePools.completeUpgrade" call. -// Exactly one of *Empty or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Empty.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) Do(opts ...googleapi.CallOption) (*Empty, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13507,38 +10407,7 @@ func (c *ProjectsLocationsClustersNodePoolsCompleteUpgradeCall) Do(opts ...googl return nil, err } return ret, nil - // { - // "description": "CompleteNodePoolUpgrade will signal an on-going node pool upgrade to complete.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}:completeUpgrade", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.nodePools.completeUpgrade", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to complete upgrade. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:completeUpgrade", - // "request": { - // "$ref": "CompleteNodePoolUpgradeRequest" - // }, - // "response": { - // "$ref": "Empty" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.create": +} type ProjectsLocationsClustersNodePoolsCreateCall struct { s *Service @@ -13551,8 +10420,8 @@ type ProjectsLocationsClustersNodePoolsCreateCall struct { // Create: Creates a node pool for a cluster. // -// - parent: The parent (project, location, cluster name) where the node -// pool will be created. Specified in the format +// - parent: The parent (project, location, cluster name) where the node pool +// will be created. Specified in the format // `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersNodePoolsService) Create(parent string, createnodepoolrequest *CreateNodePoolRequest) *ProjectsLocationsClustersNodePoolsCreateCall { c := &ProjectsLocationsClustersNodePoolsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13562,23 +10431,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) Create(parent string, create } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsCreateCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsCreateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13587,18 +10454,12 @@ func (c *ProjectsLocationsClustersNodePoolsCreateCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.createnodepoolrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/nodePools") @@ -13615,12 +10476,10 @@ func (c *ProjectsLocationsClustersNodePoolsCreateCall) doRequest(alt string) (*h } // Do executes the "container.projects.locations.clusters.nodePools.create" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13651,38 +10510,7 @@ func (c *ProjectsLocationsClustersNodePoolsCreateCall) Do(opts ...googleapi.Call return nil, err } return ret, nil - // { - // "description": "Creates a node pool for a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.nodePools.create", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "The parent (project, location, cluster name) where the node pool will be created. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/nodePools", - // "request": { - // "$ref": "CreateNodePoolRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.delete": +} type ProjectsLocationsClustersNodePoolsDeleteCall struct { s *Service @@ -13694,8 +10522,8 @@ type ProjectsLocationsClustersNodePoolsDeleteCall struct { // Delete: Deletes a node pool from a cluster. // -// - name: The name (project, location, cluster, node pool id) of the -// node pool to delete. Specified in the format +// - name: The name (project, location, cluster, node pool id) of the node pool +// to delete. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) Delete(name string) *ProjectsLocationsClustersNodePoolsDeleteCall { c := &ProjectsLocationsClustersNodePoolsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13703,25 +10531,24 @@ func (r *ProjectsLocationsClustersNodePoolsService) Delete(name string) *Project return c } -// ClusterId sets the optional parameter "clusterId": Required. -// Deprecated. The name of the cluster. This field has been deprecated -// and replaced by the name field. +// ClusterId sets the optional parameter "clusterId": Required. Deprecated. The +// name of the cluster. This field has been deprecated and replaced by the name +// field. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) ClusterId(clusterId string) *ProjectsLocationsClustersNodePoolsDeleteCall { c.urlParams_.Set("clusterId", clusterId) return c } -// NodePoolId sets the optional parameter "nodePoolId": Required. -// Deprecated. The name of the node pool to delete. This field has been -// deprecated and replaced by the name field. +// NodePoolId sets the optional parameter "nodePoolId": Required. Deprecated. +// The name of the node pool to delete. This field has been deprecated and +// replaced by the name field. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) NodePoolId(nodePoolId string) *ProjectsLocationsClustersNodePoolsDeleteCall { c.urlParams_.Set("nodePoolId", nodePoolId) return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) ProjectId(projectId string) *ProjectsLocationsClustersNodePoolsDeleteCall { @@ -13729,34 +10556,31 @@ func (c *ProjectsLocationsClustersNodePoolsDeleteCall) ProjectId(projectId strin return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides. This field has been deprecated and replaced by the -// name field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides. This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Zone(zone string) *ProjectsLocationsClustersNodePoolsDeleteCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13765,12 +10589,7 @@ func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -13788,12 +10607,10 @@ func (c *ProjectsLocationsClustersNodePoolsDeleteCall) doRequest(alt string) (*h } // Do executes the "container.projects.locations.clusters.nodePools.delete" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13824,59 +10641,7 @@ func (c *ProjectsLocationsClustersNodePoolsDeleteCall) Do(opts ...googleapi.Call return nil, err } return ret, nil - // { - // "description": "Deletes a node pool from a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}", - // "httpMethod": "DELETE", - // "id": "container.projects.locations.clusters.nodePools.delete", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "clusterId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to delete. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the node pool to delete. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.get": +} type ProjectsLocationsClustersNodePoolsGetCall struct { s *Service @@ -13889,8 +10654,8 @@ type ProjectsLocationsClustersNodePoolsGetCall struct { // Get: Retrieves the requested node pool. // -// - name: The name (project, location, cluster, node pool id) of the -// node pool to get. Specified in the format +// - name: The name (project, location, cluster, node pool id) of the node pool +// to get. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) Get(name string) *ProjectsLocationsClustersNodePoolsGetCall { c := &ProjectsLocationsClustersNodePoolsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13898,25 +10663,24 @@ func (r *ProjectsLocationsClustersNodePoolsService) Get(name string) *ProjectsLo return c } -// ClusterId sets the optional parameter "clusterId": Required. -// Deprecated. The name of the cluster. This field has been deprecated -// and replaced by the name field. +// ClusterId sets the optional parameter "clusterId": Required. Deprecated. The +// name of the cluster. This field has been deprecated and replaced by the name +// field. func (c *ProjectsLocationsClustersNodePoolsGetCall) ClusterId(clusterId string) *ProjectsLocationsClustersNodePoolsGetCall { c.urlParams_.Set("clusterId", clusterId) return c } -// NodePoolId sets the optional parameter "nodePoolId": Required. -// Deprecated. The name of the node pool. This field has been deprecated -// and replaced by the name field. +// NodePoolId sets the optional parameter "nodePoolId": Required. Deprecated. +// The name of the node pool. This field has been deprecated and replaced by +// the name field. func (c *ProjectsLocationsClustersNodePoolsGetCall) NodePoolId(nodePoolId string) *ProjectsLocationsClustersNodePoolsGetCall { c.urlParams_.Set("nodePoolId", nodePoolId) return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersNodePoolsGetCall) ProjectId(projectId string) *ProjectsLocationsClustersNodePoolsGetCall { @@ -13924,44 +10688,39 @@ func (c *ProjectsLocationsClustersNodePoolsGetCall) ProjectId(projectId string) return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides. This field has been deprecated and replaced by the -// name field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides. This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsClustersNodePoolsGetCall) Zone(zone string) *ProjectsLocationsClustersNodePoolsGetCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersNodePoolsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersNodePoolsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsGetCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13970,12 +10729,7 @@ func (c *ProjectsLocationsClustersNodePoolsGetCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -13996,12 +10750,10 @@ func (c *ProjectsLocationsClustersNodePoolsGetCall) doRequest(alt string) (*http } // Do executes the "container.projects.locations.clusters.nodePools.get" call. -// Exactly one of *NodePool or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *NodePool.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *NodePool.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsGetCall) Do(opts ...googleapi.CallOption) (*NodePool, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14032,59 +10784,7 @@ func (c *ProjectsLocationsClustersNodePoolsGetCall) Do(opts ...googleapi.CallOpt return nil, err } return ret, nil - // { - // "description": "Retrieves the requested node pool.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.nodePools.get", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "clusterId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to get. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the node pool. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "response": { - // "$ref": "NodePool" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.list": +} type ProjectsLocationsClustersNodePoolsListCall struct { s *Service @@ -14097,8 +10797,8 @@ type ProjectsLocationsClustersNodePoolsListCall struct { // List: Lists the node pools for a cluster. // -// - parent: The parent (project, location, cluster name) where the node -// pools will be listed. Specified in the format +// - parent: The parent (project, location, cluster name) where the node pools +// will be listed. Specified in the format // `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersNodePoolsService) List(parent string) *ProjectsLocationsClustersNodePoolsListCall { c := &ProjectsLocationsClustersNodePoolsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14106,17 +10806,16 @@ func (r *ProjectsLocationsClustersNodePoolsService) List(parent string) *Project return c } -// ClusterId sets the optional parameter "clusterId": Required. -// Deprecated. The name of the cluster. This field has been deprecated -// and replaced by the parent field. +// ClusterId sets the optional parameter "clusterId": Required. Deprecated. The +// name of the cluster. This field has been deprecated and replaced by the +// parent field. func (c *ProjectsLocationsClustersNodePoolsListCall) ClusterId(clusterId string) *ProjectsLocationsClustersNodePoolsListCall { c.urlParams_.Set("clusterId", clusterId) return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. func (c *ProjectsLocationsClustersNodePoolsListCall) ProjectId(projectId string) *ProjectsLocationsClustersNodePoolsListCall { @@ -14124,44 +10823,39 @@ func (c *ProjectsLocationsClustersNodePoolsListCall) ProjectId(projectId string) return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides. This field has been deprecated and replaced by the -// parent field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides. This field has been deprecated and replaced by the parent field. func (c *ProjectsLocationsClustersNodePoolsListCall) Zone(zone string) *ProjectsLocationsClustersNodePoolsListCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersNodePoolsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersNodePoolsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsListCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14170,12 +10864,7 @@ func (c *ProjectsLocationsClustersNodePoolsListCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -14196,12 +10885,11 @@ func (c *ProjectsLocationsClustersNodePoolsListCall) doRequest(alt string) (*htt } // Do executes the "container.projects.locations.clusters.nodePools.list" call. -// Exactly one of *ListNodePoolsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListNodePoolsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListNodePoolsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsLocationsClustersNodePoolsListCall) Do(opts ...googleapi.CallOption) (*ListNodePoolsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14232,53 +10920,7 @@ func (c *ProjectsLocationsClustersNodePoolsListCall) Do(opts ...googleapi.CallOp return nil, err } return ret, nil - // { - // "description": "Lists the node pools for a cluster.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.nodePools.list", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "clusterId": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "The parent (project, location, cluster name) where the node pools will be listed. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/nodePools", - // "response": { - // "$ref": "ListNodePoolsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.rollback": +} type ProjectsLocationsClustersNodePoolsRollbackCall struct { s *Service @@ -14289,11 +10931,11 @@ type ProjectsLocationsClustersNodePoolsRollbackCall struct { header_ http.Header } -// Rollback: Rolls back a previously Aborted or Failed NodePool upgrade. -// This makes no changes if the last upgrade successfully completed. +// Rollback: Rolls back a previously Aborted or Failed NodePool upgrade. This +// makes no changes if the last upgrade successfully completed. // -// - name: The name (project, location, cluster, node pool id) of the -// node poll to rollback upgrade. Specified in the format +// - name: The name (project, location, cluster, node pool id) of the node poll +// to rollback upgrade. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) Rollback(name string, rollbacknodepoolupgraderequest *RollbackNodePoolUpgradeRequest) *ProjectsLocationsClustersNodePoolsRollbackCall { c := &ProjectsLocationsClustersNodePoolsRollbackCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14303,23 +10945,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) Rollback(name string, rollba } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsRollbackCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsRollbackCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsRollbackCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsRollbackCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsRollbackCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14328,18 +10968,12 @@ func (c *ProjectsLocationsClustersNodePoolsRollbackCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsRollbackCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.rollbacknodepoolupgraderequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:rollback") @@ -14356,12 +10990,10 @@ func (c *ProjectsLocationsClustersNodePoolsRollbackCall) doRequest(alt string) ( } // Do executes the "container.projects.locations.clusters.nodePools.rollback" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsRollbackCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14392,38 +11024,7 @@ func (c *ProjectsLocationsClustersNodePoolsRollbackCall) Do(opts ...googleapi.Ca return nil, err } return ret, nil - // { - // "description": "Rolls back a previously Aborted or Failed NodePool upgrade. This makes no changes if the last upgrade successfully completed.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}:rollback", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.nodePools.rollback", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node poll to rollback upgrade. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:rollback", - // "request": { - // "$ref": "RollbackNodePoolUpgradeRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.setAutoscaling": +} type ProjectsLocationsClustersNodePoolsSetAutoscalingCall struct { s *Service @@ -14434,11 +11035,10 @@ type ProjectsLocationsClustersNodePoolsSetAutoscalingCall struct { header_ http.Header } -// SetAutoscaling: Sets the autoscaling settings of a specific node -// pool. +// SetAutoscaling: Sets the autoscaling settings of a specific node pool. // -// - name: The name (project, location, cluster, node pool) of the node -// pool to set autoscaler settings. Specified in the format +// - name: The name (project, location, cluster, node pool) of the node pool to +// set autoscaler settings. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) SetAutoscaling(name string, setnodepoolautoscalingrequest *SetNodePoolAutoscalingRequest) *ProjectsLocationsClustersNodePoolsSetAutoscalingCall { c := &ProjectsLocationsClustersNodePoolsSetAutoscalingCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14448,23 +11048,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) SetAutoscaling(name string, } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsSetAutoscalingCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsSetAutoscalingCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14473,18 +11071,12 @@ func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) Header() http.Hea } func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnodepoolautoscalingrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setAutoscaling") @@ -14501,12 +11093,10 @@ func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) doRequest(alt str } // Do executes the "container.projects.locations.clusters.nodePools.setAutoscaling" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14537,38 +11127,7 @@ func (c *ProjectsLocationsClustersNodePoolsSetAutoscalingCall) Do(opts ...google return nil, err } return ret, nil - // { - // "description": "Sets the autoscaling settings of a specific node pool.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}:setAutoscaling", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.nodePools.setAutoscaling", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster, node pool) of the node pool to set autoscaler settings. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setAutoscaling", - // "request": { - // "$ref": "SetNodePoolAutoscalingRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.setManagement": +} type ProjectsLocationsClustersNodePoolsSetManagementCall struct { s *Service @@ -14581,8 +11140,8 @@ type ProjectsLocationsClustersNodePoolsSetManagementCall struct { // SetManagement: Sets the NodeManagement options for a node pool. // -// - name: The name (project, location, cluster, node pool id) of the -// node pool to set management properties. Specified in the format +// - name: The name (project, location, cluster, node pool id) of the node pool +// to set management properties. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) SetManagement(name string, setnodepoolmanagementrequest *SetNodePoolManagementRequest) *ProjectsLocationsClustersNodePoolsSetManagementCall { c := &ProjectsLocationsClustersNodePoolsSetManagementCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14592,23 +11151,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) SetManagement(name string, s } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsSetManagementCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsSetManagementCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14617,18 +11174,12 @@ func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) Header() http.Head } func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnodepoolmanagementrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setManagement") @@ -14645,12 +11196,10 @@ func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) doRequest(alt stri } // Do executes the "container.projects.locations.clusters.nodePools.setManagement" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14681,38 +11230,7 @@ func (c *ProjectsLocationsClustersNodePoolsSetManagementCall) Do(opts ...googlea return nil, err } return ret, nil - // { - // "description": "Sets the NodeManagement options for a node pool.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}:setManagement", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.nodePools.setManagement", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to set management properties. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setManagement", - // "request": { - // "$ref": "SetNodePoolManagementRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.setSize": +} type ProjectsLocationsClustersNodePoolsSetSizeCall struct { s *Service @@ -14723,12 +11241,12 @@ type ProjectsLocationsClustersNodePoolsSetSizeCall struct { header_ http.Header } -// SetSize: SetNodePoolSizeRequest sets the size of a node pool. The new -// size will be used for all replicas, including future replicas created -// by modifying NodePool.locations. +// SetSize: SetNodePoolSizeRequest sets the size of a node pool. The new size +// will be used for all replicas, including future replicas created by +// modifying NodePool.locations. // -// - name: The name (project, location, cluster, node pool id) of the -// node pool to set size. Specified in the format +// - name: The name (project, location, cluster, node pool id) of the node pool +// to set size. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) SetSize(name string, setnodepoolsizerequest *SetNodePoolSizeRequest) *ProjectsLocationsClustersNodePoolsSetSizeCall { c := &ProjectsLocationsClustersNodePoolsSetSizeCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14738,23 +11256,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) SetSize(name string, setnode } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsSetSizeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsSetSizeCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14763,18 +11279,12 @@ func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnodepoolsizerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setSize") @@ -14791,12 +11301,10 @@ func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) doRequest(alt string) (* } // Do executes the "container.projects.locations.clusters.nodePools.setSize" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14827,38 +11335,7 @@ func (c *ProjectsLocationsClustersNodePoolsSetSizeCall) Do(opts ...googleapi.Cal return nil, err } return ret, nil - // { - // "description": "SetNodePoolSizeRequest sets the size of a node pool. The new size will be used for all replicas, including future replicas created by modifying NodePool.locations.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}:setSize", - // "httpMethod": "POST", - // "id": "container.projects.locations.clusters.nodePools.setSize", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to set size. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:setSize", - // "request": { - // "$ref": "SetNodePoolSizeRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.nodePools.update": +} type ProjectsLocationsClustersNodePoolsUpdateCall struct { s *Service @@ -14869,11 +11346,10 @@ type ProjectsLocationsClustersNodePoolsUpdateCall struct { header_ http.Header } -// Update: Updates the version and/or image type of a specific node -// pool. +// Update: Updates the version and/or image type of a specific node pool. // -// - name: The name (project, location, cluster, node pool) of the node -// pool to update. Specified in the format +// - name: The name (project, location, cluster, node pool) of the node pool to +// update. Specified in the format // `projects/*/locations/*/clusters/*/nodePools/*`. func (r *ProjectsLocationsClustersNodePoolsService) Update(name string, updatenodepoolrequest *UpdateNodePoolRequest) *ProjectsLocationsClustersNodePoolsUpdateCall { c := &ProjectsLocationsClustersNodePoolsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14883,23 +11359,21 @@ func (r *ProjectsLocationsClustersNodePoolsService) Update(name string, updateno } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersNodePoolsUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersNodePoolsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersNodePoolsUpdateCall) Context(ctx context.Context) *ProjectsLocationsClustersNodePoolsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersNodePoolsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14908,18 +11382,12 @@ func (c *ProjectsLocationsClustersNodePoolsUpdateCall) Header() http.Header { } func (c *ProjectsLocationsClustersNodePoolsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.updatenodepoolrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") @@ -14936,12 +11404,10 @@ func (c *ProjectsLocationsClustersNodePoolsUpdateCall) doRequest(alt string) (*h } // Do executes the "container.projects.locations.clusters.nodePools.update" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsClustersNodePoolsUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14972,38 +11438,7 @@ func (c *ProjectsLocationsClustersNodePoolsUpdateCall) Do(opts ...googleapi.Call return nil, err } return ret, nil - // { - // "description": "Updates the version and/or image type of a specific node pool.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/nodePools/{nodePoolsId}", - // "httpMethod": "PUT", - // "id": "container.projects.locations.clusters.nodePools.update", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, cluster, node pool) of the node pool to update. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+/nodePools/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "request": { - // "$ref": "UpdateNodePoolRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.clusters.well-known.getOpenid-configuration": +} type ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall struct { s *Service @@ -15014,14 +11449,12 @@ type ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall struct { header_ http.Header } -// GetOpenidConfiguration: Gets the OIDC discovery document for the -// cluster. See the OpenID Connect Discovery 1.0 specification -// (https://openid.net/specs/openid-connect-discovery-1_0.html) for -// details. +// GetOpenidConfiguration: Gets the OIDC discovery document for the cluster. +// See the OpenID Connect Discovery 1.0 specification +// (https://openid.net/specs/openid-connect-discovery-1_0.html) for details. // -// - parent: The cluster (project, location, cluster name) to get the -// discovery document for. Specified in the format -// `projects/*/locations/*/clusters/*`. +// - parent: The cluster (project, location, cluster name) to get the discovery +// document for. Specified in the format `projects/*/locations/*/clusters/*`. func (r *ProjectsLocationsClustersWellKnownService) GetOpenidConfiguration(parent string) *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall { c := &ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -15029,33 +11462,29 @@ func (r *ProjectsLocationsClustersWellKnownService) GetOpenidConfiguration(paren } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) IfNoneMatch(entityTag string) *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) Context(ctx context.Context) *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15064,12 +11493,7 @@ func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) Header() } func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -15090,12 +11514,11 @@ func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) doRequest } // Do executes the "container.projects.locations.clusters.well-known.getOpenid-configuration" call. -// Exactly one of *GetOpenIDConfigResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either +// Any non-2xx status code is an error. Response headers are in either // *GetOpenIDConfigResponse.ServerResponse.Header or (if a response was // returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) Do(opts ...googleapi.CallOption) (*GetOpenIDConfigResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15126,32 +11549,7 @@ func (c *ProjectsLocationsClustersWellKnownGetOpenidConfigurationCall) Do(opts . return nil, err } return ret, nil - // { - // "description": "Gets the OIDC discovery document for the cluster. See the [OpenID Connect Discovery 1.0 specification](https://openid.net/specs/openid-connect-discovery-1_0.html) for details.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}/.well-known/openid-configuration", - // "httpMethod": "GET", - // "id": "container.projects.locations.clusters.well-known.getOpenid-configuration", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "The cluster (project, location, cluster name) to get the discovery document for. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/.well-known/openid-configuration", - // "response": { - // "$ref": "GetOpenIDConfigResponse" - // } - // } - -} - -// method id "container.projects.locations.operations.cancel": +} type ProjectsLocationsOperationsCancelCall struct { s *Service @@ -15164,9 +11562,8 @@ type ProjectsLocationsOperationsCancelCall struct { // Cancel: Cancels the specified operation. // -// - name: The name (project, location, operation id) of the operation -// to cancel. Specified in the format -// `projects/*/locations/*/operations/*`. +// - name: The name (project, location, operation id) of the operation to +// cancel. Specified in the format `projects/*/locations/*/operations/*`. func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall { c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -15175,23 +11572,21 @@ func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperation } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15200,18 +11595,12 @@ func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header { } func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:cancel") @@ -15228,12 +11617,10 @@ func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Res } // Do executes the "container.projects.locations.operations.cancel" call. -// Exactly one of *Empty or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Empty.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15264,38 +11651,7 @@ func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Cancels the specified operation.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", - // "httpMethod": "POST", - // "id": "container.projects.locations.operations.cancel", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, operation id) of the operation to cancel. Specified in the format `projects/*/locations/*/operations/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}:cancel", - // "request": { - // "$ref": "CancelOperationRequest" - // }, - // "response": { - // "$ref": "Empty" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.operations.get": +} type ProjectsLocationsOperationsGetCall struct { s *Service @@ -15308,26 +11664,24 @@ type ProjectsLocationsOperationsGetCall struct { // Get: Gets the specified operation. // -// - name: The name (project, location, operation id) of the operation -// to get. Specified in the format -// `projects/*/locations/*/operations/*`. +// - name: The name (project, location, operation id) of the operation to get. +// Specified in the format `projects/*/locations/*/operations/*`. func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall { c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// OperationId sets the optional parameter "operationId": Required. -// Deprecated. The server-assigned `name` of the operation. This field -// has been deprecated and replaced by the name field. +// OperationId sets the optional parameter "operationId": Required. Deprecated. +// The server-assigned `name` of the operation. This field has been deprecated +// and replaced by the name field. func (c *ProjectsLocationsOperationsGetCall) OperationId(operationId string) *ProjectsLocationsOperationsGetCall { c.urlParams_.Set("operationId", operationId) return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsOperationsGetCall) ProjectId(projectId string) *ProjectsLocationsOperationsGetCall { @@ -15335,44 +11689,39 @@ func (c *ProjectsLocationsOperationsGetCall) ProjectId(projectId string) *Projec return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which the -// cluster resides. This field has been deprecated and replaced by the -// name field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) in which the cluster +// resides. This field has been deprecated and replaced by the name field. func (c *ProjectsLocationsOperationsGetCall) Zone(zone string) *ProjectsLocationsOperationsGetCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15381,12 +11730,7 @@ func (c *ProjectsLocationsOperationsGetCall) Header() http.Header { } func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -15407,12 +11751,10 @@ func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Respon } // Do executes the "container.projects.locations.operations.get" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15443,53 +11785,7 @@ func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (* return nil, err } return ret, nil - // { - // "description": "Gets the specified operation.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "container.projects.locations.operations.get", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, operation id) of the operation to get. Specified in the format `projects/*/locations/*/operations/*`.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "operationId": { - // "deprecated": true, - // "description": "Required. Deprecated. The server-assigned `name` of the operation. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+name}", - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.locations.operations.list": +} type ProjectsLocationsOperationsListCall struct { s *Service @@ -15500,21 +11796,19 @@ type ProjectsLocationsOperationsListCall struct { header_ http.Header } -// List: Lists all operations in a project in the specified zone or all -// zones. +// List: Lists all operations in a project in the specified zone or all zones. // -// - parent: The parent (project and location) where the operations will -// be listed. Specified in the format `projects/*/locations/*`. -// Location "-" matches all zones and all regions. +// - parent: The parent (project and location) where the operations will be +// listed. Specified in the format `projects/*/locations/*`. Location "-" +// matches all zones and all regions. func (r *ProjectsLocationsOperationsService) List(parent string) *ProjectsLocationsOperationsListCall { c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent return c } -// ProjectId sets the optional parameter "projectId": Required. -// Deprecated. The Google Developers Console project ID or project -// number +// ProjectId sets the optional parameter "projectId": Required. Deprecated. The +// Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. func (c *ProjectsLocationsOperationsListCall) ProjectId(projectId string) *ProjectsLocationsOperationsListCall { @@ -15522,44 +11816,40 @@ func (c *ProjectsLocationsOperationsListCall) ProjectId(projectId string) *Proje return c } -// Zone sets the optional parameter "zone": Required. Deprecated. The -// name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) to return -// operations for, or `-` for all zones. This field has been deprecated -// and replaced by the parent field. +// Zone sets the optional parameter "zone": Required. Deprecated. The name of +// the Google Compute Engine zone +// (https://cloud.google.com/compute/docs/zones#available) to return operations +// for, or `-` for all zones. This field has been deprecated and replaced by +// the parent field. func (c *ProjectsLocationsOperationsListCall) Zone(zone string) *ProjectsLocationsOperationsListCall { c.urlParams_.Set("zone", zone) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsLocationsOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15568,12 +11858,7 @@ func (c *ProjectsLocationsOperationsListCall) Header() http.Header { } func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -15594,12 +11879,11 @@ func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Respo } // Do executes the "container.projects.locations.operations.list" call. -// Exactly one of *ListOperationsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListOperationsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListOperationsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15630,47 +11914,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Lists all operations in a project in the specified zone or all zones.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations", - // "httpMethod": "GET", - // "id": "container.projects.locations.operations.list", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "The parent (project and location) where the operations will be listed. Specified in the format `projects/*/locations/*`. Location \"-\" matches all zones and all regions.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "deprecated": true, - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // }, - // "zone": { - // "deprecated": true, - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) to return operations for, or `-` for all zones. This field has been deprecated and replaced by the parent field.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta1/{+parent}/operations", - // "response": { - // "$ref": "ListOperationsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.getServerconfig": +} type ProjectsZonesGetServerconfigCall struct { s *Service @@ -15682,17 +11926,17 @@ type ProjectsZonesGetServerconfigCall struct { header_ http.Header } -// GetServerconfig: Returns configuration info about the Google -// Kubernetes Engine service. +// GetServerconfig: Returns configuration info about the Google Kubernetes +// Engine service. // -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone // (https://cloud.google.com/compute/docs/zones#available) to return -// operations for. This field has been deprecated and replaced by the -// name field. +// operations for. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesService) GetServerconfig(projectId string, zone string) *ProjectsZonesGetServerconfigCall { c := &ProjectsZonesGetServerconfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -15700,42 +11944,37 @@ func (r *ProjectsZonesService) GetServerconfig(projectId string, zone string) *P return c } -// Name sets the optional parameter "name": The name (project and -// location) of the server config to get, specified in the format -// `projects/*/locations/*`. +// Name sets the optional parameter "name": The name (project and location) of +// the server config to get, specified in the format `projects/*/locations/*`. func (c *ProjectsZonesGetServerconfigCall) Name(name string) *ProjectsZonesGetServerconfigCall { c.urlParams_.Set("name", name) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesGetServerconfigCall) Fields(s ...googleapi.Field) *ProjectsZonesGetServerconfigCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesGetServerconfigCall) IfNoneMatch(entityTag string) *ProjectsZonesGetServerconfigCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesGetServerconfigCall) Context(ctx context.Context) *ProjectsZonesGetServerconfigCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesGetServerconfigCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15744,12 +11983,7 @@ func (c *ProjectsZonesGetServerconfigCall) Header() http.Header { } func (c *ProjectsZonesGetServerconfigCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -15771,12 +12005,10 @@ func (c *ProjectsZonesGetServerconfigCall) doRequest(alt string) (*http.Response } // Do executes the "container.projects.zones.getServerconfig" call. -// Exactly one of *ServerConfig or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *ServerConfig.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ServerConfig.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesGetServerconfigCall) Do(opts ...googleapi.CallOption) (*ServerConfig, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15807,46 +12039,7 @@ func (c *ProjectsZonesGetServerconfigCall) Do(opts ...googleapi.CallOption) (*Se return nil, err } return ret, nil - // { - // "description": "Returns configuration info about the Google Kubernetes Engine service.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/serverconfig", - // "httpMethod": "GET", - // "id": "container.projects.zones.getServerconfig", - // "parameterOrder": [ - // "projectId", - // "zone" - // ], - // "parameters": { - // "name": { - // "description": "The name (project and location) of the server config to get, specified in the format `projects/*/locations/*`.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) to return operations for. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/serverconfig", - // "response": { - // "$ref": "ServerConfig" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.addons": +} type ProjectsZonesClustersAddonsCall struct { s *Service @@ -15861,16 +12054,16 @@ type ProjectsZonesClustersAddonsCall struct { // Addons: Sets the addons for a specific cluster. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Addons(projectId string, zone string, clusterId string, setaddonsconfigrequest *SetAddonsConfigRequest) *ProjectsZonesClustersAddonsCall { c := &ProjectsZonesClustersAddonsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -15881,23 +12074,21 @@ func (r *ProjectsZonesClustersService) Addons(projectId string, zone string, clu } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersAddonsCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersAddonsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersAddonsCall) Context(ctx context.Context) *ProjectsZonesClustersAddonsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersAddonsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15906,18 +12097,12 @@ func (c *ProjectsZonesClustersAddonsCall) Header() http.Header { } func (c *ProjectsZonesClustersAddonsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setaddonsconfigrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/addons") @@ -15936,12 +12121,10 @@ func (c *ProjectsZonesClustersAddonsCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.clusters.addons" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersAddonsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15972,51 +12155,7 @@ func (c *ProjectsZonesClustersAddonsCall) Do(opts ...googleapi.CallOption) (*Ope return nil, err } return ret, nil - // { - // "description": "Sets the addons for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/addons", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.addons", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/addons", - // "request": { - // "$ref": "SetAddonsConfigRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.completeIpRotation": +} type ProjectsZonesClustersCompleteIpRotationCall struct { s *Service @@ -16033,14 +12172,14 @@ type ProjectsZonesClustersCompleteIpRotationCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) CompleteIpRotation(projectId string, zone string, clusterId string, completeiprotationrequest *CompleteIPRotationRequest) *ProjectsZonesClustersCompleteIpRotationCall { c := &ProjectsZonesClustersCompleteIpRotationCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -16051,23 +12190,21 @@ func (r *ProjectsZonesClustersService) CompleteIpRotation(projectId string, zone } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersCompleteIpRotationCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersCompleteIpRotationCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersCompleteIpRotationCall) Context(ctx context.Context) *ProjectsZonesClustersCompleteIpRotationCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersCompleteIpRotationCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16076,18 +12213,12 @@ func (c *ProjectsZonesClustersCompleteIpRotationCall) Header() http.Header { } func (c *ProjectsZonesClustersCompleteIpRotationCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.completeiprotationrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:completeIpRotation") @@ -16106,12 +12237,10 @@ func (c *ProjectsZonesClustersCompleteIpRotationCall) doRequest(alt string) (*ht } // Do executes the "container.projects.zones.clusters.completeIpRotation" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersCompleteIpRotationCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16142,51 +12271,7 @@ func (c *ProjectsZonesClustersCompleteIpRotationCall) Do(opts ...googleapi.CallO return nil, err } return ret, nil - // { - // "description": "Completes master IP rotation.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:completeIpRotation", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.completeIpRotation", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:completeIpRotation", - // "request": { - // "$ref": "CompleteIPRotationRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.create": +} type ProjectsZonesClustersCreateCall struct { s *Service @@ -16198,24 +12283,24 @@ type ProjectsZonesClustersCreateCall struct { header_ http.Header } -// Create: Creates a cluster, consisting of the specified number and -// type of Google Compute Engine instances. By default, the cluster is -// created in the project's default network -// (https://cloud.google.com/compute/docs/networks-and-firewalls#networks). -// One firewall is added for the cluster. After cluster creation, the -// Kubelet creates routes for each node to allow the containers on that -// node to communicate with all other instances in the cluster. Finally, -// an entry is added to the project's global metadata indicating which -// CIDR range the cluster is using. +// Create: Creates a cluster, consisting of the specified number and type of +// Google Compute Engine instances. By default, the cluster is created in the +// project's default network +// (https://cloud.google.com/compute/docs/networks-and-firewalls#networks). One +// firewall is added for the cluster. After cluster creation, the Kubelet +// creates routes for each node to allow the containers on that node to +// communicate with all other instances in the cluster. Finally, an entry is +// added to the project's global metadata indicating which CIDR range the +// cluster is using. // -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the parent field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the parent +// field. func (r *ProjectsZonesClustersService) Create(projectId string, zone string, createclusterrequest *CreateClusterRequest) *ProjectsZonesClustersCreateCall { c := &ProjectsZonesClustersCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -16225,23 +12310,21 @@ func (r *ProjectsZonesClustersService) Create(projectId string, zone string, cre } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersCreateCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersCreateCall) Context(ctx context.Context) *ProjectsZonesClustersCreateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16250,18 +12333,12 @@ func (c *ProjectsZonesClustersCreateCall) Header() http.Header { } func (c *ProjectsZonesClustersCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.createclusterrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters") @@ -16279,12 +12356,10 @@ func (c *ProjectsZonesClustersCreateCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.clusters.create" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16315,44 +12390,7 @@ func (c *ProjectsZonesClustersCreateCall) Do(opts ...googleapi.CallOption) (*Ope return nil, err } return ret, nil - // { - // "description": "Creates a cluster, consisting of the specified number and type of Google Compute Engine instances. By default, the cluster is created in the project's [default network](https://cloud.google.com/compute/docs/networks-and-firewalls#networks). One firewall is added for the cluster. After cluster creation, the Kubelet creates routes for each node to allow the containers on that node to communicate with all other instances in the cluster. Finally, an entry is added to the project's global metadata indicating which CIDR range the cluster is using.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.create", - // "parameterOrder": [ - // "projectId", - // "zone" - // ], - // "parameters": { - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters", - // "request": { - // "$ref": "CreateClusterRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.delete": +} type ProjectsZonesClustersDeleteCall struct { s *Service @@ -16364,23 +12402,22 @@ type ProjectsZonesClustersDeleteCall struct { header_ http.Header } -// Delete: Deletes the cluster, including the Kubernetes endpoint and -// all worker nodes. Firewalls and routes that were configured during -// cluster creation are also deleted. Other Google Compute Engine -// resources that might be in use by the cluster, such as load balancer -// resources, are not deleted if they weren't present when the cluster -// was initially created. +// Delete: Deletes the cluster, including the Kubernetes endpoint and all +// worker nodes. Firewalls and routes that were configured during cluster +// creation are also deleted. Other Google Compute Engine resources that might +// be in use by the cluster, such as load balancer resources, are not deleted +// if they weren't present when the cluster was initially created. // -// - clusterId: Deprecated. The name of the cluster to delete. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to delete. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Delete(projectId string, zone string, clusterId string) *ProjectsZonesClustersDeleteCall { c := &ProjectsZonesClustersDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -16398,23 +12435,21 @@ func (c *ProjectsZonesClustersDeleteCall) Name(name string) *ProjectsZonesCluste } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersDeleteCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersDeleteCall) Context(ctx context.Context) *ProjectsZonesClustersDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16423,12 +12458,7 @@ func (c *ProjectsZonesClustersDeleteCall) Header() http.Header { } func (c *ProjectsZonesClustersDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -16448,12 +12478,10 @@ func (c *ProjectsZonesClustersDeleteCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.clusters.delete" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16484,53 +12512,7 @@ func (c *ProjectsZonesClustersDeleteCall) Do(opts ...googleapi.CallOption) (*Ope return nil, err } return ret, nil - // { - // "description": "Deletes the cluster, including the Kubernetes endpoint and all worker nodes. Firewalls and routes that were configured during cluster creation are also deleted. Other Google Compute Engine resources that might be in use by the cluster, such as load balancer resources, are not deleted if they weren't present when the cluster was initially created.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", - // "httpMethod": "DELETE", - // "id": "container.projects.zones.clusters.delete", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to delete. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster) of the cluster to delete. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.get": +} type ProjectsZonesClustersGetCall struct { s *Service @@ -16545,16 +12527,16 @@ type ProjectsZonesClustersGetCall struct { // Get: Gets the details for a specific cluster. // -// - clusterId: Deprecated. The name of the cluster to retrieve. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to retrieve. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Get(projectId string, zone string, clusterId string) *ProjectsZonesClustersGetCall { c := &ProjectsZonesClustersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -16572,33 +12554,29 @@ func (c *ProjectsZonesClustersGetCall) Name(name string) *ProjectsZonesClustersG } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersGetCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesClustersGetCall) IfNoneMatch(entityTag string) *ProjectsZonesClustersGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersGetCall) Context(ctx context.Context) *ProjectsZonesClustersGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16607,12 +12585,7 @@ func (c *ProjectsZonesClustersGetCall) Header() http.Header { } func (c *ProjectsZonesClustersGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -16635,12 +12608,10 @@ func (c *ProjectsZonesClustersGetCall) doRequest(alt string) (*http.Response, er } // Do executes the "container.projects.zones.clusters.get" call. -// Exactly one of *Cluster or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Cluster.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Cluster.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersGetCall) Do(opts ...googleapi.CallOption) (*Cluster, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16671,53 +12642,7 @@ func (c *ProjectsZonesClustersGetCall) Do(opts ...googleapi.CallOption) (*Cluste return nil, err } return ret, nil - // { - // "description": "Gets the details for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", - // "httpMethod": "GET", - // "id": "container.projects.zones.clusters.get", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to retrieve. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster) of the cluster to retrieve. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", - // "response": { - // "$ref": "Cluster" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.legacyAbac": +} type ProjectsZonesClustersLegacyAbacCall struct { s *Service @@ -16733,16 +12658,16 @@ type ProjectsZonesClustersLegacyAbacCall struct { // LegacyAbac: Enables or disables the ABAC authorization mechanism on a // cluster. // -// - clusterId: Deprecated. The name of the cluster to update. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to update. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) LegacyAbac(projectId string, zone string, clusterId string, setlegacyabacrequest *SetLegacyAbacRequest) *ProjectsZonesClustersLegacyAbacCall { c := &ProjectsZonesClustersLegacyAbacCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -16753,23 +12678,21 @@ func (r *ProjectsZonesClustersService) LegacyAbac(projectId string, zone string, } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersLegacyAbacCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersLegacyAbacCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersLegacyAbacCall) Context(ctx context.Context) *ProjectsZonesClustersLegacyAbacCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersLegacyAbacCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16778,18 +12701,12 @@ func (c *ProjectsZonesClustersLegacyAbacCall) Header() http.Header { } func (c *ProjectsZonesClustersLegacyAbacCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setlegacyabacrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/legacyAbac") @@ -16808,12 +12725,10 @@ func (c *ProjectsZonesClustersLegacyAbacCall) doRequest(alt string) (*http.Respo } // Do executes the "container.projects.zones.clusters.legacyAbac" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersLegacyAbacCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16844,51 +12759,7 @@ func (c *ProjectsZonesClustersLegacyAbacCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Enables or disables the ABAC authorization mechanism on a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/legacyAbac", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.legacyAbac", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to update. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/legacyAbac", - // "request": { - // "$ref": "SetLegacyAbacRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.list": +} type ProjectsZonesClustersListCall struct { s *Service @@ -16900,17 +12771,17 @@ type ProjectsZonesClustersListCall struct { header_ http.Header } -// List: Lists all clusters owned by a project in either the specified -// zone or all zones. +// List: Lists all clusters owned by a project in either the specified zone or +// all zones. // -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides, or "-" for all zones. This field has been -// deprecated and replaced by the parent field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides, or "-" for all zones. This field has been deprecated and +// replaced by the parent field. func (r *ProjectsZonesClustersService) List(projectId string, zone string) *ProjectsZonesClustersListCall { c := &ProjectsZonesClustersListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -16920,41 +12791,36 @@ func (r *ProjectsZonesClustersService) List(projectId string, zone string) *Proj // Parent sets the optional parameter "parent": The parent (project and // location) where the clusters will be listed. Specified in the format -// `projects/*/locations/*`. Location "-" matches all zones and all -// regions. +// `projects/*/locations/*`. Location "-" matches all zones and all regions. func (c *ProjectsZonesClustersListCall) Parent(parent string) *ProjectsZonesClustersListCall { c.urlParams_.Set("parent", parent) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersListCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesClustersListCall) IfNoneMatch(entityTag string) *ProjectsZonesClustersListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersListCall) Context(ctx context.Context) *ProjectsZonesClustersListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16963,12 +12829,7 @@ func (c *ProjectsZonesClustersListCall) Header() http.Header { } func (c *ProjectsZonesClustersListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -16990,12 +12851,11 @@ func (c *ProjectsZonesClustersListCall) doRequest(alt string) (*http.Response, e } // Do executes the "container.projects.zones.clusters.list" call. -// Exactly one of *ListClustersResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListClustersResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListClustersResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsZonesClustersListCall) Do(opts ...googleapi.CallOption) (*ListClustersResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17026,46 +12886,7 @@ func (c *ProjectsZonesClustersListCall) Do(opts ...googleapi.CallOption) (*ListC return nil, err } return ret, nil - // { - // "description": "Lists all clusters owned by a project in either the specified zone or all zones.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters", - // "httpMethod": "GET", - // "id": "container.projects.zones.clusters.list", - // "parameterOrder": [ - // "projectId", - // "zone" - // ], - // "parameters": { - // "parent": { - // "description": "The parent (project and location) where the clusters will be listed. Specified in the format `projects/*/locations/*`. Location \"-\" matches all zones and all regions.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides, or \"-\" for all zones. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters", - // "response": { - // "$ref": "ListClustersResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.locations": +} type ProjectsZonesClustersLocationsCall struct { s *Service @@ -17083,16 +12904,16 @@ type ProjectsZonesClustersLocationsCall struct { // (https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters/update) // instead. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Locations(projectId string, zone string, clusterId string, setlocationsrequest *SetLocationsRequest) *ProjectsZonesClustersLocationsCall { c := &ProjectsZonesClustersLocationsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17103,23 +12924,21 @@ func (r *ProjectsZonesClustersService) Locations(projectId string, zone string, } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersLocationsCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersLocationsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersLocationsCall) Context(ctx context.Context) *ProjectsZonesClustersLocationsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersLocationsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17128,18 +12947,12 @@ func (c *ProjectsZonesClustersLocationsCall) Header() http.Header { } func (c *ProjectsZonesClustersLocationsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setlocationsrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/locations") @@ -17158,12 +12971,10 @@ func (c *ProjectsZonesClustersLocationsCall) doRequest(alt string) (*http.Respon } // Do executes the "container.projects.zones.clusters.locations" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersLocationsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17194,52 +13005,7 @@ func (c *ProjectsZonesClustersLocationsCall) Do(opts ...googleapi.CallOption) (* return nil, err } return ret, nil - // { - // "deprecated": true, - // "description": "Sets the locations for a specific cluster. Deprecated. Use [projects.locations.clusters.update](https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters/update) instead.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/locations", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.locations", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/locations", - // "request": { - // "$ref": "SetLocationsRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.logging": +} type ProjectsZonesClustersLoggingCall struct { s *Service @@ -17254,16 +13020,16 @@ type ProjectsZonesClustersLoggingCall struct { // Logging: Sets the logging service for a specific cluster. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Logging(projectId string, zone string, clusterId string, setloggingservicerequest *SetLoggingServiceRequest) *ProjectsZonesClustersLoggingCall { c := &ProjectsZonesClustersLoggingCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17274,23 +13040,21 @@ func (r *ProjectsZonesClustersService) Logging(projectId string, zone string, cl } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersLoggingCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersLoggingCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersLoggingCall) Context(ctx context.Context) *ProjectsZonesClustersLoggingCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersLoggingCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17299,18 +13063,12 @@ func (c *ProjectsZonesClustersLoggingCall) Header() http.Header { } func (c *ProjectsZonesClustersLoggingCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setloggingservicerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/logging") @@ -17329,12 +13087,10 @@ func (c *ProjectsZonesClustersLoggingCall) doRequest(alt string) (*http.Response } // Do executes the "container.projects.zones.clusters.logging" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersLoggingCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17365,51 +13121,7 @@ func (c *ProjectsZonesClustersLoggingCall) Do(opts ...googleapi.CallOption) (*Op return nil, err } return ret, nil - // { - // "description": "Sets the logging service for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/logging", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.logging", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/logging", - // "request": { - // "$ref": "SetLoggingServiceRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.master": +} type ProjectsZonesClustersMasterCall struct { s *Service @@ -17424,16 +13136,16 @@ type ProjectsZonesClustersMasterCall struct { // Master: Updates the master for a specific cluster. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Master(projectId string, zone string, clusterId string, updatemasterrequest *UpdateMasterRequest) *ProjectsZonesClustersMasterCall { c := &ProjectsZonesClustersMasterCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17444,23 +13156,21 @@ func (r *ProjectsZonesClustersService) Master(projectId string, zone string, clu } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersMasterCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersMasterCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersMasterCall) Context(ctx context.Context) *ProjectsZonesClustersMasterCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersMasterCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17469,18 +13179,12 @@ func (c *ProjectsZonesClustersMasterCall) Header() http.Header { } func (c *ProjectsZonesClustersMasterCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.updatemasterrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/master") @@ -17499,12 +13203,10 @@ func (c *ProjectsZonesClustersMasterCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.clusters.master" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersMasterCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17535,51 +13237,7 @@ func (c *ProjectsZonesClustersMasterCall) Do(opts ...googleapi.CallOption) (*Ope return nil, err } return ret, nil - // { - // "description": "Updates the master for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/master", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.master", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/master", - // "request": { - // "$ref": "UpdateMasterRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.monitoring": +} type ProjectsZonesClustersMonitoringCall struct { s *Service @@ -17594,16 +13252,16 @@ type ProjectsZonesClustersMonitoringCall struct { // Monitoring: Sets the monitoring service for a specific cluster. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Monitoring(projectId string, zone string, clusterId string, setmonitoringservicerequest *SetMonitoringServiceRequest) *ProjectsZonesClustersMonitoringCall { c := &ProjectsZonesClustersMonitoringCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17614,23 +13272,21 @@ func (r *ProjectsZonesClustersService) Monitoring(projectId string, zone string, } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersMonitoringCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersMonitoringCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersMonitoringCall) Context(ctx context.Context) *ProjectsZonesClustersMonitoringCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersMonitoringCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17639,18 +13295,12 @@ func (c *ProjectsZonesClustersMonitoringCall) Header() http.Header { } func (c *ProjectsZonesClustersMonitoringCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setmonitoringservicerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/monitoring") @@ -17669,12 +13319,10 @@ func (c *ProjectsZonesClustersMonitoringCall) doRequest(alt string) (*http.Respo } // Do executes the "container.projects.zones.clusters.monitoring" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersMonitoringCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17705,51 +13353,7 @@ func (c *ProjectsZonesClustersMonitoringCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Sets the monitoring service for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/monitoring", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.monitoring", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/monitoring", - // "request": { - // "$ref": "SetMonitoringServiceRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.resourceLabels": +} type ProjectsZonesClustersResourceLabelsCall struct { s *Service @@ -17766,14 +13370,14 @@ type ProjectsZonesClustersResourceLabelsCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) ResourceLabels(projectId string, zone string, clusterId string, setlabelsrequest *SetLabelsRequest) *ProjectsZonesClustersResourceLabelsCall { c := &ProjectsZonesClustersResourceLabelsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17784,23 +13388,21 @@ func (r *ProjectsZonesClustersService) ResourceLabels(projectId string, zone str } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersResourceLabelsCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersResourceLabelsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersResourceLabelsCall) Context(ctx context.Context) *ProjectsZonesClustersResourceLabelsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersResourceLabelsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17809,18 +13411,12 @@ func (c *ProjectsZonesClustersResourceLabelsCall) Header() http.Header { } func (c *ProjectsZonesClustersResourceLabelsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setlabelsrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/resourceLabels") @@ -17839,12 +13435,10 @@ func (c *ProjectsZonesClustersResourceLabelsCall) doRequest(alt string) (*http.R } // Do executes the "container.projects.zones.clusters.resourceLabels" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersResourceLabelsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17875,51 +13469,7 @@ func (c *ProjectsZonesClustersResourceLabelsCall) Do(opts ...googleapi.CallOptio return nil, err } return ret, nil - // { - // "description": "Sets labels on a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/resourceLabels", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.resourceLabels", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/resourceLabels", - // "request": { - // "$ref": "SetLabelsRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.setMaintenancePolicy": +} type ProjectsZonesClustersSetMaintenancePolicyCall struct { s *Service @@ -17935,12 +13485,11 @@ type ProjectsZonesClustersSetMaintenancePolicyCall struct { // SetMaintenancePolicy: Sets the maintenance policy for a cluster. // // - clusterId: The name of the cluster to update. -// - projectId: The Google Developers Console project ID or project -// number +// - projectId: The Google Developers Console project ID or project number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // - zone: The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. func (r *ProjectsZonesClustersService) SetMaintenancePolicy(projectId string, zone string, clusterId string, setmaintenancepolicyrequest *SetMaintenancePolicyRequest) *ProjectsZonesClustersSetMaintenancePolicyCall { c := &ProjectsZonesClustersSetMaintenancePolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17951,23 +13500,21 @@ func (r *ProjectsZonesClustersService) SetMaintenancePolicy(projectId string, zo } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersSetMaintenancePolicyCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersSetMaintenancePolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersSetMaintenancePolicyCall) Context(ctx context.Context) *ProjectsZonesClustersSetMaintenancePolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersSetMaintenancePolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17976,18 +13523,12 @@ func (c *ProjectsZonesClustersSetMaintenancePolicyCall) Header() http.Header { } func (c *ProjectsZonesClustersSetMaintenancePolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setmaintenancepolicyrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMaintenancePolicy") @@ -18006,12 +13547,10 @@ func (c *ProjectsZonesClustersSetMaintenancePolicyCall) doRequest(alt string) (* } // Do executes the "container.projects.zones.clusters.setMaintenancePolicy" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersSetMaintenancePolicyCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18042,51 +13581,7 @@ func (c *ProjectsZonesClustersSetMaintenancePolicyCall) Do(opts ...googleapi.Cal return nil, err } return ret, nil - // { - // "description": "Sets the maintenance policy for a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMaintenancePolicy", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.setMaintenancePolicy", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. The name of the cluster to update.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMaintenancePolicy", - // "request": { - // "$ref": "SetMaintenancePolicyRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.setMasterAuth": +} type ProjectsZonesClustersSetMasterAuthCall struct { s *Service @@ -18099,20 +13594,20 @@ type ProjectsZonesClustersSetMasterAuthCall struct { header_ http.Header } -// SetMasterAuth: Sets master auth materials. Currently supports -// changing the admin password or a specific cluster, either via -// password generation or explicitly setting the password. +// SetMasterAuth: Sets master auth materials. Currently supports changing the +// admin password or a specific cluster, either via password generation or +// explicitly setting the password. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) SetMasterAuth(projectId string, zone string, clusterId string, setmasterauthrequest *SetMasterAuthRequest) *ProjectsZonesClustersSetMasterAuthCall { c := &ProjectsZonesClustersSetMasterAuthCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -18123,23 +13618,21 @@ func (r *ProjectsZonesClustersService) SetMasterAuth(projectId string, zone stri } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersSetMasterAuthCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersSetMasterAuthCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersSetMasterAuthCall) Context(ctx context.Context) *ProjectsZonesClustersSetMasterAuthCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersSetMasterAuthCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18148,18 +13641,12 @@ func (c *ProjectsZonesClustersSetMasterAuthCall) Header() http.Header { } func (c *ProjectsZonesClustersSetMasterAuthCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setmasterauthrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMasterAuth") @@ -18178,12 +13665,10 @@ func (c *ProjectsZonesClustersSetMasterAuthCall) doRequest(alt string) (*http.Re } // Do executes the "container.projects.zones.clusters.setMasterAuth" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersSetMasterAuthCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18214,51 +13699,7 @@ func (c *ProjectsZonesClustersSetMasterAuthCall) Do(opts ...googleapi.CallOption return nil, err } return ret, nil - // { - // "description": "Sets master auth materials. Currently supports changing the admin password or a specific cluster, either via password generation or explicitly setting the password.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMasterAuth", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.setMasterAuth", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMasterAuth", - // "request": { - // "$ref": "SetMasterAuthRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.setNetworkPolicy": +} type ProjectsZonesClustersSetNetworkPolicyCall struct { s *Service @@ -18275,14 +13716,14 @@ type ProjectsZonesClustersSetNetworkPolicyCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) SetNetworkPolicy(projectId string, zone string, clusterId string, setnetworkpolicyrequest *SetNetworkPolicyRequest) *ProjectsZonesClustersSetNetworkPolicyCall { c := &ProjectsZonesClustersSetNetworkPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -18293,23 +13734,21 @@ func (r *ProjectsZonesClustersService) SetNetworkPolicy(projectId string, zone s } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersSetNetworkPolicyCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersSetNetworkPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersSetNetworkPolicyCall) Context(ctx context.Context) *ProjectsZonesClustersSetNetworkPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersSetNetworkPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18318,18 +13757,12 @@ func (c *ProjectsZonesClustersSetNetworkPolicyCall) Header() http.Header { } func (c *ProjectsZonesClustersSetNetworkPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnetworkpolicyrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setNetworkPolicy") @@ -18348,12 +13781,10 @@ func (c *ProjectsZonesClustersSetNetworkPolicyCall) doRequest(alt string) (*http } // Do executes the "container.projects.zones.clusters.setNetworkPolicy" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersSetNetworkPolicyCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18384,51 +13815,7 @@ func (c *ProjectsZonesClustersSetNetworkPolicyCall) Do(opts ...googleapi.CallOpt return nil, err } return ret, nil - // { - // "description": "Enables or disables Network Policy for a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setNetworkPolicy", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.setNetworkPolicy", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setNetworkPolicy", - // "request": { - // "$ref": "SetNetworkPolicyRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.startIpRotation": +} type ProjectsZonesClustersStartIpRotationCall struct { s *Service @@ -18445,14 +13832,14 @@ type ProjectsZonesClustersStartIpRotationCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) StartIpRotation(projectId string, zone string, clusterId string, startiprotationrequest *StartIPRotationRequest) *ProjectsZonesClustersStartIpRotationCall { c := &ProjectsZonesClustersStartIpRotationCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -18463,23 +13850,21 @@ func (r *ProjectsZonesClustersService) StartIpRotation(projectId string, zone st } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersStartIpRotationCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersStartIpRotationCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersStartIpRotationCall) Context(ctx context.Context) *ProjectsZonesClustersStartIpRotationCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersStartIpRotationCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18488,18 +13873,12 @@ func (c *ProjectsZonesClustersStartIpRotationCall) Header() http.Header { } func (c *ProjectsZonesClustersStartIpRotationCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.startiprotationrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:startIpRotation") @@ -18518,12 +13897,10 @@ func (c *ProjectsZonesClustersStartIpRotationCall) doRequest(alt string) (*http. } // Do executes the "container.projects.zones.clusters.startIpRotation" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersStartIpRotationCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18554,51 +13931,7 @@ func (c *ProjectsZonesClustersStartIpRotationCall) Do(opts ...googleapi.CallOpti return nil, err } return ret, nil - // { - // "description": "Starts master IP rotation.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:startIpRotation", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.startIpRotation", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:startIpRotation", - // "request": { - // "$ref": "StartIPRotationRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.update": +} type ProjectsZonesClustersUpdateCall struct { s *Service @@ -18613,16 +13946,16 @@ type ProjectsZonesClustersUpdateCall struct { // Update: Updates the settings for a specific cluster. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersService) Update(projectId string, zone string, clusterId string, updateclusterrequest *UpdateClusterRequest) *ProjectsZonesClustersUpdateCall { c := &ProjectsZonesClustersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -18633,23 +13966,21 @@ func (r *ProjectsZonesClustersService) Update(projectId string, zone string, clu } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersUpdateCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersUpdateCall) Context(ctx context.Context) *ProjectsZonesClustersUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18658,18 +13989,12 @@ func (c *ProjectsZonesClustersUpdateCall) Header() http.Header { } func (c *ProjectsZonesClustersUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.updateclusterrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}") @@ -18688,12 +14013,10 @@ func (c *ProjectsZonesClustersUpdateCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.clusters.update" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18724,51 +14047,7 @@ func (c *ProjectsZonesClustersUpdateCall) Do(opts ...googleapi.CallOption) (*Ope return nil, err } return ret, nil - // { - // "description": "Updates the settings for a specific cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", - // "httpMethod": "PUT", - // "id": "container.projects.zones.clusters.update", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", - // "request": { - // "$ref": "UpdateClusterRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.autoscaling": +} type ProjectsZonesClustersNodePoolsAutoscalingCall struct { s *Service @@ -18784,18 +14063,18 @@ type ProjectsZonesClustersNodePoolsAutoscalingCall struct { // Autoscaling: Sets the autoscaling settings of a specific node pool. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - nodePoolId: Deprecated. The name of the node pool to upgrade. This field +// has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) Autoscaling(projectId string, zone string, clusterId string, nodePoolId string, setnodepoolautoscalingrequest *SetNodePoolAutoscalingRequest) *ProjectsZonesClustersNodePoolsAutoscalingCall { c := &ProjectsZonesClustersNodePoolsAutoscalingCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -18807,23 +14086,21 @@ func (r *ProjectsZonesClustersNodePoolsService) Autoscaling(projectId string, zo } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsAutoscalingCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsAutoscalingCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18832,18 +14109,12 @@ func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnodepoolautoscalingrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/autoscaling") @@ -18863,12 +14134,10 @@ func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) doRequest(alt string) (* } // Do executes the "container.projects.zones.clusters.nodePools.autoscaling" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18899,58 +14168,7 @@ func (c *ProjectsZonesClustersNodePoolsAutoscalingCall) Do(opts ...googleapi.Cal return nil, err } return ret, nil - // { - // "description": "Sets the autoscaling settings of a specific node pool.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/autoscaling", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.nodePools.autoscaling", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/autoscaling", - // "request": { - // "$ref": "SetNodePoolAutoscalingRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.create": +} type ProjectsZonesClustersNodePoolsCreateCall struct { s *Service @@ -18967,14 +14185,14 @@ type ProjectsZonesClustersNodePoolsCreateCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the parent field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the parent field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the parent +// field. func (r *ProjectsZonesClustersNodePoolsService) Create(projectId string, zone string, clusterId string, createnodepoolrequest *CreateNodePoolRequest) *ProjectsZonesClustersNodePoolsCreateCall { c := &ProjectsZonesClustersNodePoolsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -18985,23 +14203,21 @@ func (r *ProjectsZonesClustersNodePoolsService) Create(projectId string, zone st } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsCreateCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsCreateCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsCreateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -19010,18 +14226,12 @@ func (c *ProjectsZonesClustersNodePoolsCreateCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.createnodepoolrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools") @@ -19040,12 +14250,10 @@ func (c *ProjectsZonesClustersNodePoolsCreateCall) doRequest(alt string) (*http. } // Do executes the "container.projects.zones.clusters.nodePools.create" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -19076,51 +14284,7 @@ func (c *ProjectsZonesClustersNodePoolsCreateCall) Do(opts ...googleapi.CallOpti return nil, err } return ret, nil - // { - // "description": "Creates a node pool for a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.nodePools.create", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools", - // "request": { - // "$ref": "CreateNodePoolRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.delete": +} type ProjectsZonesClustersNodePoolsDeleteCall struct { s *Service @@ -19137,16 +14301,16 @@ type ProjectsZonesClustersNodePoolsDeleteCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool to delete. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - nodePoolId: Deprecated. The name of the node pool to delete. This field +// has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) Delete(projectId string, zone string, clusterId string, nodePoolId string) *ProjectsZonesClustersNodePoolsDeleteCall { c := &ProjectsZonesClustersNodePoolsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -19157,31 +14321,29 @@ func (r *ProjectsZonesClustersNodePoolsService) Delete(projectId string, zone st } // Name sets the optional parameter "name": The name (project, location, -// cluster, node pool id) of the node pool to delete. Specified in the -// format `projects/*/locations/*/clusters/*/nodePools/*`. +// cluster, node pool id) of the node pool to delete. Specified in the format +// `projects/*/locations/*/clusters/*/nodePools/*`. func (c *ProjectsZonesClustersNodePoolsDeleteCall) Name(name string) *ProjectsZonesClustersNodePoolsDeleteCall { c.urlParams_.Set("name", name) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsDeleteCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsDeleteCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -19190,12 +14352,7 @@ func (c *ProjectsZonesClustersNodePoolsDeleteCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -19216,12 +14373,10 @@ func (c *ProjectsZonesClustersNodePoolsDeleteCall) doRequest(alt string) (*http. } // Do executes the "container.projects.zones.clusters.nodePools.delete" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -19252,60 +14407,7 @@ func (c *ProjectsZonesClustersNodePoolsDeleteCall) Do(opts ...googleapi.CallOpti return nil, err } return ret, nil - // { - // "description": "Deletes a node pool from a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}", - // "httpMethod": "DELETE", - // "id": "container.projects.zones.clusters.nodePools.delete", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to delete. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "query", - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool to delete. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}", - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.get": +} type ProjectsZonesClustersNodePoolsGetCall struct { s *Service @@ -19323,16 +14425,16 @@ type ProjectsZonesClustersNodePoolsGetCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool. This field has -// been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - nodePoolId: Deprecated. The name of the node pool. This field has been +// deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) Get(projectId string, zone string, clusterId string, nodePoolId string) *ProjectsZonesClustersNodePoolsGetCall { c := &ProjectsZonesClustersNodePoolsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -19343,41 +14445,37 @@ func (r *ProjectsZonesClustersNodePoolsService) Get(projectId string, zone strin } // Name sets the optional parameter "name": The name (project, location, -// cluster, node pool id) of the node pool to get. Specified in the -// format `projects/*/locations/*/clusters/*/nodePools/*`. +// cluster, node pool id) of the node pool to get. Specified in the format +// `projects/*/locations/*/clusters/*/nodePools/*`. func (c *ProjectsZonesClustersNodePoolsGetCall) Name(name string) *ProjectsZonesClustersNodePoolsGetCall { c.urlParams_.Set("name", name) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsGetCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesClustersNodePoolsGetCall) IfNoneMatch(entityTag string) *ProjectsZonesClustersNodePoolsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsGetCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -19386,12 +14484,7 @@ func (c *ProjectsZonesClustersNodePoolsGetCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -19415,12 +14508,10 @@ func (c *ProjectsZonesClustersNodePoolsGetCall) doRequest(alt string) (*http.Res } // Do executes the "container.projects.zones.clusters.nodePools.get" call. -// Exactly one of *NodePool or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *NodePool.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *NodePool.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsGetCall) Do(opts ...googleapi.CallOption) (*NodePool, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -19451,60 +14542,7 @@ func (c *ProjectsZonesClustersNodePoolsGetCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Retrieves the requested node pool.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}", - // "httpMethod": "GET", - // "id": "container.projects.zones.clusters.nodePools.get", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "name": { - // "description": "The name (project, location, cluster, node pool id) of the node pool to get. Specified in the format `projects/*/locations/*/clusters/*/nodePools/*`.", - // "location": "query", - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}", - // "response": { - // "$ref": "NodePool" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.list": +} type ProjectsZonesClustersNodePoolsListCall struct { s *Service @@ -19521,14 +14559,14 @@ type ProjectsZonesClustersNodePoolsListCall struct { // // - clusterId: Deprecated. The name of the cluster. This field has been // deprecated and replaced by the parent field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the parent field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the parent +// field. func (r *ProjectsZonesClustersNodePoolsService) List(projectId string, zone string, clusterId string) *ProjectsZonesClustersNodePoolsListCall { c := &ProjectsZonesClustersNodePoolsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -19537,42 +14575,38 @@ func (r *ProjectsZonesClustersNodePoolsService) List(projectId string, zone stri return c } -// Parent sets the optional parameter "parent": The parent (project, -// location, cluster name) where the node pools will be listed. -// Specified in the format `projects/*/locations/*/clusters/*`. +// Parent sets the optional parameter "parent": The parent (project, location, +// cluster name) where the node pools will be listed. Specified in the format +// `projects/*/locations/*/clusters/*`. func (c *ProjectsZonesClustersNodePoolsListCall) Parent(parent string) *ProjectsZonesClustersNodePoolsListCall { c.urlParams_.Set("parent", parent) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsListCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesClustersNodePoolsListCall) IfNoneMatch(entityTag string) *ProjectsZonesClustersNodePoolsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsListCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -19581,12 +14615,7 @@ func (c *ProjectsZonesClustersNodePoolsListCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -19609,12 +14638,11 @@ func (c *ProjectsZonesClustersNodePoolsListCall) doRequest(alt string) (*http.Re } // Do executes the "container.projects.zones.clusters.nodePools.list" call. -// Exactly one of *ListNodePoolsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListNodePoolsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListNodePoolsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsZonesClustersNodePoolsListCall) Do(opts ...googleapi.CallOption) (*ListNodePoolsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -19645,53 +14673,7 @@ func (c *ProjectsZonesClustersNodePoolsListCall) Do(opts ...googleapi.CallOption return nil, err } return ret, nil - // { - // "description": "Lists the node pools for a cluster.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools", - // "httpMethod": "GET", - // "id": "container.projects.zones.clusters.nodePools.list", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "parent": { - // "description": "The parent (project, location, cluster name) where the node pools will be listed. Specified in the format `projects/*/locations/*/clusters/*`.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools", - // "response": { - // "$ref": "ListNodePoolsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.rollback": +} type ProjectsZonesClustersNodePoolsRollbackCall struct { s *Service @@ -19705,21 +14687,21 @@ type ProjectsZonesClustersNodePoolsRollbackCall struct { header_ http.Header } -// Rollback: Rolls back a previously Aborted or Failed NodePool upgrade. -// This makes no changes if the last upgrade successfully completed. +// Rollback: Rolls back a previously Aborted or Failed NodePool upgrade. This +// makes no changes if the last upgrade successfully completed. // -// - clusterId: Deprecated. The name of the cluster to rollback. This -// field has been deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool to rollback. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to rollback. This field has +// been deprecated and replaced by the name field. +// - nodePoolId: Deprecated. The name of the node pool to rollback. This field +// has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) Rollback(projectId string, zone string, clusterId string, nodePoolId string, rollbacknodepoolupgraderequest *RollbackNodePoolUpgradeRequest) *ProjectsZonesClustersNodePoolsRollbackCall { c := &ProjectsZonesClustersNodePoolsRollbackCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -19731,23 +14713,21 @@ func (r *ProjectsZonesClustersNodePoolsService) Rollback(projectId string, zone } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsRollbackCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsRollbackCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsRollbackCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsRollbackCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsRollbackCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -19756,18 +14736,12 @@ func (c *ProjectsZonesClustersNodePoolsRollbackCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsRollbackCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.rollbacknodepoolupgraderequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}:rollback") @@ -19787,12 +14761,10 @@ func (c *ProjectsZonesClustersNodePoolsRollbackCall) doRequest(alt string) (*htt } // Do executes the "container.projects.zones.clusters.nodePools.rollback" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsRollbackCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -19823,58 +14795,7 @@ func (c *ProjectsZonesClustersNodePoolsRollbackCall) Do(opts ...googleapi.CallOp return nil, err } return ret, nil - // { - // "description": "Rolls back a previously Aborted or Failed NodePool upgrade. This makes no changes if the last upgrade successfully completed.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}:rollback", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.nodePools.rollback", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to rollback. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool to rollback. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}:rollback", - // "request": { - // "$ref": "RollbackNodePoolUpgradeRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.setManagement": +} type ProjectsZonesClustersNodePoolsSetManagementCall struct { s *Service @@ -19890,18 +14811,18 @@ type ProjectsZonesClustersNodePoolsSetManagementCall struct { // SetManagement: Sets the NodeManagement options for a node pool. // -// - clusterId: Deprecated. The name of the cluster to update. This -// field has been deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool to update. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to update. This field has +// been deprecated and replaced by the name field. +// - nodePoolId: Deprecated. The name of the node pool to update. This field +// has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) SetManagement(projectId string, zone string, clusterId string, nodePoolId string, setnodepoolmanagementrequest *SetNodePoolManagementRequest) *ProjectsZonesClustersNodePoolsSetManagementCall { c := &ProjectsZonesClustersNodePoolsSetManagementCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -19913,23 +14834,21 @@ func (r *ProjectsZonesClustersNodePoolsService) SetManagement(projectId string, } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsSetManagementCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsSetManagementCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsSetManagementCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsSetManagementCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsSetManagementCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -19938,18 +14857,12 @@ func (c *ProjectsZonesClustersNodePoolsSetManagementCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsSetManagementCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnodepoolmanagementrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setManagement") @@ -19969,12 +14882,10 @@ func (c *ProjectsZonesClustersNodePoolsSetManagementCall) doRequest(alt string) } // Do executes the "container.projects.zones.clusters.nodePools.setManagement" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsSetManagementCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -20005,58 +14916,7 @@ func (c *ProjectsZonesClustersNodePoolsSetManagementCall) Do(opts ...googleapi.C return nil, err } return ret, nil - // { - // "description": "Sets the NodeManagement options for a node pool.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setManagement", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.nodePools.setManagement", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to update. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool to update. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setManagement", - // "request": { - // "$ref": "SetNodePoolManagementRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.setSize": +} type ProjectsZonesClustersNodePoolsSetSizeCall struct { s *Service @@ -20070,22 +14930,22 @@ type ProjectsZonesClustersNodePoolsSetSizeCall struct { header_ http.Header } -// SetSize: SetNodePoolSizeRequest sets the size of a node pool. The new -// size will be used for all replicas, including future replicas created -// by modifying NodePool.locations. +// SetSize: SetNodePoolSizeRequest sets the size of a node pool. The new size +// will be used for all replicas, including future replicas created by +// modifying NodePool.locations. // -// - clusterId: Deprecated. The name of the cluster to update. This -// field has been deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool to update. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to update. This field has +// been deprecated and replaced by the name field. +// - nodePoolId: Deprecated. The name of the node pool to update. This field +// has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) SetSize(projectId string, zone string, clusterId string, nodePoolId string, setnodepoolsizerequest *SetNodePoolSizeRequest) *ProjectsZonesClustersNodePoolsSetSizeCall { c := &ProjectsZonesClustersNodePoolsSetSizeCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -20097,23 +14957,21 @@ func (r *ProjectsZonesClustersNodePoolsService) SetSize(projectId string, zone s } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsSetSizeCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsSetSizeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsSetSizeCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsSetSizeCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsSetSizeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -20122,18 +14980,12 @@ func (c *ProjectsZonesClustersNodePoolsSetSizeCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsSetSizeCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.setnodepoolsizerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setSize") @@ -20153,12 +15005,10 @@ func (c *ProjectsZonesClustersNodePoolsSetSizeCall) doRequest(alt string) (*http } // Do executes the "container.projects.zones.clusters.nodePools.setSize" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsSetSizeCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -20189,58 +15039,7 @@ func (c *ProjectsZonesClustersNodePoolsSetSizeCall) Do(opts ...googleapi.CallOpt return nil, err } return ret, nil - // { - // "description": "SetNodePoolSizeRequest sets the size of a node pool. The new size will be used for all replicas, including future replicas created by modifying NodePool.locations.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setSize", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.nodePools.setSize", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to update. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool to update. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setSize", - // "request": { - // "$ref": "SetNodePoolSizeRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.clusters.nodePools.update": +} type ProjectsZonesClustersNodePoolsUpdateCall struct { s *Service @@ -20254,21 +15053,20 @@ type ProjectsZonesClustersNodePoolsUpdateCall struct { header_ http.Header } -// Update: Updates the version and/or image type of a specific node -// pool. +// Update: Updates the version and/or image type of a specific node pool. // -// - clusterId: Deprecated. The name of the cluster to upgrade. This -// field has been deprecated and replaced by the name field. -// - nodePoolId: Deprecated. The name of the node pool to upgrade. This -// field has been deprecated and replaced by the name field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - clusterId: Deprecated. The name of the cluster to upgrade. This field has +// been deprecated and replaced by the name field. +// - nodePoolId: Deprecated. The name of the node pool to upgrade. This field +// has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesClustersNodePoolsService) Update(projectId string, zone string, clusterId string, nodePoolId string, updatenodepoolrequest *UpdateNodePoolRequest) *ProjectsZonesClustersNodePoolsUpdateCall { c := &ProjectsZonesClustersNodePoolsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -20280,23 +15078,21 @@ func (r *ProjectsZonesClustersNodePoolsService) Update(projectId string, zone st } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesClustersNodePoolsUpdateCall) Fields(s ...googleapi.Field) *ProjectsZonesClustersNodePoolsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesClustersNodePoolsUpdateCall) Context(ctx context.Context) *ProjectsZonesClustersNodePoolsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesClustersNodePoolsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -20305,18 +15101,12 @@ func (c *ProjectsZonesClustersNodePoolsUpdateCall) Header() http.Header { } func (c *ProjectsZonesClustersNodePoolsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.updatenodepoolrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/update") @@ -20336,12 +15126,10 @@ func (c *ProjectsZonesClustersNodePoolsUpdateCall) doRequest(alt string) (*http. } // Do executes the "container.projects.zones.clusters.nodePools.update" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesClustersNodePoolsUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -20372,58 +15160,7 @@ func (c *ProjectsZonesClustersNodePoolsUpdateCall) Do(opts ...googleapi.CallOpti return nil, err } return ret, nil - // { - // "description": "Updates the version and/or image type of a specific node pool.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/update", - // "httpMethod": "POST", - // "id": "container.projects.zones.clusters.nodePools.update", - // "parameterOrder": [ - // "projectId", - // "zone", - // "clusterId", - // "nodePoolId" - // ], - // "parameters": { - // "clusterId": { - // "description": "Required. Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "nodePoolId": { - // "description": "Required. Deprecated. The name of the node pool to upgrade. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/update", - // "request": { - // "$ref": "UpdateNodePoolRequest" - // }, - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.operations.cancel": +} type ProjectsZonesOperationsCancelCall struct { s *Service @@ -20438,17 +15175,16 @@ type ProjectsZonesOperationsCancelCall struct { // Cancel: Cancels the specified operation. // -// - operationId: Deprecated. The server-assigned `name` of the -// operation. This field has been deprecated and replaced by the name -// field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - operationId: Deprecated. The server-assigned `name` of the operation. This +// field has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the operation resides. This field has been deprecated and replaced -// by the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// operation resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesOperationsService) Cancel(projectId string, zone string, operationId string, canceloperationrequest *CancelOperationRequest) *ProjectsZonesOperationsCancelCall { c := &ProjectsZonesOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -20459,23 +15195,21 @@ func (r *ProjectsZonesOperationsService) Cancel(projectId string, zone string, o } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsZonesOperationsCancelCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesOperationsCancelCall) Context(ctx context.Context) *ProjectsZonesOperationsCancelCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesOperationsCancelCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -20484,18 +15218,12 @@ func (c *ProjectsZonesOperationsCancelCall) Header() http.Header { } func (c *ProjectsZonesOperationsCancelCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/projects/{projectId}/zones/{zone}/operations/{operationId}:cancel") @@ -20514,12 +15242,10 @@ func (c *ProjectsZonesOperationsCancelCall) doRequest(alt string) (*http.Respons } // Do executes the "container.projects.zones.operations.cancel" call. -// Exactly one of *Empty or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Empty.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -20550,51 +15276,7 @@ func (c *ProjectsZonesOperationsCancelCall) Do(opts ...googleapi.CallOption) (*E return nil, err } return ret, nil - // { - // "description": "Cancels the specified operation.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/operations/{operationId}:cancel", - // "httpMethod": "POST", - // "id": "container.projects.zones.operations.cancel", - // "parameterOrder": [ - // "projectId", - // "zone", - // "operationId" - // ], - // "parameters": { - // "operationId": { - // "description": "Required. Deprecated. The server-assigned `name` of the operation. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the operation resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/operations/{operationId}:cancel", - // "request": { - // "$ref": "CancelOperationRequest" - // }, - // "response": { - // "$ref": "Empty" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.operations.get": +} type ProjectsZonesOperationsGetCall struct { s *Service @@ -20609,17 +15291,16 @@ type ProjectsZonesOperationsGetCall struct { // Get: Gets the specified operation. // -// - operationId: Deprecated. The server-assigned `name` of the -// operation. This field has been deprecated and replaced by the name -// field. -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - operationId: Deprecated. The server-assigned `name` of the operation. This +// field has been deprecated and replaced by the name field. +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the name field. // - zone: Deprecated. The name of the Google Compute Engine zone -// (https://cloud.google.com/compute/docs/zones#available) in which -// the cluster resides. This field has been deprecated and replaced by -// the name field. +// (https://cloud.google.com/compute/docs/zones#available) in which the +// cluster resides. This field has been deprecated and replaced by the name +// field. func (r *ProjectsZonesOperationsService) Get(projectId string, zone string, operationId string) *ProjectsZonesOperationsGetCall { c := &ProjectsZonesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -20637,33 +15318,29 @@ func (c *ProjectsZonesOperationsGetCall) Name(name string) *ProjectsZonesOperati } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsZonesOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsZonesOperationsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesOperationsGetCall) Context(ctx context.Context) *ProjectsZonesOperationsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -20672,12 +15349,7 @@ func (c *ProjectsZonesOperationsGetCall) Header() http.Header { } func (c *ProjectsZonesOperationsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -20700,12 +15372,10 @@ func (c *ProjectsZonesOperationsGetCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.operations.get" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Operation.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsZonesOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -20736,53 +15406,7 @@ func (c *ProjectsZonesOperationsGetCall) Do(opts ...googleapi.CallOption) (*Oper return nil, err } return ret, nil - // { - // "description": "Gets the specified operation.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/operations/{operationId}", - // "httpMethod": "GET", - // "id": "container.projects.zones.operations.get", - // "parameterOrder": [ - // "projectId", - // "zone", - // "operationId" - // ], - // "parameters": { - // "name": { - // "description": "The name (project, location, operation id) of the operation to get. Specified in the format `projects/*/locations/*/operations/*`.", - // "location": "query", - // "type": "string" - // }, - // "operationId": { - // "description": "Required. Deprecated. The server-assigned `name` of the operation. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/operations/{operationId}", - // "response": { - // "$ref": "Operation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// method id "container.projects.zones.operations.list": +} type ProjectsZonesOperationsListCall struct { s *Service @@ -20794,17 +15418,16 @@ type ProjectsZonesOperationsListCall struct { header_ http.Header } -// List: Lists all operations in a project in the specified zone or all -// zones. +// List: Lists all operations in a project in the specified zone or all zones. // -// - projectId: Deprecated. The Google Developers Console project ID or -// project number +// - projectId: Deprecated. The Google Developers Console project ID or project +// number // (https://cloud.google.com/resource-manager/docs/creating-managing-projects). // This field has been deprecated and replaced by the parent field. // - zone: Deprecated. The name of the Google Compute Engine zone // (https://cloud.google.com/compute/docs/zones#available) to return -// operations for, or `-` for all zones. This field has been -// deprecated and replaced by the parent field. +// operations for, or `-` for all zones. This field has been deprecated and +// replaced by the parent field. func (r *ProjectsZonesOperationsService) List(projectId string, zone string) *ProjectsZonesOperationsListCall { c := &ProjectsZonesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -20813,42 +15436,37 @@ func (r *ProjectsZonesOperationsService) List(projectId string, zone string) *Pr } // Parent sets the optional parameter "parent": The parent (project and -// location) where the operations will be listed. Specified in the -// format `projects/*/locations/*`. Location "-" matches all zones and -// all regions. +// location) where the operations will be listed. Specified in the format +// `projects/*/locations/*`. Location "-" matches all zones and all regions. func (c *ProjectsZonesOperationsListCall) Parent(parent string) *ProjectsZonesOperationsListCall { c.urlParams_.Set("parent", parent) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsZonesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsZonesOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsZonesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsZonesOperationsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsZonesOperationsListCall) Context(ctx context.Context) *ProjectsZonesOperationsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsZonesOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -20857,12 +15475,7 @@ func (c *ProjectsZonesOperationsListCall) Header() http.Header { } func (c *ProjectsZonesOperationsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -20884,12 +15497,11 @@ func (c *ProjectsZonesOperationsListCall) doRequest(alt string) (*http.Response, } // Do executes the "container.projects.zones.operations.list" call. -// Exactly one of *ListOperationsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListOperationsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ListOperationsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsZonesOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -20920,41 +15532,4 @@ func (c *ProjectsZonesOperationsListCall) Do(opts ...googleapi.CallOption) (*Lis return nil, err } return ret, nil - // { - // "description": "Lists all operations in a project in the specified zone or all zones.", - // "flatPath": "v1beta1/projects/{projectId}/zones/{zone}/operations", - // "httpMethod": "GET", - // "id": "container.projects.zones.operations.list", - // "parameterOrder": [ - // "projectId", - // "zone" - // ], - // "parameters": { - // "parent": { - // "description": "The parent (project and location) where the operations will be listed. Specified in the format `projects/*/locations/*`. Location \"-\" matches all zones and all regions.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Required. Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "zone": { - // "description": "Required. Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) to return operations for, or `-` for all zones. This field has been deprecated and replaced by the parent field.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta1/projects/{projectId}/zones/{zone}/operations", - // "response": { - // "$ref": "ListOperationsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - } diff --git a/vendor/google.golang.org/api/iamcredentials/v1/iamcredentials-gen.go b/vendor/google.golang.org/api/iamcredentials/v1/iamcredentials-gen.go index 947e83a5b5..4316aab702 100644 --- a/vendor/google.golang.org/api/iamcredentials/v1/iamcredentials-gen.go +++ b/vendor/google.golang.org/api/iamcredentials/v1/iamcredentials-gen.go @@ -96,8 +96,8 @@ const defaultUniverseDomain = "googleapis.com" // OAuth2 scopes used by this API. const ( - // See, edit, configure, and delete your Google Cloud data and see the - // email address for your Google Account. + // See, edit, configure, and delete your Google Cloud data and see the email + // address for your Google Account. CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" ) @@ -177,354 +177,276 @@ type ProjectsServiceAccountsService struct { } type GenerateAccessTokenRequest struct { - // Delegates: The sequence of service accounts in a delegation chain. - // This field is required for delegated requests - // (https://cloud.google.com/iam/help/credentials/delegated-request). - // For direct requests - // (https://cloud.google.com/iam/help/credentials/direct-request), which - // are more common, do not specify this field. Each service account must - // be granted the `roles/iam.serviceAccountTokenCreator` role on its - // next service account in the chain. The last service account in the - // chain must be granted the `roles/iam.serviceAccountTokenCreator` role - // on the service account that is specified in the `name` field of the - // request. The delegates must have the following format: - // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` - // wildcard character is required; replacing it with a project ID is + // Delegates: The sequence of service accounts in a delegation chain. This + // field is required for delegated requests + // (https://cloud.google.com/iam/help/credentials/delegated-request). For + // direct requests + // (https://cloud.google.com/iam/help/credentials/direct-request), which are + // more common, do not specify this field. Each service account must be granted + // the `roles/iam.serviceAccountTokenCreator` role on its next service account + // in the chain. The last service account in the chain must be granted the + // `roles/iam.serviceAccountTokenCreator` role on the service account that is + // specified in the `name` field of the request. The delegates must have the + // following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. + // The `-` wildcard character is required; replacing it with a project ID is // invalid. Delegates []string `json:"delegates,omitempty"` - - // Lifetime: The desired lifetime duration of the access token in - // seconds. By default, the maximum allowed value is 1 hour. To set a - // lifetime of up to 12 hours, you can add the service account as an - // allowed value in an Organization Policy that enforces the - // `constraints/iam.allowServiceAccountCredentialLifetimeExtension` - // constraint. See detailed instructions at - // https://cloud.google.com/iam/help/credentials/lifetime If a value is - // not specified, the token's lifetime will be set to a default value of - // 1 hour. + // Lifetime: The desired lifetime duration of the access token in seconds. By + // default, the maximum allowed value is 1 hour. To set a lifetime of up to 12 + // hours, you can add the service account as an allowed value in an + // Organization Policy that enforces the + // `constraints/iam.allowServiceAccountCredentialLifetimeExtension` constraint. + // See detailed instructions at + // https://cloud.google.com/iam/help/credentials/lifetime If a value is not + // specified, the token's lifetime will be set to a default value of 1 hour. Lifetime string `json:"lifetime,omitempty"` - - // Scope: Required. Code to identify the scopes to be included in the - // OAuth 2.0 access token. See - // https://developers.google.com/identity/protocols/googlescopes for - // more information. At least one value required. + // Scope: Required. Code to identify the scopes to be included in the OAuth 2.0 + // access token. See + // https://developers.google.com/identity/protocols/googlescopes for more + // information. At least one value required. Scope []string `json:"scope,omitempty"` - // ForceSendFields is a list of field names (e.g. "Delegates") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Delegates") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Delegates") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GenerateAccessTokenRequest) MarshalJSON() ([]byte, error) { type NoMethod GenerateAccessTokenRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type GenerateAccessTokenResponse struct { // AccessToken: The OAuth 2.0 access token. AccessToken string `json:"accessToken,omitempty"` - // ExpireTime: Token expiration time. The expiration time is always set. ExpireTime string `json:"expireTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AccessToken") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AccessToken") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AccessToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GenerateAccessTokenResponse) MarshalJSON() ([]byte, error) { type NoMethod GenerateAccessTokenResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type GenerateIdTokenRequest struct { - // Audience: Required. The audience for the token, such as the API or - // account that this token grants access to. + // Audience: Required. The audience for the token, such as the API or account + // that this token grants access to. Audience string `json:"audience,omitempty"` - - // Delegates: The sequence of service accounts in a delegation chain. - // Each service account must be granted the - // `roles/iam.serviceAccountTokenCreator` role on its next service - // account in the chain. The last service account in the chain must be - // granted the `roles/iam.serviceAccountTokenCreator` role on the - // service account that is specified in the `name` field of the request. + // Delegates: The sequence of service accounts in a delegation chain. Each + // service account must be granted the `roles/iam.serviceAccountTokenCreator` + // role on its next service account in the chain. The last service account in + // the chain must be granted the `roles/iam.serviceAccountTokenCreator` role on + // the service account that is specified in the `name` field of the request. // The delegates must have the following format: - // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` - // wildcard character is required; replacing it with a project ID is - // invalid. + // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard + // character is required; replacing it with a project ID is invalid. Delegates []string `json:"delegates,omitempty"` - - // IncludeEmail: Include the service account email in the token. If set - // to `true`, the token will contain `email` and `email_verified` - // claims. + // IncludeEmail: Include the service account email in the token. If set to + // `true`, the token will contain `email` and `email_verified` claims. IncludeEmail bool `json:"includeEmail,omitempty"` - // ForceSendFields is a list of field names (e.g. "Audience") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Audience") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Audience") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GenerateIdTokenRequest) MarshalJSON() ([]byte, error) { type NoMethod GenerateIdTokenRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type GenerateIdTokenResponse struct { // Token: The OpenId Connect ID token. Token string `json:"token,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Token") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Token") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Token") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GenerateIdTokenResponse) MarshalJSON() ([]byte, error) { type NoMethod GenerateIdTokenResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type SignBlobRequest struct { - // Delegates: The sequence of service accounts in a delegation chain. - // Each service account must be granted the - // `roles/iam.serviceAccountTokenCreator` role on its next service - // account in the chain. The last service account in the chain must be - // granted the `roles/iam.serviceAccountTokenCreator` role on the - // service account that is specified in the `name` field of the request. + // Delegates: The sequence of service accounts in a delegation chain. Each + // service account must be granted the `roles/iam.serviceAccountTokenCreator` + // role on its next service account in the chain. The last service account in + // the chain must be granted the `roles/iam.serviceAccountTokenCreator` role on + // the service account that is specified in the `name` field of the request. // The delegates must have the following format: - // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` - // wildcard character is required; replacing it with a project ID is - // invalid. + // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard + // character is required; replacing it with a project ID is invalid. Delegates []string `json:"delegates,omitempty"` - // Payload: Required. The bytes to sign. Payload string `json:"payload,omitempty"` - // ForceSendFields is a list of field names (e.g. "Delegates") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Delegates") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Delegates") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SignBlobRequest) MarshalJSON() ([]byte, error) { type NoMethod SignBlobRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type SignBlobResponse struct { - // KeyId: The ID of the key used to sign the blob. The key used for - // signing will remain valid for at least 12 hours after the blob is - // signed. To verify the signature, you can retrieve the public key in - // several formats from the following endpoints: - RSA public key - // wrapped in an X.509 v3 certificate: - // `https://www.googleapis.com/service_accounts/v1/metadata/x509/{ACCOUNT - // _EMAIL}` - Raw key in JSON format: - // `https://www.googleapis.com/service_accounts/v1/metadata/raw/{ACCOUNT_ - // EMAIL}` - JSON Web Key (JWK): - // `https://www.googleapis.com/service_accounts/v1/metadata/jwk/{ACCOUNT_ - // EMAIL}` + // KeyId: The ID of the key used to sign the blob. The key used for signing + // will remain valid for at least 12 hours after the blob is signed. To verify + // the signature, you can retrieve the public key in several formats from the + // following endpoints: - RSA public key wrapped in an X.509 v3 certificate: + // `https://www.googleapis.com/service_accounts/v1/metadata/x509/{ACCOUNT_EMAIL} + // ` - Raw key in JSON format: + // `https://www.googleapis.com/service_accounts/v1/metadata/raw/{ACCOUNT_EMAIL}` + // - JSON Web Key (JWK): + // `https://www.googleapis.com/service_accounts/v1/metadata/jwk/{ACCOUNT_EMAIL}` KeyId string `json:"keyId,omitempty"` - - // SignedBlob: The signature for the blob. Does not include the original - // blob. After the key pair referenced by the `key_id` response field - // expires, Google no longer exposes the public key that can be used to - // verify the blob. As a result, the receiver can no longer verify the - // signature. + // SignedBlob: The signature for the blob. Does not include the original blob. + // After the key pair referenced by the `key_id` response field expires, Google + // no longer exposes the public key that can be used to verify the blob. As a + // result, the receiver can no longer verify the signature. SignedBlob string `json:"signedBlob,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "KeyId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "KeyId") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "KeyId") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SignBlobResponse) MarshalJSON() ([]byte, error) { type NoMethod SignBlobResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type SignJwtRequest struct { - // Delegates: The sequence of service accounts in a delegation chain. - // Each service account must be granted the - // `roles/iam.serviceAccountTokenCreator` role on its next service - // account in the chain. The last service account in the chain must be - // granted the `roles/iam.serviceAccountTokenCreator` role on the - // service account that is specified in the `name` field of the request. + // Delegates: The sequence of service accounts in a delegation chain. Each + // service account must be granted the `roles/iam.serviceAccountTokenCreator` + // role on its next service account in the chain. The last service account in + // the chain must be granted the `roles/iam.serviceAccountTokenCreator` role on + // the service account that is specified in the `name` field of the request. // The delegates must have the following format: - // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` - // wildcard character is required; replacing it with a project ID is - // invalid. + // `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard + // character is required; replacing it with a project ID is invalid. Delegates []string `json:"delegates,omitempty"` - - // Payload: Required. The JWT payload to sign. Must be a serialized JSON - // object that contains a JWT Claims Set. For example: `{"sub": - // "user@example.com", "iat": 313435}` If the JWT Claims Set contains an - // expiration time (`exp`) claim, it must be an integer timestamp that - // is not in the past and no more than 12 hours in the future. + // Payload: Required. The JWT payload to sign. Must be a serialized JSON object + // that contains a JWT Claims Set. For example: `{"sub": "user@example.com", + // "iat": 313435}` If the JWT Claims Set contains an expiration time (`exp`) + // claim, it must be an integer timestamp that is not in the past and no more + // than 12 hours in the future. Payload string `json:"payload,omitempty"` - // ForceSendFields is a list of field names (e.g. "Delegates") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Delegates") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Delegates") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SignJwtRequest) MarshalJSON() ([]byte, error) { type NoMethod SignJwtRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type SignJwtResponse struct { - // KeyId: The ID of the key used to sign the JWT. The key used for - // signing will remain valid for at least 12 hours after the JWT is - // signed. To verify the signature, you can retrieve the public key in - // several formats from the following endpoints: - RSA public key - // wrapped in an X.509 v3 certificate: - // `https://www.googleapis.com/service_accounts/v1/metadata/x509/{ACCOUNT - // _EMAIL}` - Raw key in JSON format: - // `https://www.googleapis.com/service_accounts/v1/metadata/raw/{ACCOUNT_ - // EMAIL}` - JSON Web Key (JWK): - // `https://www.googleapis.com/service_accounts/v1/metadata/jwk/{ACCOUNT_ - // EMAIL}` + // KeyId: The ID of the key used to sign the JWT. The key used for signing will + // remain valid for at least 12 hours after the JWT is signed. To verify the + // signature, you can retrieve the public key in several formats from the + // following endpoints: - RSA public key wrapped in an X.509 v3 certificate: + // `https://www.googleapis.com/service_accounts/v1/metadata/x509/{ACCOUNT_EMAIL} + // ` - Raw key in JSON format: + // `https://www.googleapis.com/service_accounts/v1/metadata/raw/{ACCOUNT_EMAIL}` + // - JSON Web Key (JWK): + // `https://www.googleapis.com/service_accounts/v1/metadata/jwk/{ACCOUNT_EMAIL}` KeyId string `json:"keyId,omitempty"` - - // SignedJwt: The signed JWT. Contains the automatically generated - // header; the client-supplied payload; and the signature, which is - // generated using the key referenced by the `kid` field in the header. - // After the key pair referenced by the `key_id` response field expires, - // Google no longer exposes the public key that can be used to verify - // the JWT. As a result, the receiver can no longer verify the - // signature. + // SignedJwt: The signed JWT. Contains the automatically generated header; the + // client-supplied payload; and the signature, which is generated using the key + // referenced by the `kid` field in the header. After the key pair referenced + // by the `key_id` response field expires, Google no longer exposes the public + // key that can be used to verify the JWT. As a result, the receiver can no + // longer verify the signature. SignedJwt string `json:"signedJwt,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "KeyId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "KeyId") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "KeyId") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *SignJwtResponse) MarshalJSON() ([]byte, error) { type NoMethod SignJwtResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// method id "iamcredentials.projects.serviceAccounts.generateAccessToken": - type ProjectsServiceAccountsGenerateAccessTokenCall struct { s *Service name string @@ -534,14 +456,13 @@ type ProjectsServiceAccountsGenerateAccessTokenCall struct { header_ http.Header } -// GenerateAccessToken: Generates an OAuth 2.0 access token for a -// service account. +// GenerateAccessToken: Generates an OAuth 2.0 access token for a service +// account. // -// - name: The resource name of the service account for which the -// credentials are requested, in the following format: -// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` -// wildcard character is required; replacing it with a project ID is -// invalid. +// - name: The resource name of the service account for which the credentials +// are requested, in the following format: +// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard +// character is required; replacing it with a project ID is invalid. func (r *ProjectsServiceAccountsService) GenerateAccessToken(name string, generateaccesstokenrequest *GenerateAccessTokenRequest) *ProjectsServiceAccountsGenerateAccessTokenCall { c := &ProjectsServiceAccountsGenerateAccessTokenCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -550,23 +471,21 @@ func (r *ProjectsServiceAccountsService) GenerateAccessToken(name string, genera } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsServiceAccountsGenerateAccessTokenCall) Fields(s ...googleapi.Field) *ProjectsServiceAccountsGenerateAccessTokenCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsServiceAccountsGenerateAccessTokenCall) Context(ctx context.Context) *ProjectsServiceAccountsGenerateAccessTokenCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsServiceAccountsGenerateAccessTokenCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -575,18 +494,12 @@ func (c *ProjectsServiceAccountsGenerateAccessTokenCall) Header() http.Header { } func (c *ProjectsServiceAccountsGenerateAccessTokenCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.generateaccesstokenrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:generateAccessToken") @@ -603,12 +516,11 @@ func (c *ProjectsServiceAccountsGenerateAccessTokenCall) doRequest(alt string) ( } // Do executes the "iamcredentials.projects.serviceAccounts.generateAccessToken" call. -// Exactly one of *GenerateAccessTokenResponse or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *GenerateAccessTokenResponse.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *GenerateAccessTokenResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ProjectsServiceAccountsGenerateAccessTokenCall) Do(opts ...googleapi.CallOption) (*GenerateAccessTokenResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -639,39 +551,8 @@ func (c *ProjectsServiceAccountsGenerateAccessTokenCall) Do(opts ...googleapi.Ca return nil, err } return ret, nil - // { - // "description": "Generates an OAuth 2.0 access token for a service account.", - // "flatPath": "v1/projects/{projectsId}/serviceAccounts/{serviceAccountsId}:generateAccessToken", - // "httpMethod": "POST", - // "id": "iamcredentials.projects.serviceAccounts.generateAccessToken", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "Required. The resource name of the service account for which the credentials are requested, in the following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard character is required; replacing it with a project ID is invalid.", - // "location": "path", - // "pattern": "^projects/[^/]+/serviceAccounts/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1/{+name}:generateAccessToken", - // "request": { - // "$ref": "GenerateAccessTokenRequest" - // }, - // "response": { - // "$ref": "GenerateAccessTokenResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - } -// method id "iamcredentials.projects.serviceAccounts.generateIdToken": - type ProjectsServiceAccountsGenerateIdTokenCall struct { s *Service name string @@ -681,14 +562,12 @@ type ProjectsServiceAccountsGenerateIdTokenCall struct { header_ http.Header } -// GenerateIdToken: Generates an OpenID Connect ID token for a service -// account. +// GenerateIdToken: Generates an OpenID Connect ID token for a service account. // -// - name: The resource name of the service account for which the -// credentials are requested, in the following format: -// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` -// wildcard character is required; replacing it with a project ID is -// invalid. +// - name: The resource name of the service account for which the credentials +// are requested, in the following format: +// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard +// character is required; replacing it with a project ID is invalid. func (r *ProjectsServiceAccountsService) GenerateIdToken(name string, generateidtokenrequest *GenerateIdTokenRequest) *ProjectsServiceAccountsGenerateIdTokenCall { c := &ProjectsServiceAccountsGenerateIdTokenCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -697,23 +576,21 @@ func (r *ProjectsServiceAccountsService) GenerateIdToken(name string, generateid } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsServiceAccountsGenerateIdTokenCall) Fields(s ...googleapi.Field) *ProjectsServiceAccountsGenerateIdTokenCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsServiceAccountsGenerateIdTokenCall) Context(ctx context.Context) *ProjectsServiceAccountsGenerateIdTokenCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsServiceAccountsGenerateIdTokenCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -722,18 +599,12 @@ func (c *ProjectsServiceAccountsGenerateIdTokenCall) Header() http.Header { } func (c *ProjectsServiceAccountsGenerateIdTokenCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.generateidtokenrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:generateIdToken") @@ -750,12 +621,11 @@ func (c *ProjectsServiceAccountsGenerateIdTokenCall) doRequest(alt string) (*htt } // Do executes the "iamcredentials.projects.serviceAccounts.generateIdToken" call. -// Exactly one of *GenerateIdTokenResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either +// Any non-2xx status code is an error. Response headers are in either // *GenerateIdTokenResponse.ServerResponse.Header or (if a response was // returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ProjectsServiceAccountsGenerateIdTokenCall) Do(opts ...googleapi.CallOption) (*GenerateIdTokenResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -786,39 +656,8 @@ func (c *ProjectsServiceAccountsGenerateIdTokenCall) Do(opts ...googleapi.CallOp return nil, err } return ret, nil - // { - // "description": "Generates an OpenID Connect ID token for a service account.", - // "flatPath": "v1/projects/{projectsId}/serviceAccounts/{serviceAccountsId}:generateIdToken", - // "httpMethod": "POST", - // "id": "iamcredentials.projects.serviceAccounts.generateIdToken", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "Required. The resource name of the service account for which the credentials are requested, in the following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard character is required; replacing it with a project ID is invalid.", - // "location": "path", - // "pattern": "^projects/[^/]+/serviceAccounts/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1/{+name}:generateIdToken", - // "request": { - // "$ref": "GenerateIdTokenRequest" - // }, - // "response": { - // "$ref": "GenerateIdTokenResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - } -// method id "iamcredentials.projects.serviceAccounts.signBlob": - type ProjectsServiceAccountsSignBlobCall struct { s *Service name string @@ -828,14 +667,12 @@ type ProjectsServiceAccountsSignBlobCall struct { header_ http.Header } -// SignBlob: Signs a blob using a service account's system-managed -// private key. +// SignBlob: Signs a blob using a service account's system-managed private key. // -// - name: The resource name of the service account for which the -// credentials are requested, in the following format: -// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` -// wildcard character is required; replacing it with a project ID is -// invalid. +// - name: The resource name of the service account for which the credentials +// are requested, in the following format: +// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard +// character is required; replacing it with a project ID is invalid. func (r *ProjectsServiceAccountsService) SignBlob(name string, signblobrequest *SignBlobRequest) *ProjectsServiceAccountsSignBlobCall { c := &ProjectsServiceAccountsSignBlobCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -844,23 +681,21 @@ func (r *ProjectsServiceAccountsService) SignBlob(name string, signblobrequest * } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsServiceAccountsSignBlobCall) Fields(s ...googleapi.Field) *ProjectsServiceAccountsSignBlobCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsServiceAccountsSignBlobCall) Context(ctx context.Context) *ProjectsServiceAccountsSignBlobCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsServiceAccountsSignBlobCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -869,18 +704,12 @@ func (c *ProjectsServiceAccountsSignBlobCall) Header() http.Header { } func (c *ProjectsServiceAccountsSignBlobCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.signblobrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:signBlob") @@ -897,12 +726,11 @@ func (c *ProjectsServiceAccountsSignBlobCall) doRequest(alt string) (*http.Respo } // Do executes the "iamcredentials.projects.serviceAccounts.signBlob" call. -// Exactly one of *SignBlobResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *SignBlobResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *SignBlobResponse.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsServiceAccountsSignBlobCall) Do(opts ...googleapi.CallOption) (*SignBlobResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -933,39 +761,8 @@ func (c *ProjectsServiceAccountsSignBlobCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Signs a blob using a service account's system-managed private key.", - // "flatPath": "v1/projects/{projectsId}/serviceAccounts/{serviceAccountsId}:signBlob", - // "httpMethod": "POST", - // "id": "iamcredentials.projects.serviceAccounts.signBlob", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "Required. The resource name of the service account for which the credentials are requested, in the following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard character is required; replacing it with a project ID is invalid.", - // "location": "path", - // "pattern": "^projects/[^/]+/serviceAccounts/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1/{+name}:signBlob", - // "request": { - // "$ref": "SignBlobRequest" - // }, - // "response": { - // "$ref": "SignBlobResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - } -// method id "iamcredentials.projects.serviceAccounts.signJwt": - type ProjectsServiceAccountsSignJwtCall struct { s *Service name string @@ -975,14 +772,12 @@ type ProjectsServiceAccountsSignJwtCall struct { header_ http.Header } -// SignJwt: Signs a JWT using a service account's system-managed private -// key. +// SignJwt: Signs a JWT using a service account's system-managed private key. // -// - name: The resource name of the service account for which the -// credentials are requested, in the following format: -// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` -// wildcard character is required; replacing it with a project ID is -// invalid. +// - name: The resource name of the service account for which the credentials +// are requested, in the following format: +// `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard +// character is required; replacing it with a project ID is invalid. func (r *ProjectsServiceAccountsService) SignJwt(name string, signjwtrequest *SignJwtRequest) *ProjectsServiceAccountsSignJwtCall { c := &ProjectsServiceAccountsSignJwtCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -991,23 +786,21 @@ func (r *ProjectsServiceAccountsService) SignJwt(name string, signjwtrequest *Si } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsServiceAccountsSignJwtCall) Fields(s ...googleapi.Field) *ProjectsServiceAccountsSignJwtCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsServiceAccountsSignJwtCall) Context(ctx context.Context) *ProjectsServiceAccountsSignJwtCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsServiceAccountsSignJwtCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -1016,18 +809,12 @@ func (c *ProjectsServiceAccountsSignJwtCall) Header() http.Header { } func (c *ProjectsServiceAccountsSignJwtCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.signjwtrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:signJwt") @@ -1044,12 +831,11 @@ func (c *ProjectsServiceAccountsSignJwtCall) doRequest(alt string) (*http.Respon } // Do executes the "iamcredentials.projects.serviceAccounts.signJwt" call. -// Exactly one of *SignJwtResponse or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *SignJwtResponse.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *SignJwtResponse.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsServiceAccountsSignJwtCall) Do(opts ...googleapi.CallOption) (*SignJwtResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -1080,33 +866,4 @@ func (c *ProjectsServiceAccountsSignJwtCall) Do(opts ...googleapi.CallOption) (* return nil, err } return ret, nil - // { - // "description": "Signs a JWT using a service account's system-managed private key.", - // "flatPath": "v1/projects/{projectsId}/serviceAccounts/{serviceAccountsId}:signJwt", - // "httpMethod": "POST", - // "id": "iamcredentials.projects.serviceAccounts.signJwt", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "name": { - // "description": "Required. The resource name of the service account for which the credentials are requested, in the following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard character is required; replacing it with a project ID is invalid.", - // "location": "path", - // "pattern": "^projects/[^/]+/serviceAccounts/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1/{+name}:signJwt", - // "request": { - // "$ref": "SignJwtRequest" - // }, - // "response": { - // "$ref": "SignJwtResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - } diff --git a/vendor/google.golang.org/api/internal/gensupport/params.go b/vendor/google.golang.org/api/internal/gensupport/params.go index 1a30d2ca25..3f4074c819 100644 --- a/vendor/google.golang.org/api/internal/gensupport/params.go +++ b/vendor/google.golang.org/api/internal/gensupport/params.go @@ -5,9 +5,11 @@ package gensupport import ( + "net/http" "net/url" "google.golang.org/api/googleapi" + "google.golang.org/api/internal" ) // URLParams is a simplified replacement for url.Values @@ -55,3 +57,17 @@ func SetOptions(u URLParams, opts ...googleapi.CallOption) { u.Set(o.Get()) } } + +// SetHeaders sets common headers for all requests. +func SetHeaders(userAgent, contentType string, userHeaders http.Header) http.Header { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+GoVersion()+" gdcl/"+internal.Version) + reqHeaders.Set("User-Agent", userAgent) + if contentType != "" { + reqHeaders.Set("Content-Type", contentType) + } + for k, v := range userHeaders { + reqHeaders[k] = v + } + return reqHeaders +} diff --git a/vendor/google.golang.org/api/internal/version.go b/vendor/google.golang.org/api/internal/version.go index 18546fcd95..6a47694eae 100644 --- a/vendor/google.golang.org/api/internal/version.go +++ b/vendor/google.golang.org/api/internal/version.go @@ -5,4 +5,4 @@ package internal // Version is the current tagged release of the library. -const Version = "0.176.1" +const Version = "0.177.0" diff --git a/vendor/google.golang.org/api/storage/v1/storage-gen.go b/vendor/google.golang.org/api/storage/v1/storage-gen.go index a3f17e5c6f..70a7458e3f 100644 --- a/vendor/google.golang.org/api/storage/v1/storage-gen.go +++ b/vendor/google.golang.org/api/storage/v1/storage-gen.go @@ -347,462 +347,344 @@ type ProjectsServiceAccountService struct { type AnywhereCache struct { // AdmissionPolicy: The cache-level entry admission policy. AdmissionPolicy string `json:"admissionPolicy,omitempty"` - // AnywhereCacheId: The ID of the Anywhere cache instance. AnywhereCacheId string `json:"anywhereCacheId,omitempty"` - // Bucket: The name of the bucket containing this cache instance. Bucket string `json:"bucket,omitempty"` - - // CreateTime: The creation time of the cache instance in RFC 3339 - // format. + // CreateTime: The creation time of the cache instance in RFC 3339 format. CreateTime string `json:"createTime,omitempty"` - - // Id: The ID of the resource, including the project number, bucket name - // and anywhere cache ID. + // Id: The ID of the resource, including the project number, bucket name and + // anywhere cache ID. Id string `json:"id,omitempty"` - // Kind: The kind of item this is. For Anywhere Cache, this is always // storage#anywhereCache. Kind string `json:"kind,omitempty"` - - // PendingUpdate: True if the cache instance has an active Update - // long-running operation. + // PendingUpdate: True if the cache instance has an active Update long-running + // operation. PendingUpdate bool `json:"pendingUpdate,omitempty"` - // SelfLink: The link to this cache instance. SelfLink string `json:"selfLink,omitempty"` - // State: The current state of the cache instance. State string `json:"state,omitempty"` - // Ttl: The TTL of all cache entries in whole seconds. e.g., "7200s". Ttl string `json:"ttl,omitempty"` - - // UpdateTime: The modification time of the cache instance metadata in - // RFC 3339 format. + // UpdateTime: The modification time of the cache instance metadata in RFC 3339 + // format. UpdateTime string `json:"updateTime,omitempty"` - // Zone: The zone in which the cache instance is running. For example, // us-central1-a. Zone string `json:"zone,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AdmissionPolicy") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AdmissionPolicy") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AdmissionPolicy") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AnywhereCache) MarshalJSON() ([]byte, error) { type NoMethod AnywhereCache - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // AnywhereCaches: A list of Anywhere Caches. type AnywhereCaches struct { // Items: The list of items. Items []*AnywhereCache `json:"items,omitempty"` - - // Kind: The kind of item this is. For lists of Anywhere Caches, this is - // always storage#anywhereCaches. + // Kind: The kind of item this is. For lists of Anywhere Caches, this is always + // storage#anywhereCaches. Kind string `json:"kind,omitempty"` - - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *AnywhereCaches) MarshalJSON() ([]byte, error) { type NoMethod AnywhereCaches - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Bucket: A bucket. type Bucket struct { // Acl: Access controls on the bucket. Acl []*BucketAccessControl `json:"acl,omitempty"` - // Autoclass: The bucket's Autoclass configuration. Autoclass *BucketAutoclass `json:"autoclass,omitempty"` - // Billing: The bucket's billing configuration. Billing *BucketBilling `json:"billing,omitempty"` - - // Cors: The bucket's Cross-Origin Resource Sharing (CORS) - // configuration. + // Cors: The bucket's Cross-Origin Resource Sharing (CORS) configuration. Cors []*BucketCors `json:"cors,omitempty"` - - // CustomPlacementConfig: The bucket's custom placement configuration - // for Custom Dual Regions. + // CustomPlacementConfig: The bucket's custom placement configuration for + // Custom Dual Regions. CustomPlacementConfig *BucketCustomPlacementConfig `json:"customPlacementConfig,omitempty"` - - // DefaultEventBasedHold: The default value for event-based hold on - // newly created objects in this bucket. Event-based hold is a way to - // retain objects indefinitely until an event occurs, signified by the - // hold's release. After being released, such objects will be subject to - // bucket-level retention (if any). One sample use case of this flag is - // for banks to hold loan documents for at least 3 years after loan is - // paid in full. Here, bucket-level retention is 3 years and the event - // is loan being paid in full. In this example, these objects will be - // held intact for any number of years until the event has occurred - // (event-based hold on the object is released) and then 3 more years - // after that. That means retention duration of the objects begins from - // the moment event-based hold transitioned from true to false. Objects - // under event-based hold cannot be deleted, overwritten or archived - // until the hold is removed. + // DefaultEventBasedHold: The default value for event-based hold on newly + // created objects in this bucket. Event-based hold is a way to retain objects + // indefinitely until an event occurs, signified by the hold's release. After + // being released, such objects will be subject to bucket-level retention (if + // any). One sample use case of this flag is for banks to hold loan documents + // for at least 3 years after loan is paid in full. Here, bucket-level + // retention is 3 years and the event is loan being paid in full. In this + // example, these objects will be held intact for any number of years until the + // event has occurred (event-based hold on the object is released) and then 3 + // more years after that. That means retention duration of the objects begins + // from the moment event-based hold transitioned from true to false. Objects + // under event-based hold cannot be deleted, overwritten or archived until the + // hold is removed. DefaultEventBasedHold bool `json:"defaultEventBasedHold,omitempty"` - - // DefaultObjectAcl: Default access controls to apply to new objects - // when no ACL is provided. + // DefaultObjectAcl: Default access controls to apply to new objects when no + // ACL is provided. DefaultObjectAcl []*ObjectAccessControl `json:"defaultObjectAcl,omitempty"` - // Encryption: Encryption configuration for a bucket. Encryption *BucketEncryption `json:"encryption,omitempty"` - // Etag: HTTP 1.1 Entity tag for the bucket. Etag string `json:"etag,omitempty"` - - // HierarchicalNamespace: The bucket's hierarchical namespace - // configuration. + // HierarchicalNamespace: The bucket's hierarchical namespace configuration. HierarchicalNamespace *BucketHierarchicalNamespace `json:"hierarchicalNamespace,omitempty"` - // IamConfiguration: The bucket's IAM configuration. IamConfiguration *BucketIamConfiguration `json:"iamConfiguration,omitempty"` - - // Id: The ID of the bucket. For buckets, the id and name properties are - // the same. + // Id: The ID of the bucket. For buckets, the id and name properties are the + // same. Id string `json:"id,omitempty"` - - // Kind: The kind of item this is. For buckets, this is always - // storage#bucket. + // Kind: The kind of item this is. For buckets, this is always storage#bucket. Kind string `json:"kind,omitempty"` - // Labels: User-provided labels, in key/value pairs. Labels map[string]string `json:"labels,omitempty"` - - // Lifecycle: The bucket's lifecycle configuration. See lifecycle - // management for more information. + // Lifecycle: The bucket's lifecycle configuration. See lifecycle management + // for more information. Lifecycle *BucketLifecycle `json:"lifecycle,omitempty"` - - // Location: The location of the bucket. Object data for objects in the - // bucket resides in physical storage within this region. Defaults to - // US. See the developer's guide for the authoritative list. + // Location: The location of the bucket. Object data for objects in the bucket + // resides in physical storage within this region. Defaults to US. See the + // developer's guide for the authoritative list. Location string `json:"location,omitempty"` - // LocationType: The type of the bucket location. LocationType string `json:"locationType,omitempty"` - - // Logging: The bucket's logging configuration, which defines the - // destination bucket and optional name prefix for the current bucket's - // logs. + // Logging: The bucket's logging configuration, which defines the destination + // bucket and optional name prefix for the current bucket's logs. Logging *BucketLogging `json:"logging,omitempty"` - // Metageneration: The metadata generation of this bucket. Metageneration int64 `json:"metageneration,omitempty,string"` - // Name: The name of the bucket. Name string `json:"name,omitempty"` - // ObjectRetention: The bucket's object retention config. ObjectRetention *BucketObjectRetention `json:"objectRetention,omitempty"` - - // Owner: The owner of the bucket. This is always the project team's - // owner group. + // Owner: The owner of the bucket. This is always the project team's owner + // group. Owner *BucketOwner `json:"owner,omitempty"` - - // ProjectNumber: The project number of the project the bucket belongs - // to. + // ProjectNumber: The project number of the project the bucket belongs to. ProjectNumber uint64 `json:"projectNumber,omitempty,string"` - // RetentionPolicy: The bucket's retention policy. The retention policy - // enforces a minimum retention time for all objects contained in the - // bucket, based on their creation time. Any attempt to overwrite or - // delete objects younger than the retention period will result in a - // PERMISSION_DENIED error. An unlocked retention policy can be modified - // or removed from the bucket via a storage.buckets.update operation. A - // locked retention policy cannot be removed or shortened in duration - // for the lifetime of the bucket. Attempting to remove or decrease - // period of a locked retention policy will result in a + // enforces a minimum retention time for all objects contained in the bucket, + // based on their creation time. Any attempt to overwrite or delete objects + // younger than the retention period will result in a PERMISSION_DENIED error. + // An unlocked retention policy can be modified or removed from the bucket via + // a storage.buckets.update operation. A locked retention policy cannot be + // removed or shortened in duration for the lifetime of the bucket. Attempting + // to remove or decrease period of a locked retention policy will result in a // PERMISSION_DENIED error. RetentionPolicy *BucketRetentionPolicy `json:"retentionPolicy,omitempty"` - - // Rpo: The Recovery Point Objective (RPO) of this bucket. Set to - // ASYNC_TURBO to turn on Turbo Replication on a bucket. + // Rpo: The Recovery Point Objective (RPO) of this bucket. Set to ASYNC_TURBO + // to turn on Turbo Replication on a bucket. Rpo string `json:"rpo,omitempty"` - // SatisfiesPZS: Reserved for future use. SatisfiesPZS bool `json:"satisfiesPZS,omitempty"` - // SelfLink: The URI of this bucket. SelfLink string `json:"selfLink,omitempty"` - - // SoftDeletePolicy: The bucket's soft delete policy, which defines the - // period of time that soft-deleted objects will be retained, and cannot - // be permanently deleted. + // SoftDeletePolicy: The bucket's soft delete policy, which defines the period + // of time that soft-deleted objects will be retained, and cannot be + // permanently deleted. SoftDeletePolicy *BucketSoftDeletePolicy `json:"softDeletePolicy,omitempty"` - // StorageClass: The bucket's default storage class, used whenever no - // storageClass is specified for a newly-created object. This defines - // how objects in the bucket are stored and determines the SLA and the - // cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, - // NEARLINE, COLDLINE, ARCHIVE, and DURABLE_REDUCED_AVAILABILITY. If - // this value is not specified when the bucket is created, it will - // default to STANDARD. For more information, see storage classes. + // storageClass is specified for a newly-created object. This defines how + // objects in the bucket are stored and determines the SLA and the cost of + // storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, + // COLDLINE, ARCHIVE, and DURABLE_REDUCED_AVAILABILITY. If this value is not + // specified when the bucket is created, it will default to STANDARD. For more + // information, see storage classes. StorageClass string `json:"storageClass,omitempty"` - // TimeCreated: The creation time of the bucket in RFC 3339 format. TimeCreated string `json:"timeCreated,omitempty"` - // Updated: The modification time of the bucket in RFC 3339 format. Updated string `json:"updated,omitempty"` - // Versioning: The bucket's versioning configuration. Versioning *BucketVersioning `json:"versioning,omitempty"` - - // Website: The bucket's website configuration, controlling how the - // service behaves when accessing bucket contents as a web site. See the - // Static Website Examples for more information. + // Website: The bucket's website configuration, controlling how the service + // behaves when accessing bucket contents as a web site. See the Static Website + // Examples for more information. Website *BucketWebsite `json:"website,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Acl") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Acl") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Acl") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Acl") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Bucket) MarshalJSON() ([]byte, error) { type NoMethod Bucket - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketAutoclass: The bucket's Autoclass configuration. type BucketAutoclass struct { // Enabled: Whether or not Autoclass is enabled on this bucket Enabled bool `json:"enabled,omitempty"` - // TerminalStorageClass: The storage class that objects in the bucket - // eventually transition to if they are not read for a certain length of - // time. Valid values are NEARLINE and ARCHIVE. + // eventually transition to if they are not read for a certain length of time. + // Valid values are NEARLINE and ARCHIVE. TerminalStorageClass string `json:"terminalStorageClass,omitempty"` - // TerminalStorageClassUpdateTime: A date and time in RFC 3339 format - // representing the time of the most recent update to - // "terminalStorageClass". + // representing the time of the most recent update to "terminalStorageClass". TerminalStorageClassUpdateTime string `json:"terminalStorageClassUpdateTime,omitempty"` - - // ToggleTime: A date and time in RFC 3339 format representing the - // instant at which "enabled" was last toggled. + // ToggleTime: A date and time in RFC 3339 format representing the instant at + // which "enabled" was last toggled. ToggleTime string `json:"toggleTime,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketAutoclass) MarshalJSON() ([]byte, error) { type NoMethod BucketAutoclass - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketBilling: The bucket's billing configuration. type BucketBilling struct { - // RequesterPays: When set to true, Requester Pays is enabled for this - // bucket. + // RequesterPays: When set to true, Requester Pays is enabled for this bucket. RequesterPays bool `json:"requesterPays,omitempty"` - // ForceSendFields is a list of field names (e.g. "RequesterPays") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "RequesterPays") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "RequesterPays") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketBilling) MarshalJSON() ([]byte, error) { type NoMethod BucketBilling - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type BucketCors struct { // MaxAgeSeconds: The value, in seconds, to return in the // Access-Control-Max-Age header used in preflight responses. MaxAgeSeconds int64 `json:"maxAgeSeconds,omitempty"` - - // Method: The list of HTTP methods on which to include CORS response - // headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list - // of methods, and means "any method". + // Method: The list of HTTP methods on which to include CORS response headers, + // (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and + // means "any method". Method []string `json:"method,omitempty"` - - // Origin: The list of Origins eligible to receive CORS response - // headers. Note: "*" is permitted in the list of origins, and means - // "any Origin". + // Origin: The list of Origins eligible to receive CORS response headers. Note: + // "*" is permitted in the list of origins, and means "any Origin". Origin []string `json:"origin,omitempty"` - - // ResponseHeader: The list of HTTP headers other than the simple - // response headers to give permission for the user-agent to share - // across domains. + // ResponseHeader: The list of HTTP headers other than the simple response + // headers to give permission for the user-agent to share across domains. ResponseHeader []string `json:"responseHeader,omitempty"` - // ForceSendFields is a list of field names (e.g. "MaxAgeSeconds") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MaxAgeSeconds") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "MaxAgeSeconds") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketCors) MarshalJSON() ([]byte, error) { type NoMethod BucketCors - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketCustomPlacementConfig: The bucket's custom placement -// configuration for Custom Dual Regions. +// BucketCustomPlacementConfig: The bucket's custom placement configuration for +// Custom Dual Regions. type BucketCustomPlacementConfig struct { - // DataLocations: The list of regional locations in which data is - // placed. + // DataLocations: The list of regional locations in which data is placed. DataLocations []string `json:"dataLocations,omitempty"` - // ForceSendFields is a list of field names (e.g. "DataLocations") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DataLocations") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DataLocations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketCustomPlacementConfig) MarshalJSON() ([]byte, error) { type NoMethod BucketCustomPlacementConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketEncryption: Encryption configuration for a bucket. type BucketEncryption struct { - // DefaultKmsKeyName: A Cloud KMS key that will be used to encrypt - // objects inserted into this bucket, if no encryption method is - // specified. + // DefaultKmsKeyName: A Cloud KMS key that will be used to encrypt objects + // inserted into this bucket, if no encryption method is specified. DefaultKmsKeyName string `json:"defaultKmsKeyName,omitempty"` - - // ForceSendFields is a list of field names (e.g. "DefaultKmsKeyName") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "DefaultKmsKeyName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DefaultKmsKeyName") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "DefaultKmsKeyName") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketEncryption) MarshalJSON() ([]byte, error) { type NoMethod BucketEncryption - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketHierarchicalNamespace: The bucket's hierarchical namespace @@ -811,600 +693,469 @@ type BucketHierarchicalNamespace struct { // Enabled: When set to true, hierarchical namespace is enabled for this // bucket. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketHierarchicalNamespace) MarshalJSON() ([]byte, error) { type NoMethod BucketHierarchicalNamespace - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketIamConfiguration: The bucket's IAM configuration. type BucketIamConfiguration struct { - // BucketPolicyOnly: The bucket's uniform bucket-level access - // configuration. The feature was formerly known as Bucket Policy Only. - // For backward compatibility, this field will be populated with - // identical information as the uniformBucketLevelAccess field. We - // recommend using the uniformBucketLevelAccess field to enable and - // disable the feature. + // BucketPolicyOnly: The bucket's uniform bucket-level access configuration. + // The feature was formerly known as Bucket Policy Only. For backward + // compatibility, this field will be populated with identical information as + // the uniformBucketLevelAccess field. We recommend using the + // uniformBucketLevelAccess field to enable and disable the feature. BucketPolicyOnly *BucketIamConfigurationBucketPolicyOnly `json:"bucketPolicyOnly,omitempty"` - - // PublicAccessPrevention: The bucket's Public Access Prevention - // configuration. Currently, 'inherited' and 'enforced' are supported. + // PublicAccessPrevention: The bucket's Public Access Prevention configuration. + // Currently, 'inherited' and 'enforced' are supported. PublicAccessPrevention string `json:"publicAccessPrevention,omitempty"` - // UniformBucketLevelAccess: The bucket's uniform bucket-level access // configuration. UniformBucketLevelAccess *BucketIamConfigurationUniformBucketLevelAccess `json:"uniformBucketLevelAccess,omitempty"` - // ForceSendFields is a list of field names (e.g. "BucketPolicyOnly") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "BucketPolicyOnly") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "BucketPolicyOnly") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketIamConfiguration) MarshalJSON() ([]byte, error) { type NoMethod BucketIamConfiguration - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketIamConfigurationBucketPolicyOnly: The bucket's uniform -// bucket-level access configuration. The feature was formerly known as -// Bucket Policy Only. For backward compatibility, this field will be -// populated with identical information as the uniformBucketLevelAccess -// field. We recommend using the uniformBucketLevelAccess field to -// enable and disable the feature. +// BucketIamConfigurationBucketPolicyOnly: The bucket's uniform bucket-level +// access configuration. The feature was formerly known as Bucket Policy Only. +// For backward compatibility, this field will be populated with identical +// information as the uniformBucketLevelAccess field. We recommend using the +// uniformBucketLevelAccess field to enable and disable the feature. type BucketIamConfigurationBucketPolicyOnly struct { - // Enabled: If set, access is controlled only by bucket-level or above - // IAM policies. + // Enabled: If set, access is controlled only by bucket-level or above IAM + // policies. Enabled bool `json:"enabled,omitempty"` - // LockedTime: The deadline for changing - // iamConfiguration.bucketPolicyOnly.enabled from true to false in RFC - // 3339 format. iamConfiguration.bucketPolicyOnly.enabled may be changed - // from true to false until the locked time, after which the field is - // immutable. + // iamConfiguration.bucketPolicyOnly.enabled from true to false in RFC 3339 + // format. iamConfiguration.bucketPolicyOnly.enabled may be changed from true + // to false until the locked time, after which the field is immutable. LockedTime string `json:"lockedTime,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketIamConfigurationBucketPolicyOnly) MarshalJSON() ([]byte, error) { type NoMethod BucketIamConfigurationBucketPolicyOnly - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketIamConfigurationUniformBucketLevelAccess: The bucket's uniform // bucket-level access configuration. type BucketIamConfigurationUniformBucketLevelAccess struct { - // Enabled: If set, access is controlled only by bucket-level or above - // IAM policies. + // Enabled: If set, access is controlled only by bucket-level or above IAM + // policies. Enabled bool `json:"enabled,omitempty"` - // LockedTime: The deadline for changing - // iamConfiguration.uniformBucketLevelAccess.enabled from true to false - // in RFC 3339 format. - // iamConfiguration.uniformBucketLevelAccess.enabled may be changed from - // true to false until the locked time, after which the field is + // iamConfiguration.uniformBucketLevelAccess.enabled from true to false in RFC + // 3339 format. iamConfiguration.uniformBucketLevelAccess.enabled may be + // changed from true to false until the locked time, after which the field is // immutable. LockedTime string `json:"lockedTime,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketIamConfigurationUniformBucketLevelAccess) MarshalJSON() ([]byte, error) { type NoMethod BucketIamConfigurationUniformBucketLevelAccess - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketLifecycle: The bucket's lifecycle configuration. See lifecycle // management for more information. type BucketLifecycle struct { - // Rule: A lifecycle management rule, which is made of an action to take - // and the condition(s) under which the action will be taken. + // Rule: A lifecycle management rule, which is made of an action to take and + // the condition(s) under which the action will be taken. Rule []*BucketLifecycleRule `json:"rule,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Rule") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Rule") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Rule") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Rule") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketLifecycle) MarshalJSON() ([]byte, error) { type NoMethod BucketLifecycle - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type BucketLifecycleRule struct { // Action: The action to take. Action *BucketLifecycleRuleAction `json:"action,omitempty"` - // Condition: The condition(s) under which the action will be taken. Condition *BucketLifecycleRuleCondition `json:"condition,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Action") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Action") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Action") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketLifecycleRule) MarshalJSON() ([]byte, error) { type NoMethod BucketLifecycleRule - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketLifecycleRuleAction: The action to take. type BucketLifecycleRuleAction struct { - // StorageClass: Target storage class. Required iff the type of the - // action is SetStorageClass. + // StorageClass: Target storage class. Required iff the type of the action is + // SetStorageClass. StorageClass string `json:"storageClass,omitempty"` - - // Type: Type of the action. Currently, only Delete, SetStorageClass, - // and AbortIncompleteMultipartUpload are supported. + // Type: Type of the action. Currently, only Delete, SetStorageClass, and + // AbortIncompleteMultipartUpload are supported. Type string `json:"type,omitempty"` - // ForceSendFields is a list of field names (e.g. "StorageClass") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "StorageClass") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "StorageClass") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketLifecycleRuleAction) MarshalJSON() ([]byte, error) { type NoMethod BucketLifecycleRuleAction - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketLifecycleRuleCondition: The condition(s) under which the action -// will be taken. +// BucketLifecycleRuleCondition: The condition(s) under which the action will +// be taken. type BucketLifecycleRuleCondition struct { - // Age: Age of an object (in days). This condition is satisfied when an - // object reaches the specified age. + // Age: Age of an object (in days). This condition is satisfied when an object + // reaches the specified age. Age *int64 `json:"age,omitempty"` - // CreatedBefore: A date in RFC 3339 format with only the date part (for - // instance, "2013-01-15"). This condition is satisfied when an object - // is created before midnight of the specified date in UTC. + // instance, "2013-01-15"). This condition is satisfied when an object is + // created before midnight of the specified date in UTC. CreatedBefore string `json:"createdBefore,omitempty"` - - // CustomTimeBefore: A date in RFC 3339 format with only the date part - // (for instance, "2013-01-15"). This condition is satisfied when the - // custom time on an object is before this date in UTC. + // CustomTimeBefore: A date in RFC 3339 format with only the date part (for + // instance, "2013-01-15"). This condition is satisfied when the custom time on + // an object is before this date in UTC. CustomTimeBefore string `json:"customTimeBefore,omitempty"` - // DaysSinceCustomTime: Number of days elapsed since the user-specified - // timestamp set on an object. The condition is satisfied if the days - // elapsed is at least this number. If no custom timestamp is specified - // on an object, the condition does not apply. + // timestamp set on an object. The condition is satisfied if the days elapsed + // is at least this number. If no custom timestamp is specified on an object, + // the condition does not apply. DaysSinceCustomTime int64 `json:"daysSinceCustomTime,omitempty"` - // DaysSinceNoncurrentTime: Number of days elapsed since the noncurrent - // timestamp of an object. The condition is satisfied if the days - // elapsed is at least this number. This condition is relevant only for - // versioned objects. The value of the field must be a nonnegative - // integer. If it's zero, the object version will become eligible for - // Lifecycle action as soon as it becomes noncurrent. + // timestamp of an object. The condition is satisfied if the days elapsed is at + // least this number. This condition is relevant only for versioned objects. + // The value of the field must be a nonnegative integer. If it's zero, the + // object version will become eligible for Lifecycle action as soon as it + // becomes noncurrent. DaysSinceNoncurrentTime int64 `json:"daysSinceNoncurrentTime,omitempty"` - - // IsLive: Relevant only for versioned objects. If the value is true, - // this condition matches live objects; if the value is false, it - // matches archived objects. + // IsLive: Relevant only for versioned objects. If the value is true, this + // condition matches live objects; if the value is false, it matches archived + // objects. IsLive *bool `json:"isLive,omitempty"` - - // MatchesPattern: A regular expression that satisfies the RE2 syntax. - // This condition is satisfied when the name of the object matches the - // RE2 pattern. Note: This feature is currently in the "Early Access" - // launch stage and is only available to a whitelisted set of users; - // that means that this feature may be changed in backward-incompatible - // ways and that it is not guaranteed to be released. + // MatchesPattern: A regular expression that satisfies the RE2 syntax. This + // condition is satisfied when the name of the object matches the RE2 pattern. + // Note: This feature is currently in the "Early Access" launch stage and is + // only available to a whitelisted set of users; that means that this feature + // may be changed in backward-incompatible ways and that it is not guaranteed + // to be released. MatchesPattern string `json:"matchesPattern,omitempty"` - // MatchesPrefix: List of object name prefixes. This condition will be - // satisfied when at least one of the prefixes exactly matches the - // beginning of the object name. + // satisfied when at least one of the prefixes exactly matches the beginning of + // the object name. MatchesPrefix []string `json:"matchesPrefix,omitempty"` - - // MatchesStorageClass: Objects having any of the storage classes - // specified by this condition will be matched. Values include - // MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, ARCHIVE, STANDARD, and - // DURABLE_REDUCED_AVAILABILITY. + // MatchesStorageClass: Objects having any of the storage classes specified by + // this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, + // NEARLINE, COLDLINE, ARCHIVE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. MatchesStorageClass []string `json:"matchesStorageClass,omitempty"` - // MatchesSuffix: List of object name suffixes. This condition will be - // satisfied when at least one of the suffixes exactly matches the end - // of the object name. + // satisfied when at least one of the suffixes exactly matches the end of the + // object name. MatchesSuffix []string `json:"matchesSuffix,omitempty"` - - // NoncurrentTimeBefore: A date in RFC 3339 format with only the date - // part (for instance, "2013-01-15"). This condition is satisfied when - // the noncurrent time on an object is before this date in UTC. This - // condition is relevant only for versioned objects. + // NoncurrentTimeBefore: A date in RFC 3339 format with only the date part (for + // instance, "2013-01-15"). This condition is satisfied when the noncurrent + // time on an object is before this date in UTC. This condition is relevant + // only for versioned objects. NoncurrentTimeBefore string `json:"noncurrentTimeBefore,omitempty"` - - // NumNewerVersions: Relevant only for versioned objects. If the value - // is N, this condition is satisfied when there are at least N versions - // (including the live version) newer than this version of the object. + // NumNewerVersions: Relevant only for versioned objects. If the value is N, + // this condition is satisfied when there are at least N versions (including + // the live version) newer than this version of the object. NumNewerVersions int64 `json:"numNewerVersions,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Age") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Age") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Age") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Age") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketLifecycleRuleCondition) MarshalJSON() ([]byte, error) { type NoMethod BucketLifecycleRuleCondition - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketLogging: The bucket's logging configuration, which defines the -// destination bucket and optional name prefix for the current bucket's -// logs. +// destination bucket and optional name prefix for the current bucket's logs. type BucketLogging struct { - // LogBucket: The destination bucket where the current bucket's logs - // should be placed. + // LogBucket: The destination bucket where the current bucket's logs should be + // placed. LogBucket string `json:"logBucket,omitempty"` - // LogObjectPrefix: A prefix for log object names. LogObjectPrefix string `json:"logObjectPrefix,omitempty"` - // ForceSendFields is a list of field names (e.g. "LogBucket") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "LogBucket") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "LogBucket") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketLogging) MarshalJSON() ([]byte, error) { type NoMethod BucketLogging - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketObjectRetention: The bucket's object retention config. type BucketObjectRetention struct { // Mode: The bucket's object retention mode. Can be Enabled. Mode string `json:"mode,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Mode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Mode") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Mode") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Mode") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketObjectRetention) MarshalJSON() ([]byte, error) { type NoMethod BucketObjectRetention - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketOwner: The owner of the bucket. This is always the project -// team's owner group. +// BucketOwner: The owner of the bucket. This is always the project team's +// owner group. type BucketOwner struct { // Entity: The entity, in the form project-owner-projectId. Entity string `json:"entity,omitempty"` - // EntityId: The ID for the entity. EntityId string `json:"entityId,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Entity") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Entity") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketOwner) MarshalJSON() ([]byte, error) { type NoMethod BucketOwner - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// BucketRetentionPolicy: The bucket's retention policy. The retention -// policy enforces a minimum retention time for all objects contained in -// the bucket, based on their creation time. Any attempt to overwrite or -// delete objects younger than the retention period will result in a -// PERMISSION_DENIED error. An unlocked retention policy can be modified -// or removed from the bucket via a storage.buckets.update operation. A -// locked retention policy cannot be removed or shortened in duration -// for the lifetime of the bucket. Attempting to remove or decrease -// period of a locked retention policy will result in a + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// BucketRetentionPolicy: The bucket's retention policy. The retention policy +// enforces a minimum retention time for all objects contained in the bucket, +// based on their creation time. Any attempt to overwrite or delete objects +// younger than the retention period will result in a PERMISSION_DENIED error. +// An unlocked retention policy can be modified or removed from the bucket via +// a storage.buckets.update operation. A locked retention policy cannot be +// removed or shortened in duration for the lifetime of the bucket. Attempting +// to remove or decrease period of a locked retention policy will result in a // PERMISSION_DENIED error. type BucketRetentionPolicy struct { - // EffectiveTime: Server-determined value that indicates the time from - // which policy was enforced and effective. This value is in RFC 3339 - // format. + // EffectiveTime: Server-determined value that indicates the time from which + // policy was enforced and effective. This value is in RFC 3339 format. EffectiveTime string `json:"effectiveTime,omitempty"` - // IsLocked: Once locked, an object retention policy cannot be modified. IsLocked bool `json:"isLocked,omitempty"` - - // RetentionPeriod: The duration in seconds that objects need to be - // retained. Retention duration must be greater than zero and less than - // 100 years. Note that enforcement of retention periods less than a day - // is not guaranteed. Such periods should only be used for testing - // purposes. + // RetentionPeriod: The duration in seconds that objects need to be retained. + // Retention duration must be greater than zero and less than 100 years. Note + // that enforcement of retention periods less than a day is not guaranteed. + // Such periods should only be used for testing purposes. RetentionPeriod int64 `json:"retentionPeriod,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "EffectiveTime") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EffectiveTime") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EffectiveTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketRetentionPolicy) MarshalJSON() ([]byte, error) { type NoMethod BucketRetentionPolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketSoftDeletePolicy: The bucket's soft delete policy, which -// defines the period of time that soft-deleted objects will be -// retained, and cannot be permanently deleted. +// BucketSoftDeletePolicy: The bucket's soft delete policy, which defines the +// period of time that soft-deleted objects will be retained, and cannot be +// permanently deleted. type BucketSoftDeletePolicy struct { - // EffectiveTime: Server-determined value that indicates the time from - // which the policy, or one with a greater retention, was effective. - // This value is in RFC 3339 format. + // EffectiveTime: Server-determined value that indicates the time from which + // the policy, or one with a greater retention, was effective. This value is in + // RFC 3339 format. EffectiveTime string `json:"effectiveTime,omitempty"` - - // RetentionDurationSeconds: The duration in seconds that soft-deleted - // objects in the bucket will be retained and cannot be permanently - // deleted. + // RetentionDurationSeconds: The duration in seconds that soft-deleted objects + // in the bucket will be retained and cannot be permanently deleted. RetentionDurationSeconds int64 `json:"retentionDurationSeconds,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "EffectiveTime") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EffectiveTime") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EffectiveTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketSoftDeletePolicy) MarshalJSON() ([]byte, error) { type NoMethod BucketSoftDeletePolicy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketVersioning: The bucket's versioning configuration. type BucketVersioning struct { - // Enabled: While set to true, versioning is fully enabled for this - // bucket. + // Enabled: While set to true, versioning is fully enabled for this bucket. Enabled bool `json:"enabled,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Enabled") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Enabled") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Enabled") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketVersioning) MarshalJSON() ([]byte, error) { type NoMethod BucketVersioning - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketWebsite: The bucket's website configuration, controlling how -// the service behaves when accessing bucket contents as a web site. See -// the Static Website Examples for more information. +// BucketWebsite: The bucket's website configuration, controlling how the +// service behaves when accessing bucket contents as a web site. See the Static +// Website Examples for more information. type BucketWebsite struct { - // MainPageSuffix: If the requested object path is missing, the service - // will ensure the path has a trailing '/', append this suffix, and - // attempt to retrieve the resulting object. This allows the creation of - // index.html objects to represent directory pages. + // MainPageSuffix: If the requested object path is missing, the service will + // ensure the path has a trailing '/', append this suffix, and attempt to + // retrieve the resulting object. This allows the creation of index.html + // objects to represent directory pages. MainPageSuffix string `json:"mainPageSuffix,omitempty"` - // NotFoundPage: If the requested object path is missing, and any - // mainPageSuffix object is missing, if applicable, the service will - // return the named object from this bucket as the content for a 404 Not - // Found result. + // mainPageSuffix object is missing, if applicable, the service will return the + // named object from this bucket as the content for a 404 Not Found result. NotFoundPage string `json:"notFoundPage,omitempty"` - // ForceSendFields is a list of field names (e.g. "MainPageSuffix") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MainPageSuffix") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "MainPageSuffix") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketWebsite) MarshalJSON() ([]byte, error) { type NoMethod BucketWebsite - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketAccessControl: An access-control entry. type BucketAccessControl struct { // Bucket: The name of the bucket. Bucket string `json:"bucket,omitempty"` - // Domain: The domain associated with the entity, if any. Domain string `json:"domain,omitempty"` - // Email: The email address associated with the entity, if any. Email string `json:"email,omitempty"` - - // Entity: The entity holding the permission, in one of the following - // forms: + // Entity: The entity holding the permission, in one of the following forms: // - user-userId // - user-email // - group-groupId @@ -1419,1363 +1170,1031 @@ type BucketAccessControl struct { // - To refer to all members of the Google Apps for Business domain // example.com, the entity would be domain-example.com. Entity string `json:"entity,omitempty"` - // EntityId: The ID for the entity, if any. EntityId string `json:"entityId,omitempty"` - // Etag: HTTP 1.1 Entity tag for the access-control entry. Etag string `json:"etag,omitempty"` - // Id: The ID of the access-control entry. Id string `json:"id,omitempty"` - - // Kind: The kind of item this is. For bucket access control entries, - // this is always storage#bucketAccessControl. + // Kind: The kind of item this is. For bucket access control entries, this is + // always storage#bucketAccessControl. Kind string `json:"kind,omitempty"` - // ProjectTeam: The project team associated with the entity, if any. ProjectTeam *BucketAccessControlProjectTeam `json:"projectTeam,omitempty"` - // Role: The access permission for the entity. Role string `json:"role,omitempty"` - // SelfLink: The link to this access-control entry. SelfLink string `json:"selfLink,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Bucket") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Bucket") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketAccessControl) MarshalJSON() ([]byte, error) { type NoMethod BucketAccessControl - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// BucketAccessControlProjectTeam: The project team associated with the -// entity, if any. +// BucketAccessControlProjectTeam: The project team associated with the entity, +// if any. type BucketAccessControlProjectTeam struct { // ProjectNumber: The project number. ProjectNumber string `json:"projectNumber,omitempty"` - // Team: The team. Team string `json:"team,omitempty"` - // ForceSendFields is a list of field names (e.g. "ProjectNumber") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ProjectNumber") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ProjectNumber") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketAccessControlProjectTeam) MarshalJSON() ([]byte, error) { type NoMethod BucketAccessControlProjectTeam - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BucketAccessControls: An access-control list. type BucketAccessControls struct { // Items: The list of items. Items []*BucketAccessControl `json:"items,omitempty"` - - // Kind: The kind of item this is. For lists of bucket access control - // entries, this is always storage#bucketAccessControls. + // Kind: The kind of item this is. For lists of bucket access control entries, + // this is always storage#bucketAccessControls. Kind string `json:"kind,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BucketAccessControls) MarshalJSON() ([]byte, error) { type NoMethod BucketAccessControls - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Buckets: A list of buckets. type Buckets struct { // Items: The list of items. Items []*Bucket `json:"items,omitempty"` - // Kind: The kind of item this is. For lists of buckets, this is always // storage#buckets. Kind string `json:"kind,omitempty"` - - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Buckets) MarshalJSON() ([]byte, error) { type NoMethod Buckets - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // BulkRestoreObjectsRequest: A bulk restore objects request. type BulkRestoreObjectsRequest struct { - // AllowOverwrite: If false (default), the restore will not overwrite - // live objects with the same name at the destination. This means some - // deleted objects may be skipped. If true, live objects will be - // overwritten resulting in a noncurrent object (if versioning is - // enabled). If versioning is not enabled, overwriting the object will - // result in a soft-deleted object. In either case, if a noncurrent - // object already exists with the same name, a live version can be - // written without issue. + // AllowOverwrite: If false (default), the restore will not overwrite live + // objects with the same name at the destination. This means some deleted + // objects may be skipped. If true, live objects will be overwritten resulting + // in a noncurrent object (if versioning is enabled). If versioning is not + // enabled, overwriting the object will result in a soft-deleted object. In + // either case, if a noncurrent object already exists with the same name, a + // live version can be written without issue. AllowOverwrite bool `json:"allowOverwrite,omitempty"` - - // CopySourceAcl: If true, copies the source object's ACL; otherwise, - // uses the bucket's default object ACL. The default is false. + // CopySourceAcl: If true, copies the source object's ACL; otherwise, uses the + // bucket's default object ACL. The default is false. CopySourceAcl bool `json:"copySourceAcl,omitempty"` - - // MatchGlobs: Restores only the objects matching any of the specified - // glob(s). If this parameter is not specified, all objects will be - // restored within the specified time range. + // MatchGlobs: Restores only the objects matching any of the specified glob(s). + // If this parameter is not specified, all objects will be restored within the + // specified time range. MatchGlobs []string `json:"matchGlobs,omitempty"` - - // SoftDeletedAfterTime: Restores only the objects that were - // soft-deleted after this time. + // SoftDeletedAfterTime: Restores only the objects that were soft-deleted after + // this time. SoftDeletedAfterTime string `json:"softDeletedAfterTime,omitempty"` - - // SoftDeletedBeforeTime: Restores only the objects that were - // soft-deleted before this time. + // SoftDeletedBeforeTime: Restores only the objects that were soft-deleted + // before this time. SoftDeletedBeforeTime string `json:"softDeletedBeforeTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllowOverwrite") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AllowOverwrite") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "AllowOverwrite") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *BulkRestoreObjectsRequest) MarshalJSON() ([]byte, error) { type NoMethod BulkRestoreObjectsRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Channel: An notification channel used to watch for resource changes. type Channel struct { - // Address: The address where notifications are delivered for this - // channel. + // Address: The address where notifications are delivered for this channel. Address string `json:"address,omitempty"` - - // Expiration: Date and time of notification channel expiration, - // expressed as a Unix timestamp, in milliseconds. Optional. + // Expiration: Date and time of notification channel expiration, expressed as a + // Unix timestamp, in milliseconds. Optional. Expiration int64 `json:"expiration,omitempty,string"` - // Id: A UUID or similar unique string that identifies this channel. Id string `json:"id,omitempty"` - - // Kind: Identifies this as a notification channel used to watch for - // changes to a resource, which is "api#channel". + // Kind: Identifies this as a notification channel used to watch for changes to + // a resource, which is "api#channel". Kind string `json:"kind,omitempty"` - // Params: Additional parameters controlling delivery channel behavior. // Optional. Params map[string]string `json:"params,omitempty"` - - // Payload: A Boolean value to indicate whether payload is wanted. - // Optional. + // Payload: A Boolean value to indicate whether payload is wanted. Optional. Payload bool `json:"payload,omitempty"` - - // ResourceId: An opaque ID that identifies the resource being watched - // on this channel. Stable across different API versions. + // ResourceId: An opaque ID that identifies the resource being watched on this + // channel. Stable across different API versions. ResourceId string `json:"resourceId,omitempty"` - // ResourceUri: A version-specific identifier for the watched resource. ResourceUri string `json:"resourceUri,omitempty"` - // Token: An arbitrary string delivered to the target address with each // notification delivered over this channel. Optional. Token string `json:"token,omitempty"` - // Type: The type of delivery mechanism used for this channel. Type string `json:"type,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Address") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Address") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Address") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Address") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Channel) MarshalJSON() ([]byte, error) { type NoMethod Channel - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ComposeRequest: A Compose request. type ComposeRequest struct { // Destination: Properties of the resulting object. Destination *Object `json:"destination,omitempty"` - // Kind: The kind of item this is. Kind string `json:"kind,omitempty"` - - // SourceObjects: The list of source objects that will be concatenated - // into a single object. + // SourceObjects: The list of source objects that will be concatenated into a + // single object. SourceObjects []*ComposeRequestSourceObjects `json:"sourceObjects,omitempty"` - // ForceSendFields is a list of field names (e.g. "Destination") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Destination") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Destination") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ComposeRequest) MarshalJSON() ([]byte, error) { type NoMethod ComposeRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type ComposeRequestSourceObjects struct { // Generation: The generation of this object to use as the source. Generation int64 `json:"generation,omitempty,string"` - - // Name: The source object's name. All source objects must reside in the - // same bucket. + // Name: The source object's name. All source objects must reside in the same + // bucket. Name string `json:"name,omitempty"` - - // ObjectPreconditions: Conditions that must be met for this operation - // to execute. + // ObjectPreconditions: Conditions that must be met for this operation to + // execute. ObjectPreconditions *ComposeRequestSourceObjectsObjectPreconditions `json:"objectPreconditions,omitempty"` - // ForceSendFields is a list of field names (e.g. "Generation") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Generation") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Generation") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ComposeRequestSourceObjects) MarshalJSON() ([]byte, error) { type NoMethod ComposeRequestSourceObjects - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ComposeRequestSourceObjectsObjectPreconditions: Conditions that must -// be met for this operation to execute. +// ComposeRequestSourceObjectsObjectPreconditions: Conditions that must be met +// for this operation to execute. type ComposeRequestSourceObjectsObjectPreconditions struct { - // IfGenerationMatch: Only perform the composition if the generation of - // the source object that would be used matches this value. If this - // value and a generation are both specified, they must be the same - // value or the call will fail. + // IfGenerationMatch: Only perform the composition if the generation of the + // source object that would be used matches this value. If this value and a + // generation are both specified, they must be the same value or the call will + // fail. IfGenerationMatch int64 `json:"ifGenerationMatch,omitempty,string"` - - // ForceSendFields is a list of field names (e.g. "IfGenerationMatch") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "IfGenerationMatch") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "IfGenerationMatch") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "IfGenerationMatch") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ComposeRequestSourceObjectsObjectPreconditions) MarshalJSON() ([]byte, error) { type NoMethod ComposeRequestSourceObjectsObjectPreconditions - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// Expr: Represents an expression text. Example: title: "User account -// presence" description: "Determines whether the request has a user -// account" expression: "size(request.user) > 0" +// Expr: Represents an expression text. Example: title: "User account presence" +// description: "Determines whether the request has a user account" expression: +// "size(request.user) > 0" type Expr struct { - // Description: An optional description of the expression. This is a - // longer text which describes the expression, e.g. when hovered over it - // in a UI. + // Description: An optional description of the expression. This is a longer + // text which describes the expression, e.g. when hovered over it in a UI. Description string `json:"description,omitempty"` - - // Expression: Textual representation of an expression in Common - // Expression Language syntax. The application context of the containing - // message determines which well-known feature set of CEL is supported. + // Expression: Textual representation of an expression in Common Expression + // Language syntax. The application context of the containing message + // determines which well-known feature set of CEL is supported. Expression string `json:"expression,omitempty"` - - // Location: An optional string indicating the location of the - // expression for error reporting, e.g. a file name and a position in - // the file. + // Location: An optional string indicating the location of the expression for + // error reporting, e.g. a file name and a position in the file. Location string `json:"location,omitempty"` - - // Title: An optional title for the expression, i.e. a short string - // describing its purpose. This can be used e.g. in UIs which allow to - // enter the expression. + // Title: An optional title for the expression, i.e. a short string describing + // its purpose. This can be used e.g. in UIs which allow to enter the + // expression. Title string `json:"title,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Description") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Description") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Expr) MarshalJSON() ([]byte, error) { type NoMethod Expr - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// Folder: A folder. Only available in buckets with hierarchical -// namespace enabled. +// Folder: A folder. Only available in buckets with hierarchical namespace +// enabled. type Folder struct { // Bucket: The name of the bucket containing this folder. Bucket string `json:"bucket,omitempty"` - // CreateTime: The creation time of the folder in RFC 3339 format. CreateTime string `json:"createTime,omitempty"` - // Id: The ID of the folder, including the bucket name, folder name. Id string `json:"id,omitempty"` - - // Kind: The kind of item this is. For folders, this is always - // storage#folder. + // Kind: The kind of item this is. For folders, this is always storage#folder. Kind string `json:"kind,omitempty"` - // Metageneration: The version of the metadata for this folder. Used for // preconditions and for detecting changes in metadata. Metageneration int64 `json:"metageneration,omitempty,string"` - - // Name: The name of the folder. Required if not specified by URL - // parameter. + // Name: The name of the folder. Required if not specified by URL parameter. Name string `json:"name,omitempty"` - - // PendingRenameInfo: Only present if the folder is part of an ongoing - // rename folder operation. Contains information which can be used to - // query the operation status. + // PendingRenameInfo: Only present if the folder is part of an ongoing rename + // folder operation. Contains information which can be used to query the + // operation status. PendingRenameInfo *FolderPendingRenameInfo `json:"pendingRenameInfo,omitempty"` - // SelfLink: The link to this folder. SelfLink string `json:"selfLink,omitempty"` - - // UpdateTime: The modification time of the folder metadata in RFC 3339 - // format. + // UpdateTime: The modification time of the folder metadata in RFC 3339 format. UpdateTime string `json:"updateTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Bucket") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Bucket") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Folder) MarshalJSON() ([]byte, error) { type NoMethod Folder - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// FolderPendingRenameInfo: Only present if the folder is part of an -// ongoing rename folder operation. Contains information which can be -// used to query the operation status. +// FolderPendingRenameInfo: Only present if the folder is part of an ongoing +// rename folder operation. Contains information which can be used to query the +// operation status. type FolderPendingRenameInfo struct { // OperationId: The ID of the rename folder operation. OperationId string `json:"operationId,omitempty"` - // ForceSendFields is a list of field names (e.g. "OperationId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "OperationId") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "OperationId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *FolderPendingRenameInfo) MarshalJSON() ([]byte, error) { type NoMethod FolderPendingRenameInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Folders: A list of folders. type Folders struct { // Items: The list of items. Items []*Folder `json:"items,omitempty"` - // Kind: The kind of item this is. For lists of folders, this is always // storage#folders. Kind string `json:"kind,omitempty"` - - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Folders) MarshalJSON() ([]byte, error) { type NoMethod Folders - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // GoogleLongrunningListOperationsResponse: The response message for // storage.buckets.operations.list. type GoogleLongrunningListOperationsResponse struct { - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - - // Operations: A list of operations that matches the specified filter in - // the request. + // Operations: A list of operations that matches the specified filter in the + // request. Operations []*GoogleLongrunningOperation `json:"operations,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NextPageToken") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { type NoMethod GoogleLongrunningListOperationsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // GoogleLongrunningOperation: This resource represents a long-running // operation that is the result of a network API call. type GoogleLongrunningOperation struct { - // Done: If the value is "false", it means the operation is still in - // progress. If "true", the operation is completed, and either "error" - // or "response" is available. + // Done: If the value is "false", it means the operation is still in progress. + // If "true", the operation is completed, and either "error" or "response" is + // available. Done bool `json:"done,omitempty"` - - // Error: The error result of the operation in case of failure or - // cancellation. + // Error: The error result of the operation in case of failure or cancellation. Error *GoogleRpcStatus `json:"error,omitempty"` - // Metadata: Service-specific metadata associated with the operation. It - // typically contains progress information and common metadata such as - // create time. Some services might not provide such metadata. Any - // method that returns a long-running operation should document the - // metadata type, if any. + // typically contains progress information and common metadata such as create + // time. Some services might not provide such metadata. Any method that returns + // a long-running operation should document the metadata type, if any. Metadata googleapi.RawMessage `json:"metadata,omitempty"` - - // Name: The server-assigned name, which is only unique within the same - // service that originally returns it. If you use the default HTTP - // mapping, the "name" should be a resource name ending with - // "operations/{operationId}". + // Name: The server-assigned name, which is only unique within the same service + // that originally returns it. If you use the default HTTP mapping, the "name" + // should be a resource name ending with "operations/{operationId}". Name string `json:"name,omitempty"` - - // Response: The normal response of the operation in case of success. If - // the original method returns no data on success, such as "Delete", the - // response is google.protobuf.Empty. If the original method is standard - // Get/Create/Update, the response should be the resource. For other - // methods, the response should have the type "XxxResponse", where "Xxx" - // is the original method name. For example, if the original method name - // is "TakeSnapshot()", the inferred response type is - // "TakeSnapshotResponse". + // Response: The normal response of the operation in case of success. If the + // original method returns no data on success, such as "Delete", the response + // is google.protobuf.Empty. If the original method is standard + // Get/Create/Update, the response should be the resource. For other methods, + // the response should have the type "XxxResponse", where "Xxx" is the original + // method name. For example, if the original method name is "TakeSnapshot()", + // the inferred response type is "TakeSnapshotResponse". Response googleapi.RawMessage `json:"response,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Done") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Done") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Done") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Done") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { type NoMethod GoogleLongrunningOperation - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GoogleRpcStatus: The "Status" type defines a logical error model that -// is suitable for different programming environments, including REST -// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each -// "Status" message contains three pieces of data: error code, error -// message, and error details. You can find out more about this error -// model and how to work with it in the API Design Guide -// (https://cloud.google.com/apis/design/errors). +// GoogleRpcStatus: The "Status" type defines a logical error model that is +// suitable for different programming environments, including REST APIs and RPC +// APIs. It is used by gRPC (https://github.com/grpc). Each "Status" message +// contains three pieces of data: error code, error message, and error details. +// You can find out more about this error model and how to work with it in the +// API Design Guide (https://cloud.google.com/apis/design/errors). type GoogleRpcStatus struct { - // Code: The status code, which should be an enum value of - // google.rpc.Code. + // Code: The status code, which should be an enum value of google.rpc.Code. Code int64 `json:"code,omitempty"` - - // Details: A list of messages that carry the error details. There is a - // common set of message types for APIs to use. + // Details: A list of messages that carry the error details. There is a common + // set of message types for APIs to use. Details []googleapi.RawMessage `json:"details,omitempty"` - - // Message: A developer-facing error message, which should be in - // English. + // Message: A developer-facing error message, which should be in English. Message string `json:"message,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Code") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Code") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Code") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Code") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { type NoMethod GoogleRpcStatus - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HmacKey: JSON template to produce a JSON-style HMAC Key resource for -// Create responses. +// HmacKey: JSON template to produce a JSON-style HMAC Key resource for Create +// responses. type HmacKey struct { // Kind: The kind of item this is. For HMAC keys, this is always // storage#hmacKey. Kind string `json:"kind,omitempty"` - // Metadata: Key metadata. Metadata *HmacKeyMetadata `json:"metadata,omitempty"` - // Secret: HMAC secret key material. Secret string `json:"secret,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Kind") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Kind") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Kind") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Kind") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HmacKey) MarshalJSON() ([]byte, error) { type NoMethod HmacKey - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HmacKeyMetadata: JSON template to produce a JSON-style HMAC Key -// metadata resource. +// HmacKeyMetadata: JSON template to produce a JSON-style HMAC Key metadata +// resource. type HmacKeyMetadata struct { // AccessId: The ID of the HMAC Key. AccessId string `json:"accessId,omitempty"` - // Etag: HTTP 1.1 Entity tag for the HMAC key. Etag string `json:"etag,omitempty"` - - // Id: The ID of the HMAC key, including the Project ID and the Access - // ID. + // Id: The ID of the HMAC key, including the Project ID and the Access ID. Id string `json:"id,omitempty"` - // Kind: The kind of item this is. For HMAC Key metadata, this is always // storage#hmacKeyMetadata. Kind string `json:"kind,omitempty"` - // ProjectId: Project ID owning the service account to which the key // authenticates. ProjectId string `json:"projectId,omitempty"` - // SelfLink: The link to this resource. SelfLink string `json:"selfLink,omitempty"` - - // ServiceAccountEmail: The email address of the key's associated - // service account. + // ServiceAccountEmail: The email address of the key's associated service + // account. ServiceAccountEmail string `json:"serviceAccountEmail,omitempty"` - - // State: The state of the key. Can be one of ACTIVE, INACTIVE, or - // DELETED. + // State: The state of the key. Can be one of ACTIVE, INACTIVE, or DELETED. State string `json:"state,omitempty"` - // TimeCreated: The creation time of the HMAC key in RFC 3339 format. TimeCreated string `json:"timeCreated,omitempty"` - - // Updated: The last modification time of the HMAC key metadata in RFC - // 3339 format. + // Updated: The last modification time of the HMAC key metadata in RFC 3339 + // format. Updated string `json:"updated,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AccessId") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "AccessId") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AccessId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HmacKeyMetadata) MarshalJSON() ([]byte, error) { type NoMethod HmacKeyMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // HmacKeysMetadata: A list of hmacKeys. type HmacKeysMetadata struct { // Items: The list of items. Items []*HmacKeyMetadata `json:"items,omitempty"` - // Kind: The kind of item this is. For lists of hmacKeys, this is always // storage#hmacKeysMetadata. Kind string `json:"kind,omitempty"` - - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *HmacKeysMetadata) MarshalJSON() ([]byte, error) { type NoMethod HmacKeysMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ManagedFolder: A managed folder. type ManagedFolder struct { // Bucket: The name of the bucket containing this managed folder. Bucket string `json:"bucket,omitempty"` - - // CreateTime: The creation time of the managed folder in RFC 3339 - // format. + // CreateTime: The creation time of the managed folder in RFC 3339 format. CreateTime string `json:"createTime,omitempty"` - - // Id: The ID of the managed folder, including the bucket name and - // managed folder name. + // Id: The ID of the managed folder, including the bucket name and managed + // folder name. Id string `json:"id,omitempty"` - // Kind: The kind of item this is. For managed folders, this is always // storage#managedFolder. Kind string `json:"kind,omitempty"` - - // Metageneration: The version of the metadata for this managed folder. - // Used for preconditions and for detecting changes in metadata. + // Metageneration: The version of the metadata for this managed folder. Used + // for preconditions and for detecting changes in metadata. Metageneration int64 `json:"metageneration,omitempty,string"` - - // Name: The name of the managed folder. Required if not specified by - // URL parameter. + // Name: The name of the managed folder. Required if not specified by URL + // parameter. Name string `json:"name,omitempty"` - // SelfLink: The link to this managed folder. SelfLink string `json:"selfLink,omitempty"` - - // UpdateTime: The last update time of the managed folder metadata in - // RFC 3339 format. + // UpdateTime: The last update time of the managed folder metadata in RFC 3339 + // format. UpdateTime string `json:"updateTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Bucket") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Bucket") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ManagedFolder) MarshalJSON() ([]byte, error) { type NoMethod ManagedFolder - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ManagedFolders: A list of managed folders. type ManagedFolders struct { // Items: The list of items. Items []*ManagedFolder `json:"items,omitempty"` - - // Kind: The kind of item this is. For lists of managed folders, this is - // always storage#managedFolders. + // Kind: The kind of item this is. For lists of managed folders, this is always + // storage#managedFolders. Kind string `json:"kind,omitempty"` - - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ManagedFolders) MarshalJSON() ([]byte, error) { type NoMethod ManagedFolders - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Notification: A subscription to receive Google PubSub notifications. type Notification struct { - // CustomAttributes: An optional list of additional attributes to attach - // to each Cloud PubSub message published for this notification - // subscription. + // CustomAttributes: An optional list of additional attributes to attach to + // each Cloud PubSub message published for this notification subscription. CustomAttributes map[string]string `json:"custom_attributes,omitempty"` - // Etag: HTTP 1.1 Entity tag for this subscription notification. Etag string `json:"etag,omitempty"` - - // EventTypes: If present, only send notifications about listed event - // types. If empty, sent notifications for all event types. + // EventTypes: If present, only send notifications about listed event types. If + // empty, sent notifications for all event types. EventTypes []string `json:"event_types,omitempty"` - // Id: The ID of the notification. Id string `json:"id,omitempty"` - // Kind: The kind of item this is. For notifications, this is always // storage#notification. Kind string `json:"kind,omitempty"` - - // ObjectNamePrefix: If present, only apply this notification - // configuration to object names that begin with this prefix. + // ObjectNamePrefix: If present, only apply this notification configuration to + // object names that begin with this prefix. ObjectNamePrefix string `json:"object_name_prefix,omitempty"` - // PayloadFormat: The desired content of the Payload. PayloadFormat string `json:"payload_format,omitempty"` - // SelfLink: The canonical URL of this notification. SelfLink string `json:"selfLink,omitempty"` - // Topic: The Cloud PubSub topic to which this subscription publishes. // Formatted as: - // '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topi - // c}' + // '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}' Topic string `json:"topic,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CustomAttributes") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CustomAttributes") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "CustomAttributes") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Notification) MarshalJSON() ([]byte, error) { type NoMethod Notification - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Notifications: A list of notification subscriptions. type Notifications struct { // Items: The list of items. Items []*Notification `json:"items,omitempty"` - - // Kind: The kind of item this is. For lists of notifications, this is - // always storage#notifications. + // Kind: The kind of item this is. For lists of notifications, this is always + // storage#notifications. Kind string `json:"kind,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Notifications) MarshalJSON() ([]byte, error) { type NoMethod Notifications - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Object: An object. type Object struct { // Acl: Access controls on the object. Acl []*ObjectAccessControl `json:"acl,omitempty"` - // Bucket: The name of the bucket containing this object. Bucket string `json:"bucket,omitempty"` - - // CacheControl: Cache-Control directive for the object data. If - // omitted, and the object is accessible to all anonymous users, the - // default will be public, max-age=3600. + // CacheControl: Cache-Control directive for the object data. If omitted, and + // the object is accessible to all anonymous users, the default will be public, + // max-age=3600. CacheControl string `json:"cacheControl,omitempty"` - - // ComponentCount: Number of underlying components that make up this - // object. Components are accumulated by compose operations. + // ComponentCount: Number of underlying components that make up this object. + // Components are accumulated by compose operations. ComponentCount int64 `json:"componentCount,omitempty"` - // ContentDisposition: Content-Disposition of the object data. ContentDisposition string `json:"contentDisposition,omitempty"` - // ContentEncoding: Content-Encoding of the object data. ContentEncoding string `json:"contentEncoding,omitempty"` - // ContentLanguage: Content-Language of the object data. ContentLanguage string `json:"contentLanguage,omitempty"` - - // ContentType: Content-Type of the object data. If an object is stored - // without a Content-Type, it is served as application/octet-stream. + // ContentType: Content-Type of the object data. If an object is stored without + // a Content-Type, it is served as application/octet-stream. ContentType string `json:"contentType,omitempty"` - - // Crc32c: CRC32c checksum, as described in RFC 4960, Appendix B; - // encoded using base64 in big-endian byte order. For more information - // about using the CRC32c checksum, see Hashes and ETags: Best - // Practices. + // Crc32c: CRC32c checksum, as described in RFC 4960, Appendix B; encoded using + // base64 in big-endian byte order. For more information about using the CRC32c + // checksum, see Hashes and ETags: Best Practices. Crc32c string `json:"crc32c,omitempty"` - - // CustomTime: A timestamp in RFC 3339 format specified by the user for - // an object. + // CustomTime: A timestamp in RFC 3339 format specified by the user for an + // object. CustomTime string `json:"customTime,omitempty"` - - // CustomerEncryption: Metadata of customer-supplied encryption key, if - // the object is encrypted by such a key. + // CustomerEncryption: Metadata of customer-supplied encryption key, if the + // object is encrypted by such a key. CustomerEncryption *ObjectCustomerEncryption `json:"customerEncryption,omitempty"` - // Etag: HTTP 1.1 Entity tag for the object. Etag string `json:"etag,omitempty"` - - // EventBasedHold: Whether an object is under event-based hold. - // Event-based hold is a way to retain objects until an event occurs, - // which is signified by the hold's release (i.e. this value is set to - // false). After being released (set to false), such objects will be - // subject to bucket-level retention (if any). One sample use case of - // this flag is for banks to hold loan documents for at least 3 years - // after loan is paid in full. Here, bucket-level retention is 3 years - // and the event is the loan being paid in full. In this example, these - // objects will be held intact for any number of years until the event - // has occurred (event-based hold on the object is released) and then 3 - // more years after that. That means retention duration of the objects - // begins from the moment event-based hold transitioned from true to - // false. + // EventBasedHold: Whether an object is under event-based hold. Event-based + // hold is a way to retain objects until an event occurs, which is signified by + // the hold's release (i.e. this value is set to false). After being released + // (set to false), such objects will be subject to bucket-level retention (if + // any). One sample use case of this flag is for banks to hold loan documents + // for at least 3 years after loan is paid in full. Here, bucket-level + // retention is 3 years and the event is the loan being paid in full. In this + // example, these objects will be held intact for any number of years until the + // event has occurred (event-based hold on the object is released) and then 3 + // more years after that. That means retention duration of the objects begins + // from the moment event-based hold transitioned from true to false. EventBasedHold bool `json:"eventBasedHold,omitempty"` - // Generation: The content generation of this object. Used for object // versioning. Generation int64 `json:"generation,omitempty,string"` - - // HardDeleteTime: This is the time (in the future) when the - // soft-deleted object will no longer be restorable. It is equal to the - // soft delete time plus the current soft delete retention duration of - // the bucket. + // HardDeleteTime: This is the time (in the future) when the soft-deleted + // object will no longer be restorable. It is equal to the soft delete time + // plus the current soft delete retention duration of the bucket. HardDeleteTime string `json:"hardDeleteTime,omitempty"` - // Id: The ID of the object, including the bucket name, object name, and // generation number. Id string `json:"id,omitempty"` - - // Kind: The kind of item this is. For objects, this is always - // storage#object. + // Kind: The kind of item this is. For objects, this is always storage#object. Kind string `json:"kind,omitempty"` - - // KmsKeyName: Not currently supported. Specifying the parameter causes - // the request to fail with status code 400 - Bad Request. + // KmsKeyName: Not currently supported. Specifying the parameter causes the + // request to fail with status code 400 - Bad Request. KmsKeyName string `json:"kmsKeyName,omitempty"` - - // Md5Hash: MD5 hash of the data; encoded using base64. For more - // information about using the MD5 hash, see Hashes and ETags: Best - // Practices. + // Md5Hash: MD5 hash of the data; encoded using base64. For more information + // about using the MD5 hash, see Hashes and ETags: Best Practices. Md5Hash string `json:"md5Hash,omitempty"` - // MediaLink: Media download link. MediaLink string `json:"mediaLink,omitempty"` - // Metadata: User-provided metadata, in key/value pairs. Metadata map[string]string `json:"metadata,omitempty"` - // Metageneration: The version of the metadata for this object at this - // generation. Used for preconditions and for detecting changes in - // metadata. A metageneration number is only meaningful in the context - // of a particular generation of a particular object. + // generation. Used for preconditions and for detecting changes in metadata. A + // metageneration number is only meaningful in the context of a particular + // generation of a particular object. Metageneration int64 `json:"metageneration,omitempty,string"` - - // Name: The name of the object. Required if not specified by URL - // parameter. + // Name: The name of the object. Required if not specified by URL parameter. Name string `json:"name,omitempty"` - - // Owner: The owner of the object. This will always be the uploader of - // the object. + // Owner: The owner of the object. This will always be the uploader of the + // object. Owner *ObjectOwner `json:"owner,omitempty"` - // Retention: A collection of object level retention parameters. Retention *ObjectRetention `json:"retention,omitempty"` - // RetentionExpirationTime: A server-determined value that specifies the - // earliest time that the object's retention period expires. This value - // is in RFC 3339 format. Note 1: This field is not provided for objects - // with an active event-based hold, since retention expiration is - // unknown until the hold is removed. Note 2: This value can be provided - // even when temporary hold is set (so that the user can reason about - // policy without having to first unset the temporary hold). + // earliest time that the object's retention period expires. This value is in + // RFC 3339 format. Note 1: This field is not provided for objects with an + // active event-based hold, since retention expiration is unknown until the + // hold is removed. Note 2: This value can be provided even when temporary hold + // is set (so that the user can reason about policy without having to first + // unset the temporary hold). RetentionExpirationTime string `json:"retentionExpirationTime,omitempty"` - // SelfLink: The link to this object. SelfLink string `json:"selfLink,omitempty"` - // Size: Content-Length of the data in bytes. Size uint64 `json:"size,omitempty,string"` - - // SoftDeleteTime: The time at which the object became soft-deleted in - // RFC 3339 format. + // SoftDeleteTime: The time at which the object became soft-deleted in RFC 3339 + // format. SoftDeleteTime string `json:"softDeleteTime,omitempty"` - // StorageClass: Storage class of the object. StorageClass string `json:"storageClass,omitempty"` - - // TemporaryHold: Whether an object is under temporary hold. While this - // flag is set to true, the object is protected against deletion and - // overwrites. A common use case of this flag is regulatory - // investigations where objects need to be retained while the - // investigation is ongoing. Note that unlike event-based hold, - // temporary hold does not impact retention expiration time of an - // object. + // TemporaryHold: Whether an object is under temporary hold. While this flag is + // set to true, the object is protected against deletion and overwrites. A + // common use case of this flag is regulatory investigations where objects need + // to be retained while the investigation is ongoing. Note that unlike + // event-based hold, temporary hold does not impact retention expiration time + // of an object. TemporaryHold bool `json:"temporaryHold,omitempty"` - // TimeCreated: The creation time of the object in RFC 3339 format. TimeCreated string `json:"timeCreated,omitempty"` - - // TimeDeleted: The time at which the object became noncurrent in RFC - // 3339 format. Will be returned if and only if this version of the - // object has been deleted. + // TimeDeleted: The time at which the object became noncurrent in RFC 3339 + // format. Will be returned if and only if this version of the object has been + // deleted. TimeDeleted string `json:"timeDeleted,omitempty"` - - // TimeStorageClassUpdated: The time at which the object's storage class - // was last changed. When the object is initially created, it will be - // set to timeCreated. + // TimeStorageClassUpdated: The time at which the object's storage class was + // last changed. When the object is initially created, it will be set to + // timeCreated. TimeStorageClassUpdated string `json:"timeStorageClassUpdated,omitempty"` - - // Updated: The modification time of the object metadata in RFC 3339 - // format. Set initially to object creation time and then updated - // whenever any metadata of the object changes. This includes changes - // made by a requester, such as modifying custom metadata, as well as - // changes made by Cloud Storage on behalf of a requester, such as - // changing the storage class based on an Object Lifecycle - // Configuration. + // Updated: The modification time of the object metadata in RFC 3339 format. + // Set initially to object creation time and then updated whenever any metadata + // of the object changes. This includes changes made by a requester, such as + // modifying custom metadata, as well as changes made by Cloud Storage on + // behalf of a requester, such as changing the storage class based on an Object + // Lifecycle Configuration. Updated string `json:"updated,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Acl") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Acl") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Acl") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Acl") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Object) MarshalJSON() ([]byte, error) { type NoMethod Object - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ObjectCustomerEncryption: Metadata of customer-supplied encryption -// key, if the object is encrypted by such a key. +// ObjectCustomerEncryption: Metadata of customer-supplied encryption key, if +// the object is encrypted by such a key. type ObjectCustomerEncryption struct { // EncryptionAlgorithm: The encryption algorithm. EncryptionAlgorithm string `json:"encryptionAlgorithm,omitempty"` - // KeySha256: SHA256 hash value of the encryption key. KeySha256 string `json:"keySha256,omitempty"` - - // ForceSendFields is a list of field names (e.g. "EncryptionAlgorithm") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "EncryptionAlgorithm") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EncryptionAlgorithm") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EncryptionAlgorithm") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ObjectCustomerEncryption) MarshalJSON() ([]byte, error) { type NoMethod ObjectCustomerEncryption - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ObjectOwner: The owner of the object. This will always be the -// uploader of the object. +// ObjectOwner: The owner of the object. This will always be the uploader of +// the object. type ObjectOwner struct { // Entity: The entity, in the form user-userId. Entity string `json:"entity,omitempty"` - // EntityId: The ID for the entity. EntityId string `json:"entityId,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Entity") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Entity") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ObjectOwner) MarshalJSON() ([]byte, error) { type NoMethod ObjectOwner - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ObjectRetention: A collection of object level retention parameters. type ObjectRetention struct { - // Mode: The bucket's object retention mode, can only be Unlocked or - // Locked. + // Mode: The bucket's object retention mode, can only be Unlocked or Locked. Mode string `json:"mode,omitempty"` - - // RetainUntilTime: A time in RFC 3339 format until which object - // retention protects this object. + // RetainUntilTime: A time in RFC 3339 format until which object retention + // protects this object. RetainUntilTime string `json:"retainUntilTime,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Mode") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Mode") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Mode") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Mode") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ObjectRetention) MarshalJSON() ([]byte, error) { type NoMethod ObjectRetention - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ObjectAccessControl: An access-control entry. type ObjectAccessControl struct { // Bucket: The name of the bucket. Bucket string `json:"bucket,omitempty"` - // Domain: The domain associated with the entity, if any. Domain string `json:"domain,omitempty"` - // Email: The email address associated with the entity, if any. Email string `json:"email,omitempty"` - - // Entity: The entity holding the permission, in one of the following - // forms: + // Entity: The entity holding the permission, in one of the following forms: // - user-userId // - user-email // - group-groupId @@ -2790,174 +2209,132 @@ type ObjectAccessControl struct { // - To refer to all members of the Google Apps for Business domain // example.com, the entity would be domain-example.com. Entity string `json:"entity,omitempty"` - // EntityId: The ID for the entity, if any. EntityId string `json:"entityId,omitempty"` - // Etag: HTTP 1.1 Entity tag for the access-control entry. Etag string `json:"etag,omitempty"` - - // Generation: The content generation of the object, if applied to an - // object. + // Generation: The content generation of the object, if applied to an object. Generation int64 `json:"generation,omitempty,string"` - // Id: The ID of the access-control entry. Id string `json:"id,omitempty"` - - // Kind: The kind of item this is. For object access control entries, - // this is always storage#objectAccessControl. + // Kind: The kind of item this is. For object access control entries, this is + // always storage#objectAccessControl. Kind string `json:"kind,omitempty"` - // Object: The name of the object, if applied to an object. Object string `json:"object,omitempty"` - // ProjectTeam: The project team associated with the entity, if any. ProjectTeam *ObjectAccessControlProjectTeam `json:"projectTeam,omitempty"` - // Role: The access permission for the entity. Role string `json:"role,omitempty"` - // SelfLink: The link to this access-control entry. SelfLink string `json:"selfLink,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Bucket") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Bucket") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ObjectAccessControl) MarshalJSON() ([]byte, error) { type NoMethod ObjectAccessControl - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ObjectAccessControlProjectTeam: The project team associated with the -// entity, if any. +// ObjectAccessControlProjectTeam: The project team associated with the entity, +// if any. type ObjectAccessControlProjectTeam struct { // ProjectNumber: The project number. ProjectNumber string `json:"projectNumber,omitempty"` - // Team: The team. Team string `json:"team,omitempty"` - // ForceSendFields is a list of field names (e.g. "ProjectNumber") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ProjectNumber") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ProjectNumber") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ObjectAccessControlProjectTeam) MarshalJSON() ([]byte, error) { type NoMethod ObjectAccessControlProjectTeam - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // ObjectAccessControls: An access-control list. type ObjectAccessControls struct { // Items: The list of items. Items []*ObjectAccessControl `json:"items,omitempty"` - - // Kind: The kind of item this is. For lists of object access control - // entries, this is always storage#objectAccessControls. + // Kind: The kind of item this is. For lists of object access control entries, + // this is always storage#objectAccessControls. Kind string `json:"kind,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ObjectAccessControls) MarshalJSON() ([]byte, error) { type NoMethod ObjectAccessControls - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Objects: A list of objects. type Objects struct { // Items: The list of items. Items []*Object `json:"items,omitempty"` - // Kind: The kind of item this is. For lists of objects, this is always // storage#objects. Kind string `json:"kind,omitempty"` - - // NextPageToken: The continuation token, used to page through large - // result sets. Provide this value in a subsequent request to return the - // next page of results. + // NextPageToken: The continuation token, used to page through large result + // sets. Provide this value in a subsequent request to return the next page of + // results. NextPageToken string `json:"nextPageToken,omitempty"` - - // Prefixes: The list of prefixes of objects matching-but-not-listed up - // to and including the requested delimiter. + // Prefixes: The list of prefixes of objects matching-but-not-listed up to and + // including the requested delimiter. Prefixes []string `json:"prefixes,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Items") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Items") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Items") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Objects) MarshalJSON() ([]byte, error) { type NoMethod Objects - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // Policy: A bucket/object/managedFolder IAM policy. @@ -2965,231 +2342,182 @@ type Policy struct { // Bindings: An association between a role, which comes with a set of // permissions, and members who may assume that role. Bindings []*PolicyBindings `json:"bindings,omitempty"` - // Etag: HTTP 1.1 Entity tag for the policy. Etag string `json:"etag,omitempty"` - - // Kind: The kind of item this is. For policies, this is always - // storage#policy. This field is ignored on input. + // Kind: The kind of item this is. For policies, this is always storage#policy. + // This field is ignored on input. Kind string `json:"kind,omitempty"` - - // ResourceId: The ID of the resource to which this policy belongs. Will - // be of the form projects/_/buckets/bucket for buckets, + // ResourceId: The ID of the resource to which this policy belongs. Will be of + // the form projects/_/buckets/bucket for buckets, // projects/_/buckets/bucket/objects/object for objects, and // projects/_/buckets/bucket/managedFolders/managedFolder. A specific - // generation may be specified by appending #generationNumber to the end - // of the object name, e.g. - // projects/_/buckets/my-bucket/objects/data.txt#17. The current - // generation can be denoted with #0. This field is ignored on input. + // generation may be specified by appending #generationNumber to the end of the + // object name, e.g. projects/_/buckets/my-bucket/objects/data.txt#17. The + // current generation can be denoted with #0. This field is ignored on input. ResourceId string `json:"resourceId,omitempty"` - // Version: The IAM policy format version. Version int64 `json:"version,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Bindings") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Bindings") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Bindings") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *Policy) MarshalJSON() ([]byte, error) { type NoMethod Policy - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } type PolicyBindings struct { - // Condition: The condition that is associated with this binding. NOTE: - // an unsatisfied condition will not allow user access via current - // binding. Different bindings, including their conditions, are examined - // independently. + // Condition: The condition that is associated with this binding. NOTE: an + // unsatisfied condition will not allow user access via current binding. + // Different bindings, including their conditions, are examined independently. Condition *Expr `json:"condition,omitempty"` - - // Members: A collection of identifiers for members who may assume the - // provided role. Recognized identifiers are as follows: - // - allUsers — A special identifier that represents anyone on the - // internet; with or without a Google account. - // - allAuthenticatedUsers — A special identifier that represents - // anyone who is authenticated with a Google account or a service - // account. - // - user:emailid — An email address that represents a specific - // account. For example, user:alice@gmail.com or user:joe@example.com. - // - // - serviceAccount:emailid — An email address that represents a - // service account. For example, + // Members: A collection of identifiers for members who may assume the provided + // role. Recognized identifiers are as follows: + // - allUsers — A special identifier that represents anyone on the internet; + // with or without a Google account. + // - allAuthenticatedUsers — A special identifier that represents anyone who + // is authenticated with a Google account or a service account. + // - user:emailid — An email address that represents a specific account. For + // example, user:alice@gmail.com or user:joe@example.com. + // - serviceAccount:emailid — An email address that represents a service + // account. For example, // serviceAccount:my-other-app@appspot.gserviceaccount.com . - // - group:emailid — An email address that represents a Google group. - // For example, group:admins@example.com. - // - domain:domain — A Google Apps domain name that represents all the - // users of that domain. For example, domain:google.com or - // domain:example.com. - // - projectOwner:projectid — Owners of the given project. For - // example, projectOwner:my-example-project - // - projectEditor:projectid — Editors of the given project. For - // example, projectEditor:my-example-project - // - projectViewer:projectid — Viewers of the given project. For - // example, projectViewer:my-example-project + // - group:emailid — An email address that represents a Google group. For + // example, group:admins@example.com. + // - domain:domain — A Google Apps domain name that represents all the users + // of that domain. For example, domain:google.com or domain:example.com. + // - projectOwner:projectid — Owners of the given project. For example, + // projectOwner:my-example-project + // - projectEditor:projectid — Editors of the given project. For example, + // projectEditor:my-example-project + // - projectViewer:projectid — Viewers of the given project. For example, + // projectViewer:my-example-project Members []string `json:"members,omitempty"` - - // Role: The role to which members belong. Two types of roles are - // supported: new IAM roles, which grant permissions that do not map - // directly to those provided by ACLs, and legacy IAM roles, which do - // map directly to ACL permissions. All roles are of the format - // roles/storage.specificRole. + // Role: The role to which members belong. Two types of roles are supported: + // new IAM roles, which grant permissions that do not map directly to those + // provided by ACLs, and legacy IAM roles, which do map directly to ACL + // permissions. All roles are of the format roles/storage.specificRole. // The new IAM roles are: - // - roles/storage.admin — Full control of Google Cloud Storage - // resources. - // - roles/storage.objectViewer — Read-Only access to Google Cloud - // Storage objects. - // - roles/storage.objectCreator — Access to create objects in Google - // Cloud Storage. + // - roles/storage.admin — Full control of Google Cloud Storage resources. + // + // - roles/storage.objectViewer — Read-Only access to Google Cloud Storage + // objects. + // - roles/storage.objectCreator — Access to create objects in Google Cloud + // Storage. // - roles/storage.objectAdmin — Full control of Google Cloud Storage // objects. The legacy IAM roles are: - // - roles/storage.legacyObjectReader — Read-only access to objects - // without listing. Equivalent to an ACL entry on an object with the - // READER role. - // - roles/storage.legacyObjectOwner — Read/write access to existing - // objects without listing. Equivalent to an ACL entry on an object with - // the OWNER role. - // - roles/storage.legacyBucketReader — Read access to buckets with - // object listing. Equivalent to an ACL entry on a bucket with the - // READER role. - // - roles/storage.legacyBucketWriter — Read access to buckets with - // object listing/creation/deletion. Equivalent to an ACL entry on a - // bucket with the WRITER role. - // - roles/storage.legacyBucketOwner — Read and write access to - // existing buckets with object listing/creation/deletion. Equivalent to - // an ACL entry on a bucket with the OWNER role. + // - roles/storage.legacyObjectReader — Read-only access to objects without + // listing. Equivalent to an ACL entry on an object with the READER role. + // - roles/storage.legacyObjectOwner — Read/write access to existing objects + // without listing. Equivalent to an ACL entry on an object with the OWNER + // role. + // - roles/storage.legacyBucketReader — Read access to buckets with object + // listing. Equivalent to an ACL entry on a bucket with the READER role. + // - roles/storage.legacyBucketWriter — Read access to buckets with object + // listing/creation/deletion. Equivalent to an ACL entry on a bucket with the + // WRITER role. + // - roles/storage.legacyBucketOwner — Read and write access to existing + // buckets with object listing/creation/deletion. Equivalent to an ACL entry on + // a bucket with the OWNER role. Role string `json:"role,omitempty"` - // ForceSendFields is a list of field names (e.g. "Condition") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Condition") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Condition") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *PolicyBindings) MarshalJSON() ([]byte, error) { type NoMethod PolicyBindings - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // RewriteResponse: A rewrite response. type RewriteResponse struct { - // Done: true if the copy is finished; otherwise, false if the copy is - // in progress. This property is always present in the response. + // Done: true if the copy is finished; otherwise, false if the copy is in + // progress. This property is always present in the response. Done bool `json:"done,omitempty"` - // Kind: The kind of item this is. Kind string `json:"kind,omitempty"` - // ObjectSize: The total size of the object being copied in bytes. This // property is always present in the response. ObjectSize int64 `json:"objectSize,omitempty,string"` - - // Resource: A resource containing the metadata for the copied-to - // object. This property is present in the response only when copying - // completes. + // Resource: A resource containing the metadata for the copied-to object. This + // property is present in the response only when copying completes. Resource *Object `json:"resource,omitempty"` - - // RewriteToken: A token to use in subsequent requests to continue - // copying data. This token is present in the response only when there - // is more data to copy. + // RewriteToken: A token to use in subsequent requests to continue copying + // data. This token is present in the response only when there is more data to + // copy. RewriteToken string `json:"rewriteToken,omitempty"` - - // TotalBytesRewritten: The total bytes written so far, which can be - // used to provide a waiting user with a progress indicator. This - // property is always present in the response. + // TotalBytesRewritten: The total bytes written so far, which can be used to + // provide a waiting user with a progress indicator. This property is always + // present in the response. TotalBytesRewritten int64 `json:"totalBytesRewritten,omitempty,string"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Done") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Done") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Done") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Done") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *RewriteResponse) MarshalJSON() ([]byte, error) { type NoMethod RewriteResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// ServiceAccount: A subscription to receive Google PubSub -// notifications. +// ServiceAccount: A subscription to receive Google PubSub notifications. type ServiceAccount struct { // EmailAddress: The ID of the notification. EmailAddress string `json:"email_address,omitempty"` - // Kind: The kind of item this is. For notifications, this is always // storage#notification. Kind string `json:"kind,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "EmailAddress") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EmailAddress") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EmailAddress") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *ServiceAccount) MarshalJSON() ([]byte, error) { type NoMethod ServiceAccount - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } // TestIamPermissionsResponse: A @@ -3197,11 +2525,9 @@ func (s *ServiceAccount) MarshalJSON() ([]byte, error) { type TestIamPermissionsResponse struct { // Kind: The kind of item this is. Kind string `json:"kind,omitempty"` - - // Permissions: The permissions held by the caller. Permissions are - // always of the format storage.resource.capability, where resource is - // one of buckets, objects, or managedFolders. The supported permissions - // are as follows: + // Permissions: The permissions held by the caller. Permissions are always of + // the format storage.resource.capability, where resource is one of buckets, + // objects, or managedFolders. The supported permissions are as follows: // - storage.buckets.delete — Delete bucket. // - storage.buckets.get — Read bucket metadata. // - storage.buckets.getIamPolicy — Read bucket IAM policy. @@ -3218,43 +2544,33 @@ type TestIamPermissionsResponse struct { // - storage.objects.update — Update object metadata. // - storage.managedFolders.delete — Delete managed folder. // - storage.managedFolders.get — Read managed folder metadata. - // - storage.managedFolders.getIamPolicy — Read managed folder IAM - // policy. + // - storage.managedFolders.getIamPolicy — Read managed folder IAM policy. + // // - storage.managedFolders.create — Create managed folder. // - storage.managedFolders.list — List managed folders. - // - storage.managedFolders.setIamPolicy — Update managed folder IAM - // policy. + // - storage.managedFolders.setIamPolicy — Update managed folder IAM policy. Permissions []string `json:"permissions,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. + // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "Kind") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. "Kind") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Kind") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "Kind") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) { type NoMethod TestIamPermissionsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// method id "storage.anywhereCaches.disable": - type AnywhereCachesDisableCall struct { s *Service bucket string @@ -3276,23 +2592,21 @@ func (r *AnywhereCachesService) Disable(bucket string, anywhereCacheId string) * } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesDisableCall) Fields(s ...googleapi.Field) *AnywhereCachesDisableCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesDisableCall) Context(ctx context.Context) *AnywhereCachesDisableCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesDisableCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -3301,12 +2615,7 @@ func (c *AnywhereCachesDisableCall) Header() http.Header { } func (c *AnywhereCachesDisableCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -3325,12 +2634,10 @@ func (c *AnywhereCachesDisableCall) doRequest(alt string) (*http.Response, error } // Do executes the "storage.anywhereCaches.disable" call. -// Exactly one of *AnywhereCache or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *AnywhereCache.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *AnywhereCache.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *AnywhereCachesDisableCall) Do(opts ...googleapi.CallOption) (*AnywhereCache, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -3361,42 +2668,7 @@ func (c *AnywhereCachesDisableCall) Do(opts ...googleapi.CallOption) (*AnywhereC return nil, err } return ret, nil - // { - // "description": "Disables an Anywhere Cache instance.", - // "httpMethod": "POST", - // "id": "storage.anywhereCaches.disable", - // "parameterOrder": [ - // "bucket", - // "anywhereCacheId" - // ], - // "parameters": { - // "anywhereCacheId": { - // "description": "The ID of requested Anywhere Cache instance.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches/{anywhereCacheId}/disable", - // "response": { - // "$ref": "AnywhereCache" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.anywhereCaches.get": +} type AnywhereCachesGetCall struct { s *Service @@ -3420,33 +2692,29 @@ func (r *AnywhereCachesService) Get(bucket string, anywhereCacheId string) *Anyw } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesGetCall) Fields(s ...googleapi.Field) *AnywhereCachesGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *AnywhereCachesGetCall) IfNoneMatch(entityTag string) *AnywhereCachesGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesGetCall) Context(ctx context.Context) *AnywhereCachesGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -3455,12 +2723,7 @@ func (c *AnywhereCachesGetCall) Header() http.Header { } func (c *AnywhereCachesGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -3482,12 +2745,10 @@ func (c *AnywhereCachesGetCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.anywhereCaches.get" call. -// Exactly one of *AnywhereCache or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *AnywhereCache.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *AnywhereCache.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *AnywhereCachesGetCall) Do(opts ...googleapi.CallOption) (*AnywhereCache, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -3518,44 +2779,7 @@ func (c *AnywhereCachesGetCall) Do(opts ...googleapi.CallOption) (*AnywhereCache return nil, err } return ret, nil - // { - // "description": "Returns the metadata of an Anywhere Cache instance.", - // "httpMethod": "GET", - // "id": "storage.anywhereCaches.get", - // "parameterOrder": [ - // "bucket", - // "anywhereCacheId" - // ], - // "parameters": { - // "anywhereCacheId": { - // "description": "The ID of requested Anywhere Cache instance.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches/{anywhereCacheId}", - // "response": { - // "$ref": "AnywhereCache" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.anywhereCaches.insert": +} type AnywhereCachesInsertCall struct { s *Service @@ -3577,23 +2801,21 @@ func (r *AnywhereCachesService) Insert(bucket string, anywherecache *AnywhereCac } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesInsertCall) Fields(s ...googleapi.Field) *AnywhereCachesInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesInsertCall) Context(ctx context.Context) *AnywhereCachesInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -3602,18 +2824,12 @@ func (c *AnywhereCachesInsertCall) Header() http.Header { } func (c *AnywhereCachesInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.anywherecache) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/anywhereCaches") @@ -3630,12 +2846,11 @@ func (c *AnywhereCachesInsertCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.anywhereCaches.insert" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *AnywhereCachesInsertCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -3666,38 +2881,7 @@ func (c *AnywhereCachesInsertCall) Do(opts ...googleapi.CallOption) (*GoogleLong return nil, err } return ret, nil - // { - // "description": "Creates an Anywhere Cache instance.", - // "httpMethod": "POST", - // "id": "storage.anywhereCaches.insert", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches", - // "request": { - // "$ref": "AnywhereCache" - // }, - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.anywhereCaches.list": +} type AnywhereCachesListCall struct { s *Service @@ -3708,8 +2892,8 @@ type AnywhereCachesListCall struct { header_ http.Header } -// List: Returns a list of Anywhere Cache instances of the bucket -// matching the criteria. +// List: Returns a list of Anywhere Cache instances of the bucket matching the +// criteria. // // - bucket: Name of the parent bucket. func (r *AnywhereCachesService) List(bucket string) *AnywhereCachesListCall { @@ -3718,49 +2902,44 @@ func (r *AnywhereCachesService) List(bucket string) *AnywhereCachesListCall { return c } -// PageSize sets the optional parameter "pageSize": Maximum number of -// items to return in a single page of responses. Maximum 1000. +// PageSize sets the optional parameter "pageSize": Maximum number of items to +// return in a single page of responses. Maximum 1000. func (c *AnywhereCachesListCall) PageSize(pageSize int64) *AnywhereCachesListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *AnywhereCachesListCall) PageToken(pageToken string) *AnywhereCachesListCall { c.urlParams_.Set("pageToken", pageToken) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesListCall) Fields(s ...googleapi.Field) *AnywhereCachesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *AnywhereCachesListCall) IfNoneMatch(entityTag string) *AnywhereCachesListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesListCall) Context(ctx context.Context) *AnywhereCachesListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -3769,12 +2948,7 @@ func (c *AnywhereCachesListCall) Header() http.Header { } func (c *AnywhereCachesListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -3795,12 +2969,10 @@ func (c *AnywhereCachesListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.anywhereCaches.list" call. -// Exactly one of *AnywhereCaches or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *AnywhereCaches.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *AnywhereCaches.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *AnywhereCachesListCall) Do(opts ...googleapi.CallOption) (*AnywhereCaches, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -3831,46 +3003,6 @@ func (c *AnywhereCachesListCall) Do(opts ...googleapi.CallOption) (*AnywhereCach return nil, err } return ret, nil - // { - // "description": "Returns a list of Anywhere Cache instances of the bucket matching the criteria.", - // "httpMethod": "GET", - // "id": "storage.anywhereCaches.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "pageSize": { - // "description": "Maximum number of items to return in a single page of responses. Maximum 1000.", - // "format": "int32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches", - // "response": { - // "$ref": "AnywhereCaches" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - } // Pages invokes f for each page of results. @@ -3878,7 +3010,7 @@ func (c *AnywhereCachesListCall) Do(opts ...googleapi.CallOption) (*AnywhereCach // The provided context supersedes any context provided to the Context method. func (c *AnywhereCachesListCall) Pages(ctx context.Context, f func(*AnywhereCaches) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -3894,8 +3026,6 @@ func (c *AnywhereCachesListCall) Pages(ctx context.Context, f func(*AnywhereCach } } -// method id "storage.anywhereCaches.pause": - type AnywhereCachesPauseCall struct { s *Service bucket string @@ -3917,23 +3047,21 @@ func (r *AnywhereCachesService) Pause(bucket string, anywhereCacheId string) *An } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesPauseCall) Fields(s ...googleapi.Field) *AnywhereCachesPauseCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesPauseCall) Context(ctx context.Context) *AnywhereCachesPauseCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesPauseCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -3942,12 +3070,7 @@ func (c *AnywhereCachesPauseCall) Header() http.Header { } func (c *AnywhereCachesPauseCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -3966,12 +3089,10 @@ func (c *AnywhereCachesPauseCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.anywhereCaches.pause" call. -// Exactly one of *AnywhereCache or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *AnywhereCache.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *AnywhereCache.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *AnywhereCachesPauseCall) Do(opts ...googleapi.CallOption) (*AnywhereCache, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -4002,42 +3123,7 @@ func (c *AnywhereCachesPauseCall) Do(opts ...googleapi.CallOption) (*AnywhereCac return nil, err } return ret, nil - // { - // "description": "Pauses an Anywhere Cache instance.", - // "httpMethod": "POST", - // "id": "storage.anywhereCaches.pause", - // "parameterOrder": [ - // "bucket", - // "anywhereCacheId" - // ], - // "parameters": { - // "anywhereCacheId": { - // "description": "The ID of requested Anywhere Cache instance.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches/{anywhereCacheId}/pause", - // "response": { - // "$ref": "AnywhereCache" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.anywhereCaches.resume": +} type AnywhereCachesResumeCall struct { s *Service @@ -4060,23 +3146,21 @@ func (r *AnywhereCachesService) Resume(bucket string, anywhereCacheId string) *A } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesResumeCall) Fields(s ...googleapi.Field) *AnywhereCachesResumeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesResumeCall) Context(ctx context.Context) *AnywhereCachesResumeCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesResumeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -4085,12 +3169,7 @@ func (c *AnywhereCachesResumeCall) Header() http.Header { } func (c *AnywhereCachesResumeCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -4109,12 +3188,10 @@ func (c *AnywhereCachesResumeCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.anywhereCaches.resume" call. -// Exactly one of *AnywhereCache or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *AnywhereCache.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *AnywhereCache.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *AnywhereCachesResumeCall) Do(opts ...googleapi.CallOption) (*AnywhereCache, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -4145,42 +3222,7 @@ func (c *AnywhereCachesResumeCall) Do(opts ...googleapi.CallOption) (*AnywhereCa return nil, err } return ret, nil - // { - // "description": "Resumes a paused or disabled Anywhere Cache instance.", - // "httpMethod": "POST", - // "id": "storage.anywhereCaches.resume", - // "parameterOrder": [ - // "bucket", - // "anywhereCacheId" - // ], - // "parameters": { - // "anywhereCacheId": { - // "description": "The ID of requested Anywhere Cache instance.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches/{anywhereCacheId}/resume", - // "response": { - // "$ref": "AnywhereCache" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.anywhereCaches.update": +} type AnywhereCachesUpdateCall struct { s *Service @@ -4192,8 +3234,8 @@ type AnywhereCachesUpdateCall struct { header_ http.Header } -// Update: Updates the config(ttl and admissionPolicy) of an Anywhere -// Cache instance. +// Update: Updates the config(ttl and admissionPolicy) of an Anywhere Cache +// instance. // // - anywhereCacheId: The ID of requested Anywhere Cache instance. // - bucket: Name of the parent bucket. @@ -4206,23 +3248,21 @@ func (r *AnywhereCachesService) Update(bucket string, anywhereCacheId string, an } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *AnywhereCachesUpdateCall) Fields(s ...googleapi.Field) *AnywhereCachesUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *AnywhereCachesUpdateCall) Context(ctx context.Context) *AnywhereCachesUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *AnywhereCachesUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -4231,18 +3271,12 @@ func (c *AnywhereCachesUpdateCall) Header() http.Header { } func (c *AnywhereCachesUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.anywherecache) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/anywhereCaches/{anywhereCacheId}") @@ -4260,12 +3294,11 @@ func (c *AnywhereCachesUpdateCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.anywhereCaches.update" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *AnywhereCachesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -4296,45 +3329,7 @@ func (c *AnywhereCachesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLong return nil, err } return ret, nil - // { - // "description": "Updates the config(ttl and admissionPolicy) of an Anywhere Cache instance.", - // "httpMethod": "PATCH", - // "id": "storage.anywhereCaches.update", - // "parameterOrder": [ - // "bucket", - // "anywhereCacheId" - // ], - // "parameters": { - // "anywhereCacheId": { - // "description": "The ID of requested Anywhere Cache instance.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "bucket": { - // "description": "Name of the parent bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/anywhereCaches/{anywhereCacheId}", - // "request": { - // "$ref": "AnywhereCache" - // }, - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.bucketAccessControls.delete": +} type BucketAccessControlsDeleteCall struct { s *Service @@ -4345,8 +3340,8 @@ type BucketAccessControlsDeleteCall struct { header_ http.Header } -// Delete: Permanently deletes the ACL entry for the specified entity on -// the specified bucket. +// Delete: Permanently deletes the ACL entry for the specified entity on the +// specified bucket. // // - bucket: Name of a bucket. // - entity: The entity holding the permission. Can be user-userId, @@ -4359,31 +3354,29 @@ func (r *BucketAccessControlsService) Delete(bucket string, entity string) *Buck return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketAccessControlsDeleteCall) UserProject(userProject string) *BucketAccessControlsDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketAccessControlsDeleteCall) Fields(s ...googleapi.Field) *BucketAccessControlsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketAccessControlsDeleteCall) Context(ctx context.Context) *BucketAccessControlsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketAccessControlsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -4392,12 +3385,7 @@ func (c *BucketAccessControlsDeleteCall) Header() http.Header { } func (c *BucketAccessControlsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -4427,43 +3415,7 @@ func (c *BucketAccessControlsDeleteCall) Do(opts ...googleapi.CallOption) error return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes the ACL entry for the specified entity on the specified bucket.", - // "httpMethod": "DELETE", - // "id": "storage.bucketAccessControls.delete", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/acl/{entity}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.bucketAccessControls.get": +} type BucketAccessControlsGetCall struct { s *Service @@ -4475,8 +3427,7 @@ type BucketAccessControlsGetCall struct { header_ http.Header } -// Get: Returns the ACL entry for the specified entity on the specified -// bucket. +// Get: Returns the ACL entry for the specified entity on the specified bucket. // // - bucket: Name of a bucket. // - entity: The entity holding the permission. Can be user-userId, @@ -4489,41 +3440,37 @@ func (r *BucketAccessControlsService) Get(bucket string, entity string) *BucketA return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketAccessControlsGetCall) UserProject(userProject string) *BucketAccessControlsGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketAccessControlsGetCall) Fields(s ...googleapi.Field) *BucketAccessControlsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *BucketAccessControlsGetCall) IfNoneMatch(entityTag string) *BucketAccessControlsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketAccessControlsGetCall) Context(ctx context.Context) *BucketAccessControlsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketAccessControlsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -4532,12 +3479,7 @@ func (c *BucketAccessControlsGetCall) Header() http.Header { } func (c *BucketAccessControlsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -4559,12 +3501,11 @@ func (c *BucketAccessControlsGetCall) doRequest(alt string) (*http.Response, err } // Do executes the "storage.bucketAccessControls.get" call. -// Exactly one of *BucketAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *BucketAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *BucketAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *BucketAccessControlsGetCall) Do(opts ...googleapi.CallOption) (*BucketAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -4595,46 +3536,7 @@ func (c *BucketAccessControlsGetCall) Do(opts ...googleapi.CallOption) (*BucketA return nil, err } return ret, nil - // { - // "description": "Returns the ACL entry for the specified entity on the specified bucket.", - // "httpMethod": "GET", - // "id": "storage.bucketAccessControls.get", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/acl/{entity}", - // "response": { - // "$ref": "BucketAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.bucketAccessControls.insert": +} type BucketAccessControlsInsertCall struct { s *Service @@ -4655,31 +3557,29 @@ func (r *BucketAccessControlsService) Insert(bucket string, bucketaccesscontrol return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketAccessControlsInsertCall) UserProject(userProject string) *BucketAccessControlsInsertCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketAccessControlsInsertCall) Fields(s ...googleapi.Field) *BucketAccessControlsInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketAccessControlsInsertCall) Context(ctx context.Context) *BucketAccessControlsInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketAccessControlsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -4688,18 +3588,12 @@ func (c *BucketAccessControlsInsertCall) Header() http.Header { } func (c *BucketAccessControlsInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bucketaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/acl") @@ -4716,12 +3610,11 @@ func (c *BucketAccessControlsInsertCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.bucketAccessControls.insert" call. -// Exactly one of *BucketAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *BucketAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *BucketAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *BucketAccessControlsInsertCall) Do(opts ...googleapi.CallOption) (*BucketAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -4752,42 +3645,7 @@ func (c *BucketAccessControlsInsertCall) Do(opts ...googleapi.CallOption) (*Buck return nil, err } return ret, nil - // { - // "description": "Creates a new ACL entry on the specified bucket.", - // "httpMethod": "POST", - // "id": "storage.bucketAccessControls.insert", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/acl", - // "request": { - // "$ref": "BucketAccessControl" - // }, - // "response": { - // "$ref": "BucketAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.bucketAccessControls.list": +} type BucketAccessControlsListCall struct { s *Service @@ -4807,41 +3665,37 @@ func (r *BucketAccessControlsService) List(bucket string) *BucketAccessControlsL return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketAccessControlsListCall) UserProject(userProject string) *BucketAccessControlsListCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketAccessControlsListCall) Fields(s ...googleapi.Field) *BucketAccessControlsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *BucketAccessControlsListCall) IfNoneMatch(entityTag string) *BucketAccessControlsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketAccessControlsListCall) Context(ctx context.Context) *BucketAccessControlsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketAccessControlsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -4850,12 +3704,7 @@ func (c *BucketAccessControlsListCall) Header() http.Header { } func (c *BucketAccessControlsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -4876,12 +3725,11 @@ func (c *BucketAccessControlsListCall) doRequest(alt string) (*http.Response, er } // Do executes the "storage.bucketAccessControls.list" call. -// Exactly one of *BucketAccessControls or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *BucketAccessControls.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *BucketAccessControls.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *BucketAccessControlsListCall) Do(opts ...googleapi.CallOption) (*BucketAccessControls, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -4912,39 +3760,7 @@ func (c *BucketAccessControlsListCall) Do(opts ...googleapi.CallOption) (*Bucket return nil, err } return ret, nil - // { - // "description": "Retrieves ACL entries on the specified bucket.", - // "httpMethod": "GET", - // "id": "storage.bucketAccessControls.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/acl", - // "response": { - // "$ref": "BucketAccessControls" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.bucketAccessControls.patch": +} type BucketAccessControlsPatchCall struct { s *Service @@ -4970,31 +3786,29 @@ func (r *BucketAccessControlsService) Patch(bucket string, entity string, bucket return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketAccessControlsPatchCall) UserProject(userProject string) *BucketAccessControlsPatchCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketAccessControlsPatchCall) Fields(s ...googleapi.Field) *BucketAccessControlsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketAccessControlsPatchCall) Context(ctx context.Context) *BucketAccessControlsPatchCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketAccessControlsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -5003,18 +3817,12 @@ func (c *BucketAccessControlsPatchCall) Header() http.Header { } func (c *BucketAccessControlsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bucketaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/acl/{entity}") @@ -5032,12 +3840,11 @@ func (c *BucketAccessControlsPatchCall) doRequest(alt string) (*http.Response, e } // Do executes the "storage.bucketAccessControls.patch" call. -// Exactly one of *BucketAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *BucketAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *BucketAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *BucketAccessControlsPatchCall) Do(opts ...googleapi.CallOption) (*BucketAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -5068,49 +3875,7 @@ func (c *BucketAccessControlsPatchCall) Do(opts ...googleapi.CallOption) (*Bucke return nil, err } return ret, nil - // { - // "description": "Patches an ACL entry on the specified bucket.", - // "httpMethod": "PATCH", - // "id": "storage.bucketAccessControls.patch", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/acl/{entity}", - // "request": { - // "$ref": "BucketAccessControl" - // }, - // "response": { - // "$ref": "BucketAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.bucketAccessControls.update": +} type BucketAccessControlsUpdateCall struct { s *Service @@ -5136,31 +3901,29 @@ func (r *BucketAccessControlsService) Update(bucket string, entity string, bucke return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketAccessControlsUpdateCall) UserProject(userProject string) *BucketAccessControlsUpdateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketAccessControlsUpdateCall) Fields(s ...googleapi.Field) *BucketAccessControlsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketAccessControlsUpdateCall) Context(ctx context.Context) *BucketAccessControlsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketAccessControlsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -5169,18 +3932,12 @@ func (c *BucketAccessControlsUpdateCall) Header() http.Header { } func (c *BucketAccessControlsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bucketaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/acl/{entity}") @@ -5198,12 +3955,11 @@ func (c *BucketAccessControlsUpdateCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.bucketAccessControls.update" call. -// Exactly one of *BucketAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *BucketAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *BucketAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *BucketAccessControlsUpdateCall) Do(opts ...googleapi.CallOption) (*BucketAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -5234,49 +3990,7 @@ func (c *BucketAccessControlsUpdateCall) Do(opts ...googleapi.CallOption) (*Buck return nil, err } return ret, nil - // { - // "description": "Updates an ACL entry on the specified bucket.", - // "httpMethod": "PUT", - // "id": "storage.bucketAccessControls.update", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/acl/{entity}", - // "request": { - // "$ref": "BucketAccessControl" - // }, - // "response": { - // "$ref": "BucketAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.buckets.delete": +} type BucketsDeleteCall struct { s *Service @@ -5295,9 +4009,8 @@ func (r *BucketsService) Delete(bucket string) *BucketsDeleteCall { return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": If set, only deletes the bucket if its -// metageneration matches this value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// If set, only deletes the bucket if its metageneration matches this value. func (c *BucketsDeleteCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *BucketsDeleteCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c @@ -5311,31 +4024,29 @@ func (c *BucketsDeleteCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch in return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsDeleteCall) UserProject(userProject string) *BucketsDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsDeleteCall) Fields(s ...googleapi.Field) *BucketsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsDeleteCall) Context(ctx context.Context) *BucketsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -5344,12 +4055,7 @@ func (c *BucketsDeleteCall) Header() http.Header { } func (c *BucketsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -5378,49 +4084,7 @@ func (c *BucketsDeleteCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes an empty bucket.", - // "httpMethod": "DELETE", - // "id": "storage.buckets.delete", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "If set, only deletes the bucket if its metageneration matches this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "If set, only deletes the bucket if its metageneration does not match this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.get": +} type BucketsGetCall struct { s *Service @@ -5440,10 +4104,9 @@ func (r *BucketsService) Get(bucket string) *BucketsGetCall { return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the return of the bucket metadata -// conditional on whether the bucket's current metageneration matches -// the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the return of the bucket metadata conditional on whether the bucket's +// current metageneration matches the given value. func (c *BucketsGetCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *BucketsGetCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c @@ -5451,15 +4114,15 @@ func (c *BucketsGetCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *Buc // IfMetagenerationNotMatch sets the optional parameter // "ifMetagenerationNotMatch": Makes the return of the bucket metadata -// conditional on whether the bucket's current metageneration does not -// match the given value. +// conditional on whether the bucket's current metageneration does not match +// the given value. func (c *BucketsGetCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *BucketsGetCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl. // // Possible values: // @@ -5470,41 +4133,37 @@ func (c *BucketsGetCall) Projection(projection string) *BucketsGetCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsGetCall) UserProject(userProject string) *BucketsGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsGetCall) Fields(s ...googleapi.Field) *BucketsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *BucketsGetCall) IfNoneMatch(entityTag string) *BucketsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsGetCall) Context(ctx context.Context) *BucketsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -5513,12 +4172,7 @@ func (c *BucketsGetCall) Header() http.Header { } func (c *BucketsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -5539,12 +4193,10 @@ func (c *BucketsGetCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.get" call. -// Exactly one of *Bucket or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Bucket.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Bucket.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsGetCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -5575,67 +4227,7 @@ func (c *BucketsGetCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { return nil, err } return ret, nil - // { - // "description": "Returns metadata for the specified bucket.", - // "httpMethod": "GET", - // "id": "storage.buckets.get", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit owner, acl and defaultObjectAcl properties." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}", - // "response": { - // "$ref": "Bucket" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.getIamPolicy": +} type BucketsGetIamPolicyCall struct { s *Service @@ -5657,49 +4249,44 @@ func (r *BucketsService) GetIamPolicy(bucket string) *BucketsGetIamPolicyCall { // OptionsRequestedPolicyVersion sets the optional parameter // "optionsRequestedPolicyVersion": The IAM policy format version to be -// returned. If the optionsRequestedPolicyVersion is for an older -// version that doesn't support part of the requested IAM policy, the -// request fails. +// returned. If the optionsRequestedPolicyVersion is for an older version that +// doesn't support part of the requested IAM policy, the request fails. func (c *BucketsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *BucketsGetIamPolicyCall { c.urlParams_.Set("optionsRequestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsGetIamPolicyCall) UserProject(userProject string) *BucketsGetIamPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsGetIamPolicyCall) Fields(s ...googleapi.Field) *BucketsGetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *BucketsGetIamPolicyCall) IfNoneMatch(entityTag string) *BucketsGetIamPolicyCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsGetIamPolicyCall) Context(ctx context.Context) *BucketsGetIamPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsGetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -5708,12 +4295,7 @@ func (c *BucketsGetIamPolicyCall) Header() http.Header { } func (c *BucketsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -5734,12 +4316,10 @@ func (c *BucketsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.buckets.getIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -5770,46 +4350,7 @@ func (c *BucketsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, err return nil, err } return ret, nil - // { - // "description": "Returns an IAM policy for the specified bucket.", - // "httpMethod": "GET", - // "id": "storage.buckets.getIamPolicy", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "optionsRequestedPolicyVersion": { - // "description": "The IAM policy format version to be returned. If the optionsRequestedPolicyVersion is for an older version that doesn't support part of the requested IAM policy, the request fails.", - // "format": "int32", - // "location": "query", - // "minimum": "1", - // "type": "integer" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/iam", - // "response": { - // "$ref": "Policy" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.buckets.insert": +} type BucketsInsertCall struct { s *Service @@ -5829,9 +4370,8 @@ func (r *BucketsService) Insert(projectid string, bucket *Bucket) *BucketsInsert return c } -// EnableObjectRetention sets the optional parameter -// "enableObjectRetention": When set to true, object retention is -// enabled for this bucket. +// EnableObjectRetention sets the optional parameter "enableObjectRetention": +// When set to true, object retention is enabled for this bucket. func (c *BucketsInsertCall) EnableObjectRetention(enableObjectRetention bool) *BucketsInsertCall { c.urlParams_.Set("enableObjectRetention", fmt.Sprint(enableObjectRetention)) return c @@ -5847,25 +4387,25 @@ func (c *BucketsInsertCall) EnableObjectRetention(enableObjectRetention bool) *B // allAuthenticatedUsers get READER access. // // "private" - Project team owners get OWNER access. -// "projectPrivate" - Project team members get access according to +// "projectPrivate" - Project team members get access according to their // -// their roles. +// roles. // -// "publicRead" - Project team owners get OWNER access, and allUsers +// "publicRead" - Project team owners get OWNER access, and allUsers get // -// get READER access. +// READER access. // -// "publicReadWrite" - Project team owners get OWNER access, and +// "publicReadWrite" - Project team owners get OWNER access, and allUsers get // -// allUsers get WRITER access. +// WRITER access. func (c *BucketsInsertCall) PredefinedAcl(predefinedAcl string) *BucketsInsertCall { c.urlParams_.Set("predefinedAcl", predefinedAcl) return c } // PredefinedDefaultObjectAcl sets the optional parameter -// "predefinedDefaultObjectAcl": Apply a predefined set of default -// object access controls to this bucket. +// "predefinedDefaultObjectAcl": Apply a predefined set of default object +// access controls to this bucket. // // Possible values: // @@ -5873,31 +4413,30 @@ func (c *BucketsInsertCall) PredefinedAcl(predefinedAcl string) *BucketsInsertCa // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *BucketsInsertCall) PredefinedDefaultObjectAcl(predefinedDefaultObjectAcl string) *BucketsInsertCall { c.urlParams_.Set("predefinedDefaultObjectAcl", predefinedDefaultObjectAcl) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl, unless the bucket resource -// specifies acl or defaultObjectAcl properties, when it defaults to -// full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl, unless the bucket resource specifies acl or +// defaultObjectAcl properties, when it defaults to full. // // Possible values: // @@ -5908,31 +4447,29 @@ func (c *BucketsInsertCall) Projection(projection string) *BucketsInsertCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *BucketsInsertCall) UserProject(userProject string) *BucketsInsertCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsInsertCall) Fields(s ...googleapi.Field) *BucketsInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsInsertCall) Context(ctx context.Context) *BucketsInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -5941,18 +4478,12 @@ func (c *BucketsInsertCall) Header() http.Header { } func (c *BucketsInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bucket) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b") @@ -5966,12 +4497,10 @@ func (c *BucketsInsertCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.insert" call. -// Exactly one of *Bucket or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Bucket.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Bucket.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsInsertCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -6002,102 +4531,7 @@ func (c *BucketsInsertCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { return nil, err } return ret, nil - // { - // "description": "Creates a new bucket.", - // "httpMethod": "POST", - // "id": "storage.buckets.insert", - // "parameterOrder": [ - // "project" - // ], - // "parameters": { - // "enableObjectRetention": { - // "default": "false", - // "description": "When set to true, object retention is enabled for this bucket.", - // "location": "query", - // "type": "boolean" - // }, - // "predefinedAcl": { - // "description": "Apply a predefined set of access controls to this bucket.", - // "enum": [ - // "authenticatedRead", - // "private", - // "projectPrivate", - // "publicRead", - // "publicReadWrite" - // ], - // "enumDescriptions": [ - // "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", - // "Project team owners get OWNER access.", - // "Project team members get access according to their roles.", - // "Project team owners get OWNER access, and allUsers get READER access.", - // "Project team owners get OWNER access, and allUsers get WRITER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "predefinedDefaultObjectAcl": { - // "description": "Apply a predefined set of default object access controls to this bucket.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "project": { - // "description": "A valid API project identifier.", - // "location": "query", - // "required": true, - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl, unless the bucket resource specifies acl or defaultObjectAcl properties, when it defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit owner, acl and defaultObjectAcl properties." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b", - // "request": { - // "$ref": "Bucket" - // }, - // "response": { - // "$ref": "Bucket" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.list": +} type BucketsListCall struct { s *Service @@ -6116,31 +4550,30 @@ func (r *BucketsService) List(projectid string) *BucketsListCall { return c } -// MaxResults sets the optional parameter "maxResults": Maximum number -// of buckets to return in a single response. The service will use this -// parameter or 1,000 items, whichever is smaller. +// MaxResults sets the optional parameter "maxResults": Maximum number of +// buckets to return in a single response. The service will use this parameter +// or 1,000 items, whichever is smaller. func (c *BucketsListCall) MaxResults(maxResults int64) *BucketsListCall { c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *BucketsListCall) PageToken(pageToken string) *BucketsListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// Prefix sets the optional parameter "prefix": Filter results to -// buckets whose names begin with this prefix. +// Prefix sets the optional parameter "prefix": Filter results to buckets whose +// names begin with this prefix. func (c *BucketsListCall) Prefix(prefix string) *BucketsListCall { c.urlParams_.Set("prefix", prefix) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl. // // Possible values: // @@ -6151,41 +4584,37 @@ func (c *BucketsListCall) Projection(projection string) *BucketsListCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *BucketsListCall) UserProject(userProject string) *BucketsListCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsListCall) Fields(s ...googleapi.Field) *BucketsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *BucketsListCall) IfNoneMatch(entityTag string) *BucketsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsListCall) Context(ctx context.Context) *BucketsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -6194,12 +4623,7 @@ func (c *BucketsListCall) Header() http.Header { } func (c *BucketsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -6217,12 +4641,10 @@ func (c *BucketsListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.list" call. -// Exactly one of *Buckets or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Buckets.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Buckets.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsListCall) Do(opts ...googleapi.CallOption) (*Buckets, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -6253,70 +4675,6 @@ func (c *BucketsListCall) Do(opts ...googleapi.CallOption) (*Buckets, error) { return nil, err } return ret, nil - // { - // "description": "Retrieves a list of buckets for a given project.", - // "httpMethod": "GET", - // "id": "storage.buckets.list", - // "parameterOrder": [ - // "project" - // ], - // "parameters": { - // "maxResults": { - // "default": "1000", - // "description": "Maximum number of buckets to return in a single response. The service will use this parameter or 1,000 items, whichever is smaller.", - // "format": "uint32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // }, - // "prefix": { - // "description": "Filter results to buckets whose names begin with this prefix.", - // "location": "query", - // "type": "string" - // }, - // "project": { - // "description": "A valid API project identifier.", - // "location": "query", - // "required": true, - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit owner, acl and defaultObjectAcl properties." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b", - // "response": { - // "$ref": "Buckets" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - } // Pages invokes f for each page of results. @@ -6324,7 +4682,7 @@ func (c *BucketsListCall) Do(opts ...googleapi.CallOption) (*Buckets, error) { // The provided context supersedes any context provided to the Context method. func (c *BucketsListCall) Pages(ctx context.Context, f func(*Buckets) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -6340,8 +4698,6 @@ func (c *BucketsListCall) Pages(ctx context.Context, f func(*Buckets) error) err } } -// method id "storage.buckets.lockRetentionPolicy": - type BucketsLockRetentionPolicyCall struct { s *Service bucket string @@ -6353,8 +4709,8 @@ type BucketsLockRetentionPolicyCall struct { // LockRetentionPolicy: Locks retention policy on a bucket. // // - bucket: Name of a bucket. -// - ifMetagenerationMatch: Makes the operation conditional on whether -// bucket's current metageneration matches the given value. +// - ifMetagenerationMatch: Makes the operation conditional on whether bucket's +// current metageneration matches the given value. func (r *BucketsService) LockRetentionPolicy(bucket string, ifMetagenerationMatch int64) *BucketsLockRetentionPolicyCall { c := &BucketsLockRetentionPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.bucket = bucket @@ -6362,31 +4718,29 @@ func (r *BucketsService) LockRetentionPolicy(bucket string, ifMetagenerationMatc return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsLockRetentionPolicyCall) UserProject(userProject string) *BucketsLockRetentionPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsLockRetentionPolicyCall) Fields(s ...googleapi.Field) *BucketsLockRetentionPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsLockRetentionPolicyCall) Context(ctx context.Context) *BucketsLockRetentionPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsLockRetentionPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -6395,12 +4749,7 @@ func (c *BucketsLockRetentionPolicyCall) Header() http.Header { } func (c *BucketsLockRetentionPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -6418,12 +4767,10 @@ func (c *BucketsLockRetentionPolicyCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.buckets.lockRetentionPolicy" call. -// Exactly one of *Bucket or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Bucket.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Bucket.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsLockRetentionPolicyCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -6454,48 +4801,7 @@ func (c *BucketsLockRetentionPolicyCall) Do(opts ...googleapi.CallOption) (*Buck return nil, err } return ret, nil - // { - // "description": "Locks retention policy on a bucket.", - // "httpMethod": "POST", - // "id": "storage.buckets.lockRetentionPolicy", - // "parameterOrder": [ - // "bucket", - // "ifMetagenerationMatch" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether bucket's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/lockRetentionPolicy", - // "response": { - // "$ref": "Bucket" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.patch": +} type BucketsPatchCall struct { s *Service @@ -6506,9 +4812,8 @@ type BucketsPatchCall struct { header_ http.Header } -// Patch: Patches a bucket. Changes to the bucket will be readable -// immediately after writing, but configuration changes may take time to -// propagate. +// Patch: Patches a bucket. Changes to the bucket will be readable immediately +// after writing, but configuration changes may take time to propagate. // // - bucket: Name of a bucket. func (r *BucketsService) Patch(bucket string, bucket2 *Bucket) *BucketsPatchCall { @@ -6518,10 +4823,9 @@ func (r *BucketsService) Patch(bucket string, bucket2 *Bucket) *BucketsPatchCall return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the return of the bucket metadata -// conditional on whether the bucket's current metageneration matches -// the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the return of the bucket metadata conditional on whether the bucket's +// current metageneration matches the given value. func (c *BucketsPatchCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *BucketsPatchCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c @@ -6529,8 +4833,8 @@ func (c *BucketsPatchCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *B // IfMetagenerationNotMatch sets the optional parameter // "ifMetagenerationNotMatch": Makes the return of the bucket metadata -// conditional on whether the bucket's current metageneration does not -// match the given value. +// conditional on whether the bucket's current metageneration does not match +// the given value. func (c *BucketsPatchCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *BucketsPatchCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c @@ -6546,25 +4850,25 @@ func (c *BucketsPatchCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int // allAuthenticatedUsers get READER access. // // "private" - Project team owners get OWNER access. -// "projectPrivate" - Project team members get access according to +// "projectPrivate" - Project team members get access according to their // -// their roles. +// roles. // -// "publicRead" - Project team owners get OWNER access, and allUsers +// "publicRead" - Project team owners get OWNER access, and allUsers get // -// get READER access. +// READER access. // -// "publicReadWrite" - Project team owners get OWNER access, and +// "publicReadWrite" - Project team owners get OWNER access, and allUsers get // -// allUsers get WRITER access. +// WRITER access. func (c *BucketsPatchCall) PredefinedAcl(predefinedAcl string) *BucketsPatchCall { c.urlParams_.Set("predefinedAcl", predefinedAcl) return c } // PredefinedDefaultObjectAcl sets the optional parameter -// "predefinedDefaultObjectAcl": Apply a predefined set of default -// object access controls to this bucket. +// "predefinedDefaultObjectAcl": Apply a predefined set of default object +// access controls to this bucket. // // Possible values: // @@ -6572,29 +4876,29 @@ func (c *BucketsPatchCall) PredefinedAcl(predefinedAcl string) *BucketsPatchCall // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *BucketsPatchCall) PredefinedDefaultObjectAcl(predefinedDefaultObjectAcl string) *BucketsPatchCall { c.urlParams_.Set("predefinedDefaultObjectAcl", predefinedDefaultObjectAcl) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to full. // // Possible values: // @@ -6605,31 +4909,29 @@ func (c *BucketsPatchCall) Projection(projection string) *BucketsPatchCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsPatchCall) UserProject(userProject string) *BucketsPatchCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsPatchCall) Fields(s ...googleapi.Field) *BucketsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsPatchCall) Context(ctx context.Context) *BucketsPatchCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -6638,18 +4940,12 @@ func (c *BucketsPatchCall) Header() http.Header { } func (c *BucketsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bucket2) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}") @@ -6666,12 +4962,10 @@ func (c *BucketsPatchCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.patch" call. -// Exactly one of *Bucket or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Bucket.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Bucket.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsPatchCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -6702,107 +4996,7 @@ func (c *BucketsPatchCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { return nil, err } return ret, nil - // { - // "description": "Patches a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate.", - // "httpMethod": "PATCH", - // "id": "storage.buckets.patch", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "predefinedAcl": { - // "description": "Apply a predefined set of access controls to this bucket.", - // "enum": [ - // "authenticatedRead", - // "private", - // "projectPrivate", - // "publicRead", - // "publicReadWrite" - // ], - // "enumDescriptions": [ - // "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", - // "Project team owners get OWNER access.", - // "Project team members get access according to their roles.", - // "Project team owners get OWNER access, and allUsers get READER access.", - // "Project team owners get OWNER access, and allUsers get WRITER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "predefinedDefaultObjectAcl": { - // "description": "Apply a predefined set of default object access controls to this bucket.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit owner, acl and defaultObjectAcl properties." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}", - // "request": { - // "$ref": "Bucket" - // }, - // "response": { - // "$ref": "Bucket" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.buckets.setIamPolicy": +} type BucketsSetIamPolicyCall struct { s *Service @@ -6823,31 +5017,29 @@ func (r *BucketsService) SetIamPolicy(bucket string, policy *Policy) *BucketsSet return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsSetIamPolicyCall) UserProject(userProject string) *BucketsSetIamPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsSetIamPolicyCall) Fields(s ...googleapi.Field) *BucketsSetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsSetIamPolicyCall) Context(ctx context.Context) *BucketsSetIamPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsSetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -6856,18 +5048,12 @@ func (c *BucketsSetIamPolicyCall) Header() http.Header { } func (c *BucketsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.policy) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/iam") @@ -6884,12 +5070,10 @@ func (c *BucketsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.buckets.setIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -6920,42 +5104,7 @@ func (c *BucketsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, err return nil, err } return ret, nil - // { - // "description": "Updates an IAM policy for the specified bucket.", - // "httpMethod": "PUT", - // "id": "storage.buckets.setIamPolicy", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/iam", - // "request": { - // "$ref": "Policy" - // }, - // "response": { - // "$ref": "Policy" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.buckets.testIamPermissions": +} type BucketsTestIamPermissionsCall struct { s *Service @@ -6966,8 +5115,8 @@ type BucketsTestIamPermissionsCall struct { header_ http.Header } -// TestIamPermissions: Tests a set of permissions on the given bucket to -// see which, if any, are held by the caller. +// TestIamPermissions: Tests a set of permissions on the given bucket to see +// which, if any, are held by the caller. // // - bucket: Name of a bucket. // - permissions: Permissions to test. @@ -6978,41 +5127,37 @@ func (r *BucketsService) TestIamPermissions(bucket string, permissions []string) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsTestIamPermissionsCall) UserProject(userProject string) *BucketsTestIamPermissionsCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsTestIamPermissionsCall) Fields(s ...googleapi.Field) *BucketsTestIamPermissionsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *BucketsTestIamPermissionsCall) IfNoneMatch(entityTag string) *BucketsTestIamPermissionsCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsTestIamPermissionsCall) Context(ctx context.Context) *BucketsTestIamPermissionsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsTestIamPermissionsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -7021,12 +5166,7 @@ func (c *BucketsTestIamPermissionsCall) Header() http.Header { } func (c *BucketsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -7047,12 +5187,11 @@ func (c *BucketsTestIamPermissionsCall) doRequest(alt string) (*http.Response, e } // Do executes the "storage.buckets.testIamPermissions" call. -// Exactly one of *TestIamPermissionsResponse or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *TestIamPermissionsResponse.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *TestIamPermissionsResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *BucketsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -7083,50 +5222,7 @@ func (c *BucketsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestI return nil, err } return ret, nil - // { - // "description": "Tests a set of permissions on the given bucket to see which, if any, are held by the caller.", - // "httpMethod": "GET", - // "id": "storage.buckets.testIamPermissions", - // "parameterOrder": [ - // "bucket", - // "permissions" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "permissions": { - // "description": "Permissions to test.", - // "location": "query", - // "repeated": true, - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/iam/testPermissions", - // "response": { - // "$ref": "TestIamPermissionsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.update": +} type BucketsUpdateCall struct { s *Service @@ -7137,9 +5233,8 @@ type BucketsUpdateCall struct { header_ http.Header } -// Update: Updates a bucket. Changes to the bucket will be readable -// immediately after writing, but configuration changes may take time to -// propagate. +// Update: Updates a bucket. Changes to the bucket will be readable immediately +// after writing, but configuration changes may take time to propagate. // // - bucket: Name of a bucket. func (r *BucketsService) Update(bucket string, bucket2 *Bucket) *BucketsUpdateCall { @@ -7149,10 +5244,9 @@ func (r *BucketsService) Update(bucket string, bucket2 *Bucket) *BucketsUpdateCa return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the return of the bucket metadata -// conditional on whether the bucket's current metageneration matches -// the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the return of the bucket metadata conditional on whether the bucket's +// current metageneration matches the given value. func (c *BucketsUpdateCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *BucketsUpdateCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c @@ -7160,8 +5254,8 @@ func (c *BucketsUpdateCall) IfMetagenerationMatch(ifMetagenerationMatch int64) * // IfMetagenerationNotMatch sets the optional parameter // "ifMetagenerationNotMatch": Makes the return of the bucket metadata -// conditional on whether the bucket's current metageneration does not -// match the given value. +// conditional on whether the bucket's current metageneration does not match +// the given value. func (c *BucketsUpdateCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *BucketsUpdateCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c @@ -7177,25 +5271,25 @@ func (c *BucketsUpdateCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch in // allAuthenticatedUsers get READER access. // // "private" - Project team owners get OWNER access. -// "projectPrivate" - Project team members get access according to +// "projectPrivate" - Project team members get access according to their // -// their roles. +// roles. // -// "publicRead" - Project team owners get OWNER access, and allUsers +// "publicRead" - Project team owners get OWNER access, and allUsers get // -// get READER access. +// READER access. // -// "publicReadWrite" - Project team owners get OWNER access, and +// "publicReadWrite" - Project team owners get OWNER access, and allUsers get // -// allUsers get WRITER access. +// WRITER access. func (c *BucketsUpdateCall) PredefinedAcl(predefinedAcl string) *BucketsUpdateCall { c.urlParams_.Set("predefinedAcl", predefinedAcl) return c } // PredefinedDefaultObjectAcl sets the optional parameter -// "predefinedDefaultObjectAcl": Apply a predefined set of default -// object access controls to this bucket. +// "predefinedDefaultObjectAcl": Apply a predefined set of default object +// access controls to this bucket. // // Possible values: // @@ -7203,29 +5297,29 @@ func (c *BucketsUpdateCall) PredefinedAcl(predefinedAcl string) *BucketsUpdateCa // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *BucketsUpdateCall) PredefinedDefaultObjectAcl(predefinedDefaultObjectAcl string) *BucketsUpdateCall { c.urlParams_.Set("predefinedDefaultObjectAcl", predefinedDefaultObjectAcl) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to full. // // Possible values: // @@ -7236,31 +5330,29 @@ func (c *BucketsUpdateCall) Projection(projection string) *BucketsUpdateCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *BucketsUpdateCall) UserProject(userProject string) *BucketsUpdateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *BucketsUpdateCall) Fields(s ...googleapi.Field) *BucketsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *BucketsUpdateCall) Context(ctx context.Context) *BucketsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *BucketsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -7269,18 +5361,12 @@ func (c *BucketsUpdateCall) Header() http.Header { } func (c *BucketsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bucket2) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}") @@ -7297,12 +5383,10 @@ func (c *BucketsUpdateCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.update" call. -// Exactly one of *Bucket or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Bucket.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Bucket.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *BucketsUpdateCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -7333,107 +5417,7 @@ func (c *BucketsUpdateCall) Do(opts ...googleapi.CallOption) (*Bucket, error) { return nil, err } return ret, nil - // { - // "description": "Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate.", - // "httpMethod": "PUT", - // "id": "storage.buckets.update", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "predefinedAcl": { - // "description": "Apply a predefined set of access controls to this bucket.", - // "enum": [ - // "authenticatedRead", - // "private", - // "projectPrivate", - // "publicRead", - // "publicReadWrite" - // ], - // "enumDescriptions": [ - // "Project team owners get OWNER access, and allAuthenticatedUsers get READER access.", - // "Project team owners get OWNER access.", - // "Project team members get access according to their roles.", - // "Project team owners get OWNER access, and allUsers get READER access.", - // "Project team owners get OWNER access, and allUsers get WRITER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "predefinedDefaultObjectAcl": { - // "description": "Apply a predefined set of default object access controls to this bucket.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit owner, acl and defaultObjectAcl properties." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}", - // "request": { - // "$ref": "Bucket" - // }, - // "response": { - // "$ref": "Bucket" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.channels.stop": +} type ChannelsStopCall struct { s *Service @@ -7451,23 +5435,21 @@ func (r *ChannelsService) Stop(channel *Channel) *ChannelsStopCall { } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ChannelsStopCall) Fields(s ...googleapi.Field) *ChannelsStopCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ChannelsStopCall) Context(ctx context.Context) *ChannelsStopCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ChannelsStopCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -7476,18 +5458,12 @@ func (c *ChannelsStopCall) Header() http.Header { } func (c *ChannelsStopCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.channel) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "channels/stop") @@ -7512,27 +5488,7 @@ func (c *ChannelsStopCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Stop watching resources through this channel", - // "httpMethod": "POST", - // "id": "storage.channels.stop", - // "path": "channels/stop", - // "request": { - // "$ref": "Channel", - // "parameterName": "resource" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.defaultObjectAccessControls.delete": +} type DefaultObjectAccessControlsDeleteCall struct { s *Service @@ -7543,8 +5499,8 @@ type DefaultObjectAccessControlsDeleteCall struct { header_ http.Header } -// Delete: Permanently deletes the default object ACL entry for the -// specified entity on the specified bucket. +// Delete: Permanently deletes the default object ACL entry for the specified +// entity on the specified bucket. // // - bucket: Name of a bucket. // - entity: The entity holding the permission. Can be user-userId, @@ -7557,31 +5513,29 @@ func (r *DefaultObjectAccessControlsService) Delete(bucket string, entity string return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *DefaultObjectAccessControlsDeleteCall) UserProject(userProject string) *DefaultObjectAccessControlsDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *DefaultObjectAccessControlsDeleteCall) Fields(s ...googleapi.Field) *DefaultObjectAccessControlsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *DefaultObjectAccessControlsDeleteCall) Context(ctx context.Context) *DefaultObjectAccessControlsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *DefaultObjectAccessControlsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -7590,12 +5544,7 @@ func (c *DefaultObjectAccessControlsDeleteCall) Header() http.Header { } func (c *DefaultObjectAccessControlsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -7625,43 +5574,7 @@ func (c *DefaultObjectAccessControlsDeleteCall) Do(opts ...googleapi.CallOption) return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes the default object ACL entry for the specified entity on the specified bucket.", - // "httpMethod": "DELETE", - // "id": "storage.defaultObjectAccessControls.delete", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/defaultObjectAcl/{entity}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.defaultObjectAccessControls.get": +} type DefaultObjectAccessControlsGetCall struct { s *Service @@ -7673,8 +5586,8 @@ type DefaultObjectAccessControlsGetCall struct { header_ http.Header } -// Get: Returns the default object ACL entry for the specified entity on -// the specified bucket. +// Get: Returns the default object ACL entry for the specified entity on the +// specified bucket. // // - bucket: Name of a bucket. // - entity: The entity holding the permission. Can be user-userId, @@ -7687,41 +5600,37 @@ func (r *DefaultObjectAccessControlsService) Get(bucket string, entity string) * return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *DefaultObjectAccessControlsGetCall) UserProject(userProject string) *DefaultObjectAccessControlsGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *DefaultObjectAccessControlsGetCall) Fields(s ...googleapi.Field) *DefaultObjectAccessControlsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *DefaultObjectAccessControlsGetCall) IfNoneMatch(entityTag string) *DefaultObjectAccessControlsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *DefaultObjectAccessControlsGetCall) Context(ctx context.Context) *DefaultObjectAccessControlsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *DefaultObjectAccessControlsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -7730,12 +5639,7 @@ func (c *DefaultObjectAccessControlsGetCall) Header() http.Header { } func (c *DefaultObjectAccessControlsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -7757,12 +5661,11 @@ func (c *DefaultObjectAccessControlsGetCall) doRequest(alt string) (*http.Respon } // Do executes the "storage.defaultObjectAccessControls.get" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *DefaultObjectAccessControlsGetCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -7793,46 +5696,7 @@ func (c *DefaultObjectAccessControlsGetCall) Do(opts ...googleapi.CallOption) (* return nil, err } return ret, nil - // { - // "description": "Returns the default object ACL entry for the specified entity on the specified bucket.", - // "httpMethod": "GET", - // "id": "storage.defaultObjectAccessControls.get", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/defaultObjectAcl/{entity}", - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.defaultObjectAccessControls.insert": +} type DefaultObjectAccessControlsInsertCall struct { s *Service @@ -7843,8 +5707,7 @@ type DefaultObjectAccessControlsInsertCall struct { header_ http.Header } -// Insert: Creates a new default object ACL entry on the specified -// bucket. +// Insert: Creates a new default object ACL entry on the specified bucket. // // - bucket: Name of a bucket. func (r *DefaultObjectAccessControlsService) Insert(bucket string, objectaccesscontrol *ObjectAccessControl) *DefaultObjectAccessControlsInsertCall { @@ -7854,31 +5717,29 @@ func (r *DefaultObjectAccessControlsService) Insert(bucket string, objectaccessc return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *DefaultObjectAccessControlsInsertCall) UserProject(userProject string) *DefaultObjectAccessControlsInsertCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *DefaultObjectAccessControlsInsertCall) Fields(s ...googleapi.Field) *DefaultObjectAccessControlsInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *DefaultObjectAccessControlsInsertCall) Context(ctx context.Context) *DefaultObjectAccessControlsInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *DefaultObjectAccessControlsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -7887,18 +5748,12 @@ func (c *DefaultObjectAccessControlsInsertCall) Header() http.Header { } func (c *DefaultObjectAccessControlsInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.objectaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/defaultObjectAcl") @@ -7915,12 +5770,11 @@ func (c *DefaultObjectAccessControlsInsertCall) doRequest(alt string) (*http.Res } // Do executes the "storage.defaultObjectAccessControls.insert" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *DefaultObjectAccessControlsInsertCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -7951,42 +5805,7 @@ func (c *DefaultObjectAccessControlsInsertCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Creates a new default object ACL entry on the specified bucket.", - // "httpMethod": "POST", - // "id": "storage.defaultObjectAccessControls.insert", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/defaultObjectAcl", - // "request": { - // "$ref": "ObjectAccessControl" - // }, - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.defaultObjectAccessControls.list": +} type DefaultObjectAccessControlsListCall struct { s *Service @@ -8006,58 +5825,53 @@ func (r *DefaultObjectAccessControlsService) List(bucket string) *DefaultObjectA return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": If present, only return default ACL listing -// if the bucket's current metageneration matches this value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// If present, only return default ACL listing if the bucket's current +// metageneration matches this value. func (c *DefaultObjectAccessControlsListCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *DefaultObjectAccessControlsListCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": If present, only return default ACL -// listing if the bucket's current metageneration does not match the -// given value. +// "ifMetagenerationNotMatch": If present, only return default ACL listing if +// the bucket's current metageneration does not match the given value. func (c *DefaultObjectAccessControlsListCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *DefaultObjectAccessControlsListCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *DefaultObjectAccessControlsListCall) UserProject(userProject string) *DefaultObjectAccessControlsListCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *DefaultObjectAccessControlsListCall) Fields(s ...googleapi.Field) *DefaultObjectAccessControlsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *DefaultObjectAccessControlsListCall) IfNoneMatch(entityTag string) *DefaultObjectAccessControlsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *DefaultObjectAccessControlsListCall) Context(ctx context.Context) *DefaultObjectAccessControlsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *DefaultObjectAccessControlsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -8066,12 +5880,7 @@ func (c *DefaultObjectAccessControlsListCall) Header() http.Header { } func (c *DefaultObjectAccessControlsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -8092,12 +5901,11 @@ func (c *DefaultObjectAccessControlsListCall) doRequest(alt string) (*http.Respo } // Do executes the "storage.defaultObjectAccessControls.list" call. -// Exactly one of *ObjectAccessControls or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControls.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControls.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *DefaultObjectAccessControlsListCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControls, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -8128,51 +5936,7 @@ func (c *DefaultObjectAccessControlsListCall) Do(opts ...googleapi.CallOption) ( return nil, err } return ret, nil - // { - // "description": "Retrieves default object ACL entries on the specified bucket.", - // "httpMethod": "GET", - // "id": "storage.defaultObjectAccessControls.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "If present, only return default ACL listing if the bucket's current metageneration matches this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "If present, only return default ACL listing if the bucket's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/defaultObjectAcl", - // "response": { - // "$ref": "ObjectAccessControls" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.defaultObjectAccessControls.patch": +} type DefaultObjectAccessControlsPatchCall struct { s *Service @@ -8198,31 +5962,29 @@ func (r *DefaultObjectAccessControlsService) Patch(bucket string, entity string, return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *DefaultObjectAccessControlsPatchCall) UserProject(userProject string) *DefaultObjectAccessControlsPatchCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *DefaultObjectAccessControlsPatchCall) Fields(s ...googleapi.Field) *DefaultObjectAccessControlsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *DefaultObjectAccessControlsPatchCall) Context(ctx context.Context) *DefaultObjectAccessControlsPatchCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *DefaultObjectAccessControlsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -8231,18 +5993,12 @@ func (c *DefaultObjectAccessControlsPatchCall) Header() http.Header { } func (c *DefaultObjectAccessControlsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.objectaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/defaultObjectAcl/{entity}") @@ -8260,12 +6016,11 @@ func (c *DefaultObjectAccessControlsPatchCall) doRequest(alt string) (*http.Resp } // Do executes the "storage.defaultObjectAccessControls.patch" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *DefaultObjectAccessControlsPatchCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -8296,49 +6051,7 @@ func (c *DefaultObjectAccessControlsPatchCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Patches a default object ACL entry on the specified bucket.", - // "httpMethod": "PATCH", - // "id": "storage.defaultObjectAccessControls.patch", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/defaultObjectAcl/{entity}", - // "request": { - // "$ref": "ObjectAccessControl" - // }, - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.defaultObjectAccessControls.update": +} type DefaultObjectAccessControlsUpdateCall struct { s *Service @@ -8364,31 +6077,29 @@ func (r *DefaultObjectAccessControlsService) Update(bucket string, entity string return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *DefaultObjectAccessControlsUpdateCall) UserProject(userProject string) *DefaultObjectAccessControlsUpdateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *DefaultObjectAccessControlsUpdateCall) Fields(s ...googleapi.Field) *DefaultObjectAccessControlsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *DefaultObjectAccessControlsUpdateCall) Context(ctx context.Context) *DefaultObjectAccessControlsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *DefaultObjectAccessControlsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -8397,18 +6108,12 @@ func (c *DefaultObjectAccessControlsUpdateCall) Header() http.Header { } func (c *DefaultObjectAccessControlsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.objectaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/defaultObjectAcl/{entity}") @@ -8426,12 +6131,11 @@ func (c *DefaultObjectAccessControlsUpdateCall) doRequest(alt string) (*http.Res } // Do executes the "storage.defaultObjectAccessControls.update" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *DefaultObjectAccessControlsUpdateCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -8462,49 +6166,7 @@ func (c *DefaultObjectAccessControlsUpdateCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Updates a default object ACL entry on the specified bucket.", - // "httpMethod": "PUT", - // "id": "storage.defaultObjectAccessControls.update", - // "parameterOrder": [ - // "bucket", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/defaultObjectAcl/{entity}", - // "request": { - // "$ref": "ObjectAccessControl" - // }, - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.folders.delete": +} type FoldersDeleteCall struct { s *Service @@ -8527,9 +6189,8 @@ func (r *FoldersService) Delete(bucket string, folder string) *FoldersDeleteCall return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": If set, only deletes the folder if its -// metageneration matches this value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// If set, only deletes the folder if its metageneration matches this value. func (c *FoldersDeleteCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *FoldersDeleteCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c @@ -8544,23 +6205,21 @@ func (c *FoldersDeleteCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch in } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *FoldersDeleteCall) Fields(s ...googleapi.Field) *FoldersDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *FoldersDeleteCall) Context(ctx context.Context) *FoldersDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *FoldersDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -8569,12 +6228,7 @@ func (c *FoldersDeleteCall) Header() http.Header { } func (c *FoldersDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -8604,51 +6258,7 @@ func (c *FoldersDeleteCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes a folder. Only applicable to buckets with hierarchical namespace enabled.", - // "httpMethod": "DELETE", - // "id": "storage.folders.delete", - // "parameterOrder": [ - // "bucket", - // "folder" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the folder resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "folder": { - // "description": "Name of a folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "If set, only deletes the folder if its metageneration matches this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "If set, only deletes the folder if its metageneration does not match this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/folders/{folder}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.folders.get": +} type FoldersGetCall struct { s *Service @@ -8660,8 +6270,8 @@ type FoldersGetCall struct { header_ http.Header } -// Get: Returns metadata for the specified folder. Only applicable to -// buckets with hierarchical namespace enabled. +// Get: Returns metadata for the specified folder. Only applicable to buckets +// with hierarchical namespace enabled. // // - bucket: Name of the bucket in which the folder resides. // - folder: Name of a folder. @@ -8672,10 +6282,9 @@ func (r *FoldersService) Get(bucket string, folder string) *FoldersGetCall { return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the return of the folder metadata -// conditional on whether the folder's current metageneration matches -// the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the return of the folder metadata conditional on whether the folder's +// current metageneration matches the given value. func (c *FoldersGetCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *FoldersGetCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c @@ -8683,41 +6292,37 @@ func (c *FoldersGetCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *Fol // IfMetagenerationNotMatch sets the optional parameter // "ifMetagenerationNotMatch": Makes the return of the folder metadata -// conditional on whether the folder's current metageneration does not -// match the given value. +// conditional on whether the folder's current metageneration does not match +// the given value. func (c *FoldersGetCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *FoldersGetCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *FoldersGetCall) Fields(s ...googleapi.Field) *FoldersGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *FoldersGetCall) IfNoneMatch(entityTag string) *FoldersGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *FoldersGetCall) Context(ctx context.Context) *FoldersGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *FoldersGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -8726,12 +6331,7 @@ func (c *FoldersGetCall) Header() http.Header { } func (c *FoldersGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -8753,12 +6353,10 @@ func (c *FoldersGetCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.folders.get" call. -// Exactly one of *Folder or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Folder.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Folder.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *FoldersGetCall) Do(opts ...googleapi.CallOption) (*Folder, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -8789,56 +6387,7 @@ func (c *FoldersGetCall) Do(opts ...googleapi.CallOption) (*Folder, error) { return nil, err } return ret, nil - // { - // "description": "Returns metadata for the specified folder. Only applicable to buckets with hierarchical namespace enabled.", - // "httpMethod": "GET", - // "id": "storage.folders.get", - // "parameterOrder": [ - // "bucket", - // "folder" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the folder resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "folder": { - // "description": "Name of a folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the return of the folder metadata conditional on whether the folder's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the return of the folder metadata conditional on whether the folder's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/folders/{folder}", - // "response": { - // "$ref": "Folder" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.folders.insert": +} type FoldersInsertCall struct { s *Service @@ -8849,8 +6398,8 @@ type FoldersInsertCall struct { header_ http.Header } -// Insert: Creates a new folder. Only applicable to buckets with -// hierarchical namespace enabled. +// Insert: Creates a new folder. Only applicable to buckets with hierarchical +// namespace enabled. // // - bucket: Name of the bucket in which the folder resides. func (r *FoldersService) Insert(bucket string, folder *Folder) *FoldersInsertCall { @@ -8860,31 +6409,29 @@ func (r *FoldersService) Insert(bucket string, folder *Folder) *FoldersInsertCal return c } -// Recursive sets the optional parameter "recursive": If true, any -// parent folder which doesn’t exist will be created automatically. +// Recursive sets the optional parameter "recursive": If true, any parent +// folder which doesn’t exist will be created automatically. func (c *FoldersInsertCall) Recursive(recursive bool) *FoldersInsertCall { c.urlParams_.Set("recursive", fmt.Sprint(recursive)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *FoldersInsertCall) Fields(s ...googleapi.Field) *FoldersInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *FoldersInsertCall) Context(ctx context.Context) *FoldersInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *FoldersInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -8893,18 +6440,12 @@ func (c *FoldersInsertCall) Header() http.Header { } func (c *FoldersInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.folder) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/folders") @@ -8921,12 +6462,10 @@ func (c *FoldersInsertCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.folders.insert" call. -// Exactly one of *Folder or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Folder.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Folder.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *FoldersInsertCall) Do(opts ...googleapi.CallOption) (*Folder, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -8957,43 +6496,7 @@ func (c *FoldersInsertCall) Do(opts ...googleapi.CallOption) (*Folder, error) { return nil, err } return ret, nil - // { - // "description": "Creates a new folder. Only applicable to buckets with hierarchical namespace enabled.", - // "httpMethod": "POST", - // "id": "storage.folders.insert", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the folder resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "recursive": { - // "description": "If true, any parent folder which doesn’t exist will be created automatically.", - // "location": "query", - // "type": "boolean" - // } - // }, - // "path": "b/{bucket}/folders", - // "request": { - // "$ref": "Folder" - // }, - // "response": { - // "$ref": "Folder" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.folders.list": +} type FoldersListCall struct { s *Service @@ -9004,8 +6507,8 @@ type FoldersListCall struct { header_ http.Header } -// List: Retrieves a list of folders matching the criteria. Only -// applicable to buckets with hierarchical namespace enabled. +// List: Retrieves a list of folders matching the criteria. Only applicable to +// buckets with hierarchical namespace enabled. // // - bucket: Name of the bucket in which to look for folders. func (r *FoldersService) List(bucket string) *FoldersListCall { @@ -9014,84 +6517,79 @@ func (r *FoldersService) List(bucket string) *FoldersListCall { return c } -// Delimiter sets the optional parameter "delimiter": Returns results in -// a directory-like mode. The only supported value is '/'. If set, items -// will only contain folders that either exactly match the prefix, or -// are one level below the prefix. +// Delimiter sets the optional parameter "delimiter": Returns results in a +// directory-like mode. The only supported value is '/'. If set, items will +// only contain folders that either exactly match the prefix, or are one level +// below the prefix. func (c *FoldersListCall) Delimiter(delimiter string) *FoldersListCall { c.urlParams_.Set("delimiter", delimiter) return c } -// EndOffset sets the optional parameter "endOffset": Filter results to -// folders whose names are lexicographically before endOffset. If -// startOffset is also set, the folders listed will have names between -// startOffset (inclusive) and endOffset (exclusive). +// EndOffset sets the optional parameter "endOffset": Filter results to folders +// whose names are lexicographically before endOffset. If startOffset is also +// set, the folders listed will have names between startOffset (inclusive) and +// endOffset (exclusive). func (c *FoldersListCall) EndOffset(endOffset string) *FoldersListCall { c.urlParams_.Set("endOffset", endOffset) return c } -// PageSize sets the optional parameter "pageSize": Maximum number of -// items to return in a single page of responses. +// PageSize sets the optional parameter "pageSize": Maximum number of items to +// return in a single page of responses. func (c *FoldersListCall) PageSize(pageSize int64) *FoldersListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *FoldersListCall) PageToken(pageToken string) *FoldersListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// Prefix sets the optional parameter "prefix": Filter results to -// folders whose paths begin with this prefix. If set, the value must -// either be an empty string or end with a '/'. +// Prefix sets the optional parameter "prefix": Filter results to folders whose +// paths begin with this prefix. If set, the value must either be an empty +// string or end with a '/'. func (c *FoldersListCall) Prefix(prefix string) *FoldersListCall { c.urlParams_.Set("prefix", prefix) return c } -// StartOffset sets the optional parameter "startOffset": Filter results -// to folders whose names are lexicographically equal to or after -// startOffset. If endOffset is also set, the folders listed will have -// names between startOffset (inclusive) and endOffset (exclusive). +// StartOffset sets the optional parameter "startOffset": Filter results to +// folders whose names are lexicographically equal to or after startOffset. If +// endOffset is also set, the folders listed will have names between +// startOffset (inclusive) and endOffset (exclusive). func (c *FoldersListCall) StartOffset(startOffset string) *FoldersListCall { c.urlParams_.Set("startOffset", startOffset) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *FoldersListCall) Fields(s ...googleapi.Field) *FoldersListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *FoldersListCall) IfNoneMatch(entityTag string) *FoldersListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *FoldersListCall) Context(ctx context.Context) *FoldersListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *FoldersListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -9100,12 +6598,7 @@ func (c *FoldersListCall) Header() http.Header { } func (c *FoldersListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -9126,12 +6619,10 @@ func (c *FoldersListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.folders.list" call. -// Exactly one of *Folders or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Folders.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Folders.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *FoldersListCall) Do(opts ...googleapi.CallOption) (*Folders, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -9162,66 +6653,6 @@ func (c *FoldersListCall) Do(opts ...googleapi.CallOption) (*Folders, error) { return nil, err } return ret, nil - // { - // "description": "Retrieves a list of folders matching the criteria. Only applicable to buckets with hierarchical namespace enabled.", - // "httpMethod": "GET", - // "id": "storage.folders.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which to look for folders.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "delimiter": { - // "description": "Returns results in a directory-like mode. The only supported value is '/'. If set, items will only contain folders that either exactly match the prefix, or are one level below the prefix.", - // "location": "query", - // "type": "string" - // }, - // "endOffset": { - // "description": "Filter results to folders whose names are lexicographically before endOffset. If startOffset is also set, the folders listed will have names between startOffset (inclusive) and endOffset (exclusive).", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Maximum number of items to return in a single page of responses.", - // "format": "int32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // }, - // "prefix": { - // "description": "Filter results to folders whose paths begin with this prefix. If set, the value must either be an empty string or end with a '/'.", - // "location": "query", - // "type": "string" - // }, - // "startOffset": { - // "description": "Filter results to folders whose names are lexicographically equal to or after startOffset. If endOffset is also set, the folders listed will have names between startOffset (inclusive) and endOffset (exclusive).", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/folders", - // "response": { - // "$ref": "Folders" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - } // Pages invokes f for each page of results. @@ -9229,7 +6660,7 @@ func (c *FoldersListCall) Do(opts ...googleapi.CallOption) (*Folders, error) { // The provided context supersedes any context provided to the Context method. func (c *FoldersListCall) Pages(ctx context.Context, f func(*Folders) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -9245,8 +6676,6 @@ func (c *FoldersListCall) Pages(ctx context.Context, f func(*Folders) error) err } } -// method id "storage.folders.rename": - type FoldersRenameCall struct { s *Service bucket string @@ -9257,8 +6686,8 @@ type FoldersRenameCall struct { header_ http.Header } -// Rename: Renames a source folder to a destination folder. Only -// applicable to buckets with hierarchical namespace enabled. +// Rename: Renames a source folder to a destination folder. Only applicable to +// buckets with hierarchical namespace enabled. // // - bucket: Name of the bucket in which the folders are in. // - destinationFolder: Name of the destination folder. @@ -9272,41 +6701,37 @@ func (r *FoldersService) Rename(bucket string, sourceFolder string, destinationF } // IfSourceMetagenerationMatch sets the optional parameter -// "ifSourceMetagenerationMatch": Makes the operation conditional on -// whether the source object's current metageneration matches the given -// value. +// "ifSourceMetagenerationMatch": Makes the operation conditional on whether +// the source object's current metageneration matches the given value. func (c *FoldersRenameCall) IfSourceMetagenerationMatch(ifSourceMetagenerationMatch int64) *FoldersRenameCall { c.urlParams_.Set("ifSourceMetagenerationMatch", fmt.Sprint(ifSourceMetagenerationMatch)) return c } // IfSourceMetagenerationNotMatch sets the optional parameter -// "ifSourceMetagenerationNotMatch": Makes the operation conditional on -// whether the source object's current metageneration does not match the -// given value. +// "ifSourceMetagenerationNotMatch": Makes the operation conditional on whether +// the source object's current metageneration does not match the given value. func (c *FoldersRenameCall) IfSourceMetagenerationNotMatch(ifSourceMetagenerationNotMatch int64) *FoldersRenameCall { c.urlParams_.Set("ifSourceMetagenerationNotMatch", fmt.Sprint(ifSourceMetagenerationNotMatch)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *FoldersRenameCall) Fields(s ...googleapi.Field) *FoldersRenameCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *FoldersRenameCall) Context(ctx context.Context) *FoldersRenameCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *FoldersRenameCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -9315,12 +6740,7 @@ func (c *FoldersRenameCall) Header() http.Header { } func (c *FoldersRenameCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -9340,12 +6760,11 @@ func (c *FoldersRenameCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.folders.rename" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *FoldersRenameCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -9376,61 +6795,7 @@ func (c *FoldersRenameCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunning return nil, err } return ret, nil - // { - // "description": "Renames a source folder to a destination folder. Only applicable to buckets with hierarchical namespace enabled.", - // "httpMethod": "POST", - // "id": "storage.folders.rename", - // "parameterOrder": [ - // "bucket", - // "sourceFolder", - // "destinationFolder" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the folders are in.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationFolder": { - // "description": "Name of the destination folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifSourceMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "sourceFolder": { - // "description": "Name of the source folder.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/folders/{sourceFolder}/renameTo/folders/{destinationFolder}", - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.managedFolders.delete": +} type ManagedFoldersDeleteCall struct { s *Service @@ -9453,49 +6818,46 @@ func (r *ManagedFoldersService) Delete(bucket string, managedFolder string) *Man } // AllowNonEmpty sets the optional parameter "allowNonEmpty": Allows the -// deletion of a managed folder even if it is not empty. A managed -// folder is empty if there are no objects or managed folders that it -// applies to. Callers must have storage.managedFolders.setIamPolicy -// permission. +// deletion of a managed folder even if it is not empty. A managed folder is +// empty if there are no objects or managed folders that it applies to. Callers +// must have storage.managedFolders.setIamPolicy permission. func (c *ManagedFoldersDeleteCall) AllowNonEmpty(allowNonEmpty bool) *ManagedFoldersDeleteCall { c.urlParams_.Set("allowNonEmpty", fmt.Sprint(allowNonEmpty)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": If set, only deletes the managed folder if -// its metageneration matches this value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// If set, only deletes the managed folder if its metageneration matches this +// value. func (c *ManagedFoldersDeleteCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ManagedFoldersDeleteCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": If set, only deletes the managed folder -// if its metageneration does not match this value. +// "ifMetagenerationNotMatch": If set, only deletes the managed folder if its +// metageneration does not match this value. func (c *ManagedFoldersDeleteCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ManagedFoldersDeleteCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersDeleteCall) Fields(s ...googleapi.Field) *ManagedFoldersDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersDeleteCall) Context(ctx context.Context) *ManagedFoldersDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -9504,12 +6866,7 @@ func (c *ManagedFoldersDeleteCall) Header() http.Header { } func (c *ManagedFoldersDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -9539,56 +6896,7 @@ func (c *ManagedFoldersDeleteCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes a managed folder.", - // "httpMethod": "DELETE", - // "id": "storage.managedFolders.delete", - // "parameterOrder": [ - // "bucket", - // "managedFolder" - // ], - // "parameters": { - // "allowNonEmpty": { - // "description": "Allows the deletion of a managed folder even if it is not empty. A managed folder is empty if there are no objects or managed folders that it applies to. Callers must have storage.managedFolders.setIamPolicy permission.", - // "location": "query", - // "type": "boolean" - // }, - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "If set, only deletes the managed folder if its metageneration matches this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "If set, only deletes the managed folder if its metageneration does not match this value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "managedFolder": { - // "description": "The managed folder name/path.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders/{managedFolder}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.managedFolders.get": +} type ManagedFoldersGetCall struct { s *Service @@ -9611,52 +6919,47 @@ func (r *ManagedFoldersService) Get(bucket string, managedFolder string) *Manage return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the return of the managed folder -// metadata conditional on whether the managed folder's current -// metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the return of the managed folder metadata conditional on whether the +// managed folder's current metageneration matches the given value. func (c *ManagedFoldersGetCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ManagedFoldersGetCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the return of the managed folder -// metadata conditional on whether the managed folder's current -// metageneration does not match the given value. +// "ifMetagenerationNotMatch": Makes the return of the managed folder metadata +// conditional on whether the managed folder's current metageneration does not +// match the given value. func (c *ManagedFoldersGetCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ManagedFoldersGetCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersGetCall) Fields(s ...googleapi.Field) *ManagedFoldersGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ManagedFoldersGetCall) IfNoneMatch(entityTag string) *ManagedFoldersGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersGetCall) Context(ctx context.Context) *ManagedFoldersGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -9665,12 +6968,7 @@ func (c *ManagedFoldersGetCall) Header() http.Header { } func (c *ManagedFoldersGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -9692,12 +6990,10 @@ func (c *ManagedFoldersGetCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.managedFolders.get" call. -// Exactly one of *ManagedFolder or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *ManagedFolder.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ManagedFolder.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ManagedFoldersGetCall) Do(opts ...googleapi.CallOption) (*ManagedFolder, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -9728,56 +7024,7 @@ func (c *ManagedFoldersGetCall) Do(opts ...googleapi.CallOption) (*ManagedFolder return nil, err } return ret, nil - // { - // "description": "Returns metadata of the specified managed folder.", - // "httpMethod": "GET", - // "id": "storage.managedFolders.get", - // "parameterOrder": [ - // "bucket", - // "managedFolder" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the return of the managed folder metadata conditional on whether the managed folder's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the return of the managed folder metadata conditional on whether the managed folder's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "managedFolder": { - // "description": "The managed folder name/path.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders/{managedFolder}", - // "response": { - // "$ref": "ManagedFolder" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.managedFolders.getIamPolicy": +} type ManagedFoldersGetIamPolicyCall struct { s *Service @@ -9802,49 +7049,44 @@ func (r *ManagedFoldersService) GetIamPolicy(bucket string, managedFolder string // OptionsRequestedPolicyVersion sets the optional parameter // "optionsRequestedPolicyVersion": The IAM policy format version to be -// returned. If the optionsRequestedPolicyVersion is for an older -// version that doesn't support part of the requested IAM policy, the -// request fails. +// returned. If the optionsRequestedPolicyVersion is for an older version that +// doesn't support part of the requested IAM policy, the request fails. func (c *ManagedFoldersGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ManagedFoldersGetIamPolicyCall { c.urlParams_.Set("optionsRequestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ManagedFoldersGetIamPolicyCall) UserProject(userProject string) *ManagedFoldersGetIamPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersGetIamPolicyCall) Fields(s ...googleapi.Field) *ManagedFoldersGetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ManagedFoldersGetIamPolicyCall) IfNoneMatch(entityTag string) *ManagedFoldersGetIamPolicyCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersGetIamPolicyCall) Context(ctx context.Context) *ManagedFoldersGetIamPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersGetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -9853,12 +7095,7 @@ func (c *ManagedFoldersGetIamPolicyCall) Header() http.Header { } func (c *ManagedFoldersGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -9880,12 +7117,10 @@ func (c *ManagedFoldersGetIamPolicyCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.managedFolders.getIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ManagedFoldersGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -9916,56 +7151,7 @@ func (c *ManagedFoldersGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Poli return nil, err } return ret, nil - // { - // "description": "Returns an IAM policy for the specified managed folder.", - // "httpMethod": "GET", - // "id": "storage.managedFolders.getIamPolicy", - // "parameterOrder": [ - // "bucket", - // "managedFolder" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "managedFolder": { - // "description": "The managed folder name/path.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "optionsRequestedPolicyVersion": { - // "description": "The IAM policy format version to be returned. If the optionsRequestedPolicyVersion is for an older version that doesn't support part of the requested IAM policy, the request fails.", - // "format": "int32", - // "location": "query", - // "minimum": "1", - // "type": "integer" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders/{managedFolder}/iam", - // "response": { - // "$ref": "Policy" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.managedFolders.insert": +} type ManagedFoldersInsertCall struct { s *Service @@ -9987,23 +7173,21 @@ func (r *ManagedFoldersService) Insert(bucket string, managedfolder *ManagedFold } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersInsertCall) Fields(s ...googleapi.Field) *ManagedFoldersInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersInsertCall) Context(ctx context.Context) *ManagedFoldersInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10012,18 +7196,12 @@ func (c *ManagedFoldersInsertCall) Header() http.Header { } func (c *ManagedFoldersInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.managedfolder) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/managedFolders") @@ -10040,12 +7218,10 @@ func (c *ManagedFoldersInsertCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.managedFolders.insert" call. -// Exactly one of *ManagedFolder or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *ManagedFolder.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ManagedFolder.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ManagedFoldersInsertCall) Do(opts ...googleapi.CallOption) (*ManagedFolder, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10076,38 +7252,7 @@ func (c *ManagedFoldersInsertCall) Do(opts ...googleapi.CallOption) (*ManagedFol return nil, err } return ret, nil - // { - // "description": "Creates a new managed folder.", - // "httpMethod": "POST", - // "id": "storage.managedFolders.insert", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders", - // "request": { - // "$ref": "ManagedFolder" - // }, - // "response": { - // "$ref": "ManagedFolder" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.managedFolders.list": +} type ManagedFoldersListCall struct { s *Service @@ -10127,56 +7272,51 @@ func (r *ManagedFoldersService) List(bucket string) *ManagedFoldersListCall { return c } -// PageSize sets the optional parameter "pageSize": Maximum number of -// items to return in a single page of responses. +// PageSize sets the optional parameter "pageSize": Maximum number of items to +// return in a single page of responses. func (c *ManagedFoldersListCall) PageSize(pageSize int64) *ManagedFoldersListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *ManagedFoldersListCall) PageToken(pageToken string) *ManagedFoldersListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// Prefix sets the optional parameter "prefix": The managed folder -// name/path prefix to filter the output list of results. +// Prefix sets the optional parameter "prefix": The managed folder name/path +// prefix to filter the output list of results. func (c *ManagedFoldersListCall) Prefix(prefix string) *ManagedFoldersListCall { c.urlParams_.Set("prefix", prefix) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersListCall) Fields(s ...googleapi.Field) *ManagedFoldersListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ManagedFoldersListCall) IfNoneMatch(entityTag string) *ManagedFoldersListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersListCall) Context(ctx context.Context) *ManagedFoldersListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10185,12 +7325,7 @@ func (c *ManagedFoldersListCall) Header() http.Header { } func (c *ManagedFoldersListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10211,12 +7346,10 @@ func (c *ManagedFoldersListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.managedFolders.list" call. -// Exactly one of *ManagedFolders or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *ManagedFolders.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ManagedFolders.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ManagedFoldersListCall) Do(opts ...googleapi.CallOption) (*ManagedFolders, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10247,51 +7380,6 @@ func (c *ManagedFoldersListCall) Do(opts ...googleapi.CallOption) (*ManagedFolde return nil, err } return ret, nil - // { - // "description": "Lists managed folders in the given bucket.", - // "httpMethod": "GET", - // "id": "storage.managedFolders.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "pageSize": { - // "description": "Maximum number of items to return in a single page of responses.", - // "format": "int32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // }, - // "prefix": { - // "description": "The managed folder name/path prefix to filter the output list of results.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders", - // "response": { - // "$ref": "ManagedFolders" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - } // Pages invokes f for each page of results. @@ -10299,7 +7387,7 @@ func (c *ManagedFoldersListCall) Do(opts ...googleapi.CallOption) (*ManagedFolde // The provided context supersedes any context provided to the Context method. func (c *ManagedFoldersListCall) Pages(ctx context.Context, f func(*ManagedFolders) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -10315,8 +7403,6 @@ func (c *ManagedFoldersListCall) Pages(ctx context.Context, f func(*ManagedFolde } } -// method id "storage.managedFolders.setIamPolicy": - type ManagedFoldersSetIamPolicyCall struct { s *Service bucket string @@ -10339,31 +7425,29 @@ func (r *ManagedFoldersService) SetIamPolicy(bucket string, managedFolder string return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ManagedFoldersSetIamPolicyCall) UserProject(userProject string) *ManagedFoldersSetIamPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersSetIamPolicyCall) Fields(s ...googleapi.Field) *ManagedFoldersSetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersSetIamPolicyCall) Context(ctx context.Context) *ManagedFoldersSetIamPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersSetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10372,18 +7456,12 @@ func (c *ManagedFoldersSetIamPolicyCall) Header() http.Header { } func (c *ManagedFoldersSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.policy) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/managedFolders/{managedFolder}/iam") @@ -10401,12 +7479,10 @@ func (c *ManagedFoldersSetIamPolicyCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.managedFolders.setIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ManagedFoldersSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10437,49 +7513,7 @@ func (c *ManagedFoldersSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Poli return nil, err } return ret, nil - // { - // "description": "Updates an IAM policy for the specified managed folder.", - // "httpMethod": "PUT", - // "id": "storage.managedFolders.setIamPolicy", - // "parameterOrder": [ - // "bucket", - // "managedFolder" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "managedFolder": { - // "description": "The managed folder name/path.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders/{managedFolder}/iam", - // "request": { - // "$ref": "Policy" - // }, - // "response": { - // "$ref": "Policy" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.managedFolders.testIamPermissions": +} type ManagedFoldersTestIamPermissionsCall struct { s *Service @@ -10491,8 +7525,8 @@ type ManagedFoldersTestIamPermissionsCall struct { header_ http.Header } -// TestIamPermissions: Tests a set of permissions on the given managed -// folder to see which, if any, are held by the caller. +// TestIamPermissions: Tests a set of permissions on the given managed folder +// to see which, if any, are held by the caller. // // - bucket: Name of the bucket containing the managed folder. // - managedFolder: The managed folder name/path. @@ -10505,41 +7539,37 @@ func (r *ManagedFoldersService) TestIamPermissions(bucket string, managedFolder return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ManagedFoldersTestIamPermissionsCall) UserProject(userProject string) *ManagedFoldersTestIamPermissionsCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ManagedFoldersTestIamPermissionsCall) Fields(s ...googleapi.Field) *ManagedFoldersTestIamPermissionsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ManagedFoldersTestIamPermissionsCall) IfNoneMatch(entityTag string) *ManagedFoldersTestIamPermissionsCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ManagedFoldersTestIamPermissionsCall) Context(ctx context.Context) *ManagedFoldersTestIamPermissionsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ManagedFoldersTestIamPermissionsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10548,12 +7578,7 @@ func (c *ManagedFoldersTestIamPermissionsCall) Header() http.Header { } func (c *ManagedFoldersTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10575,12 +7600,11 @@ func (c *ManagedFoldersTestIamPermissionsCall) doRequest(alt string) (*http.Resp } // Do executes the "storage.managedFolders.testIamPermissions" call. -// Exactly one of *TestIamPermissionsResponse or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *TestIamPermissionsResponse.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *TestIamPermissionsResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ManagedFoldersTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10611,57 +7635,7 @@ func (c *ManagedFoldersTestIamPermissionsCall) Do(opts ...googleapi.CallOption) return nil, err } return ret, nil - // { - // "description": "Tests a set of permissions on the given managed folder to see which, if any, are held by the caller.", - // "httpMethod": "GET", - // "id": "storage.managedFolders.testIamPermissions", - // "parameterOrder": [ - // "bucket", - // "managedFolder", - // "permissions" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket containing the managed folder.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "managedFolder": { - // "description": "The managed folder name/path.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "permissions": { - // "description": "Permissions to test.", - // "location": "query", - // "repeated": true, - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/managedFolders/{managedFolder}/iam/testPermissions", - // "response": { - // "$ref": "TestIamPermissionsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.notifications.delete": +} type NotificationsDeleteCall struct { s *Service @@ -10683,31 +7657,29 @@ func (r *NotificationsService) Delete(bucket string, notification string) *Notif return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *NotificationsDeleteCall) UserProject(userProject string) *NotificationsDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *NotificationsDeleteCall) Fields(s ...googleapi.Field) *NotificationsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *NotificationsDeleteCall) Context(ctx context.Context) *NotificationsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *NotificationsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10716,12 +7688,7 @@ func (c *NotificationsDeleteCall) Header() http.Header { } func (c *NotificationsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -10751,44 +7718,7 @@ func (c *NotificationsDeleteCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes a notification subscription.", - // "httpMethod": "DELETE", - // "id": "storage.notifications.delete", - // "parameterOrder": [ - // "bucket", - // "notification" - // ], - // "parameters": { - // "bucket": { - // "description": "The parent bucket of the notification.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "notification": { - // "description": "ID of the notification to delete.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/notificationConfigs/{notification}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.notifications.get": +} type NotificationsGetCall struct { s *Service @@ -10811,41 +7741,37 @@ func (r *NotificationsService) Get(bucket string, notification string) *Notifica return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *NotificationsGetCall) UserProject(userProject string) *NotificationsGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *NotificationsGetCall) Fields(s ...googleapi.Field) *NotificationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *NotificationsGetCall) IfNoneMatch(entityTag string) *NotificationsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *NotificationsGetCall) Context(ctx context.Context) *NotificationsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *NotificationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -10854,12 +7780,7 @@ func (c *NotificationsGetCall) Header() http.Header { } func (c *NotificationsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -10881,12 +7802,10 @@ func (c *NotificationsGetCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.notifications.get" call. -// Exactly one of *Notification or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Notification.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Notification.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *NotificationsGetCall) Do(opts ...googleapi.CallOption) (*Notification, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -10917,49 +7836,7 @@ func (c *NotificationsGetCall) Do(opts ...googleapi.CallOption) (*Notification, return nil, err } return ret, nil - // { - // "description": "View a notification configuration.", - // "httpMethod": "GET", - // "id": "storage.notifications.get", - // "parameterOrder": [ - // "bucket", - // "notification" - // ], - // "parameters": { - // "bucket": { - // "description": "The parent bucket of the notification.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "notification": { - // "description": "Notification ID", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/notificationConfigs/{notification}", - // "response": { - // "$ref": "Notification" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.notifications.insert": +} type NotificationsInsertCall struct { s *Service @@ -10980,31 +7857,29 @@ func (r *NotificationsService) Insert(bucket string, notification *Notification) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *NotificationsInsertCall) UserProject(userProject string) *NotificationsInsertCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *NotificationsInsertCall) Fields(s ...googleapi.Field) *NotificationsInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *NotificationsInsertCall) Context(ctx context.Context) *NotificationsInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *NotificationsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11013,18 +7888,12 @@ func (c *NotificationsInsertCall) Header() http.Header { } func (c *NotificationsInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.notification) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/notificationConfigs") @@ -11041,12 +7910,10 @@ func (c *NotificationsInsertCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.notifications.insert" call. -// Exactly one of *Notification or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Notification.ServerResponse.Header or (if a response was returned at -// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified -// to check whether the returned error was because -// http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Notification.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *NotificationsInsertCall) Do(opts ...googleapi.CallOption) (*Notification, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11077,43 +7944,7 @@ func (c *NotificationsInsertCall) Do(opts ...googleapi.CallOption) (*Notificatio return nil, err } return ret, nil - // { - // "description": "Creates a notification subscription for a given bucket.", - // "httpMethod": "POST", - // "id": "storage.notifications.insert", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "The parent bucket of the notification.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/notificationConfigs", - // "request": { - // "$ref": "Notification" - // }, - // "response": { - // "$ref": "Notification" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.notifications.list": +} type NotificationsListCall struct { s *Service @@ -11124,8 +7955,7 @@ type NotificationsListCall struct { header_ http.Header } -// List: Retrieves a list of notification subscriptions for a given -// bucket. +// List: Retrieves a list of notification subscriptions for a given bucket. // // - bucket: Name of a Google Cloud Storage bucket. func (r *NotificationsService) List(bucket string) *NotificationsListCall { @@ -11134,41 +7964,37 @@ func (r *NotificationsService) List(bucket string) *NotificationsListCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *NotificationsListCall) UserProject(userProject string) *NotificationsListCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *NotificationsListCall) Fields(s ...googleapi.Field) *NotificationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *NotificationsListCall) IfNoneMatch(entityTag string) *NotificationsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *NotificationsListCall) Context(ctx context.Context) *NotificationsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *NotificationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11177,12 +8003,7 @@ func (c *NotificationsListCall) Header() http.Header { } func (c *NotificationsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -11203,12 +8024,10 @@ func (c *NotificationsListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.notifications.list" call. -// Exactly one of *Notifications or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Notifications.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Notifications.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *NotificationsListCall) Do(opts ...googleapi.CallOption) (*Notifications, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11239,42 +8058,7 @@ func (c *NotificationsListCall) Do(opts ...googleapi.CallOption) (*Notifications return nil, err } return ret, nil - // { - // "description": "Retrieves a list of notification subscriptions for a given bucket.", - // "httpMethod": "GET", - // "id": "storage.notifications.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a Google Cloud Storage bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/notificationConfigs", - // "response": { - // "$ref": "Notifications" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objectAccessControls.delete": +} type ObjectAccessControlsDeleteCall struct { s *Service @@ -11286,15 +8070,15 @@ type ObjectAccessControlsDeleteCall struct { header_ http.Header } -// Delete: Permanently deletes the ACL entry for the specified entity on -// the specified object. +// Delete: Permanently deletes the ACL entry for the specified entity on the +// specified object. // // - bucket: Name of a bucket. // - entity: The entity holding the permission. Can be user-userId, // user-emailAddress, group-groupId, group-emailAddress, allUsers, or // allAuthenticatedUsers. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectAccessControlsService) Delete(bucket string, object string, entity string) *ObjectAccessControlsDeleteCall { c := &ObjectAccessControlsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -11304,39 +8088,37 @@ func (r *ObjectAccessControlsService) Delete(bucket string, object string, entit return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectAccessControlsDeleteCall) Generation(generation int64) *ObjectAccessControlsDeleteCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectAccessControlsDeleteCall) UserProject(userProject string) *ObjectAccessControlsDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectAccessControlsDeleteCall) Fields(s ...googleapi.Field) *ObjectAccessControlsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectAccessControlsDeleteCall) Context(ctx context.Context) *ObjectAccessControlsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectAccessControlsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11345,12 +8127,7 @@ func (c *ObjectAccessControlsDeleteCall) Header() http.Header { } func (c *ObjectAccessControlsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -11381,56 +8158,7 @@ func (c *ObjectAccessControlsDeleteCall) Do(opts ...googleapi.CallOption) error return gensupport.WrapError(err) } return nil - // { - // "description": "Permanently deletes the ACL entry for the specified entity on the specified object.", - // "httpMethod": "DELETE", - // "id": "storage.objectAccessControls.delete", - // "parameterOrder": [ - // "bucket", - // "object", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/acl/{entity}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objectAccessControls.get": +} type ObjectAccessControlsGetCall struct { s *Service @@ -11443,15 +8171,14 @@ type ObjectAccessControlsGetCall struct { header_ http.Header } -// Get: Returns the ACL entry for the specified entity on the specified -// object. +// Get: Returns the ACL entry for the specified entity on the specified object. // // - bucket: Name of a bucket. // - entity: The entity holding the permission. Can be user-userId, // user-emailAddress, group-groupId, group-emailAddress, allUsers, or // allAuthenticatedUsers. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectAccessControlsService) Get(bucket string, object string, entity string) *ObjectAccessControlsGetCall { c := &ObjectAccessControlsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -11461,49 +8188,45 @@ func (r *ObjectAccessControlsService) Get(bucket string, object string, entity s return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectAccessControlsGetCall) Generation(generation int64) *ObjectAccessControlsGetCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectAccessControlsGetCall) UserProject(userProject string) *ObjectAccessControlsGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectAccessControlsGetCall) Fields(s ...googleapi.Field) *ObjectAccessControlsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ObjectAccessControlsGetCall) IfNoneMatch(entityTag string) *ObjectAccessControlsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectAccessControlsGetCall) Context(ctx context.Context) *ObjectAccessControlsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectAccessControlsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11512,12 +8235,7 @@ func (c *ObjectAccessControlsGetCall) Header() http.Header { } func (c *ObjectAccessControlsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -11540,12 +8258,11 @@ func (c *ObjectAccessControlsGetCall) doRequest(alt string) (*http.Response, err } // Do executes the "storage.objectAccessControls.get" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ObjectAccessControlsGetCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11576,59 +8293,7 @@ func (c *ObjectAccessControlsGetCall) Do(opts ...googleapi.CallOption) (*ObjectA return nil, err } return ret, nil - // { - // "description": "Returns the ACL entry for the specified entity on the specified object.", - // "httpMethod": "GET", - // "id": "storage.objectAccessControls.get", - // "parameterOrder": [ - // "bucket", - // "object", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/acl/{entity}", - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objectAccessControls.insert": +} type ObjectAccessControlsInsertCall struct { s *Service @@ -11643,8 +8308,8 @@ type ObjectAccessControlsInsertCall struct { // Insert: Creates a new ACL entry on the specified object. // // - bucket: Name of a bucket. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectAccessControlsService) Insert(bucket string, object string, objectaccesscontrol *ObjectAccessControl) *ObjectAccessControlsInsertCall { c := &ObjectAccessControlsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -11654,39 +8319,37 @@ func (r *ObjectAccessControlsService) Insert(bucket string, object string, objec return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectAccessControlsInsertCall) Generation(generation int64) *ObjectAccessControlsInsertCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectAccessControlsInsertCall) UserProject(userProject string) *ObjectAccessControlsInsertCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectAccessControlsInsertCall) Fields(s ...googleapi.Field) *ObjectAccessControlsInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectAccessControlsInsertCall) Context(ctx context.Context) *ObjectAccessControlsInsertCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectAccessControlsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11695,18 +8358,12 @@ func (c *ObjectAccessControlsInsertCall) Header() http.Header { } func (c *ObjectAccessControlsInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.objectaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/{object}/acl") @@ -11724,12 +8381,11 @@ func (c *ObjectAccessControlsInsertCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.objectAccessControls.insert" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ObjectAccessControlsInsertCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11760,55 +8416,7 @@ func (c *ObjectAccessControlsInsertCall) Do(opts ...googleapi.CallOption) (*Obje return nil, err } return ret, nil - // { - // "description": "Creates a new ACL entry on the specified object.", - // "httpMethod": "POST", - // "id": "storage.objectAccessControls.insert", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/acl", - // "request": { - // "$ref": "ObjectAccessControl" - // }, - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objectAccessControls.list": +} type ObjectAccessControlsListCall struct { s *Service @@ -11823,8 +8431,8 @@ type ObjectAccessControlsListCall struct { // List: Retrieves ACL entries on the specified object. // // - bucket: Name of a bucket. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectAccessControlsService) List(bucket string, object string) *ObjectAccessControlsListCall { c := &ObjectAccessControlsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -11833,49 +8441,45 @@ func (r *ObjectAccessControlsService) List(bucket string, object string) *Object return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectAccessControlsListCall) Generation(generation int64) *ObjectAccessControlsListCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectAccessControlsListCall) UserProject(userProject string) *ObjectAccessControlsListCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectAccessControlsListCall) Fields(s ...googleapi.Field) *ObjectAccessControlsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ObjectAccessControlsListCall) IfNoneMatch(entityTag string) *ObjectAccessControlsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectAccessControlsListCall) Context(ctx context.Context) *ObjectAccessControlsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectAccessControlsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -11884,12 +8488,7 @@ func (c *ObjectAccessControlsListCall) Header() http.Header { } func (c *ObjectAccessControlsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -11911,12 +8510,11 @@ func (c *ObjectAccessControlsListCall) doRequest(alt string) (*http.Response, er } // Do executes the "storage.objectAccessControls.list" call. -// Exactly one of *ObjectAccessControls or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControls.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControls.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ObjectAccessControlsListCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControls, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -11947,52 +8545,7 @@ func (c *ObjectAccessControlsListCall) Do(opts ...googleapi.CallOption) (*Object return nil, err } return ret, nil - // { - // "description": "Retrieves ACL entries on the specified object.", - // "httpMethod": "GET", - // "id": "storage.objectAccessControls.list", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/acl", - // "response": { - // "$ref": "ObjectAccessControls" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objectAccessControls.patch": +} type ObjectAccessControlsPatchCall struct { s *Service @@ -12011,8 +8564,8 @@ type ObjectAccessControlsPatchCall struct { // - entity: The entity holding the permission. Can be user-userId, // user-emailAddress, group-groupId, group-emailAddress, allUsers, or // allAuthenticatedUsers. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectAccessControlsService) Patch(bucket string, object string, entity string, objectaccesscontrol *ObjectAccessControl) *ObjectAccessControlsPatchCall { c := &ObjectAccessControlsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -12023,39 +8576,37 @@ func (r *ObjectAccessControlsService) Patch(bucket string, object string, entity return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectAccessControlsPatchCall) Generation(generation int64) *ObjectAccessControlsPatchCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectAccessControlsPatchCall) UserProject(userProject string) *ObjectAccessControlsPatchCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectAccessControlsPatchCall) Fields(s ...googleapi.Field) *ObjectAccessControlsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectAccessControlsPatchCall) Context(ctx context.Context) *ObjectAccessControlsPatchCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectAccessControlsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12064,18 +8615,12 @@ func (c *ObjectAccessControlsPatchCall) Header() http.Header { } func (c *ObjectAccessControlsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.objectaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/{object}/acl/{entity}") @@ -12094,12 +8639,11 @@ func (c *ObjectAccessControlsPatchCall) doRequest(alt string) (*http.Response, e } // Do executes the "storage.objectAccessControls.patch" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ObjectAccessControlsPatchCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12130,62 +8674,7 @@ func (c *ObjectAccessControlsPatchCall) Do(opts ...googleapi.CallOption) (*Objec return nil, err } return ret, nil - // { - // "description": "Patches an ACL entry on the specified object.", - // "httpMethod": "PATCH", - // "id": "storage.objectAccessControls.patch", - // "parameterOrder": [ - // "bucket", - // "object", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/acl/{entity}", - // "request": { - // "$ref": "ObjectAccessControl" - // }, - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objectAccessControls.update": +} type ObjectAccessControlsUpdateCall struct { s *Service @@ -12204,8 +8693,8 @@ type ObjectAccessControlsUpdateCall struct { // - entity: The entity holding the permission. Can be user-userId, // user-emailAddress, group-groupId, group-emailAddress, allUsers, or // allAuthenticatedUsers. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectAccessControlsService) Update(bucket string, object string, entity string, objectaccesscontrol *ObjectAccessControl) *ObjectAccessControlsUpdateCall { c := &ObjectAccessControlsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -12216,39 +8705,37 @@ func (r *ObjectAccessControlsService) Update(bucket string, object string, entit return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectAccessControlsUpdateCall) Generation(generation int64) *ObjectAccessControlsUpdateCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectAccessControlsUpdateCall) UserProject(userProject string) *ObjectAccessControlsUpdateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectAccessControlsUpdateCall) Fields(s ...googleapi.Field) *ObjectAccessControlsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectAccessControlsUpdateCall) Context(ctx context.Context) *ObjectAccessControlsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectAccessControlsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12257,18 +8744,12 @@ func (c *ObjectAccessControlsUpdateCall) Header() http.Header { } func (c *ObjectAccessControlsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.objectaccesscontrol) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/{object}/acl/{entity}") @@ -12287,12 +8768,11 @@ func (c *ObjectAccessControlsUpdateCall) doRequest(alt string) (*http.Response, } // Do executes the "storage.objectAccessControls.update" call. -// Exactly one of *ObjectAccessControl or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ObjectAccessControl.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ObjectAccessControl.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ObjectAccessControlsUpdateCall) Do(opts ...googleapi.CallOption) (*ObjectAccessControl, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12323,62 +8803,7 @@ func (c *ObjectAccessControlsUpdateCall) Do(opts ...googleapi.CallOption) (*Obje return nil, err } return ret, nil - // { - // "description": "Updates an ACL entry on the specified object.", - // "httpMethod": "PUT", - // "id": "storage.objectAccessControls.update", - // "parameterOrder": [ - // "bucket", - // "object", - // "entity" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of a bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "entity": { - // "description": "The entity holding the permission. Can be user-userId, user-emailAddress, group-groupId, group-emailAddress, allUsers, or allAuthenticatedUsers.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/acl/{entity}", - // "request": { - // "$ref": "ObjectAccessControl" - // }, - // "response": { - // "$ref": "ObjectAccessControl" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objects.bulkRestore": +} type ObjectsBulkRestoreCall struct { s *Service @@ -12401,23 +8826,21 @@ func (r *ObjectsService) BulkRestore(bucket string, bulkrestoreobjectsrequest *B } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsBulkRestoreCall) Fields(s ...googleapi.Field) *ObjectsBulkRestoreCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsBulkRestoreCall) Context(ctx context.Context) *ObjectsBulkRestoreCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsBulkRestoreCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12426,18 +8849,12 @@ func (c *ObjectsBulkRestoreCall) Header() http.Header { } func (c *ObjectsBulkRestoreCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.bulkrestoreobjectsrequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/bulkRestore") @@ -12454,12 +8871,11 @@ func (c *ObjectsBulkRestoreCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.bulkRestore" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ObjectsBulkRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12490,38 +8906,7 @@ func (c *ObjectsBulkRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongru return nil, err } return ret, nil - // { - // "description": "Initiates a long-running bulk restore operation on the specified bucket.", - // "httpMethod": "POST", - // "id": "storage.objects.bulkRestore", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/bulkRestore", - // "request": { - // "$ref": "BulkRestoreObjectsRequest" - // }, - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.compose": +} type ObjectsComposeCall struct { s *Service @@ -12533,14 +8918,13 @@ type ObjectsComposeCall struct { header_ http.Header } -// Compose: Concatenates a list of existing objects into a new object in -// the same bucket. +// Compose: Concatenates a list of existing objects into a new object in the +// same bucket. // -// - destinationBucket: Name of the bucket containing the source -// objects. The destination object is stored in this bucket. -// - destinationObject: Name of the new object. For information about -// how to URL encode object names to be path safe, see Encoding URI -// Path Parts +// - destinationBucket: Name of the bucket containing the source objects. The +// destination object is stored in this bucket. +// - destinationObject: Name of the new object. For information about how to +// URL encode object names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Compose(destinationBucket string, destinationObject string, composerequest *ComposeRequest) *ObjectsComposeCall { c := &ObjectsComposeCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -12551,8 +8935,8 @@ func (r *ObjectsService) Compose(destinationBucket string, destinationObject str } // DestinationPredefinedAcl sets the optional parameter -// "destinationPredefinedAcl": Apply a predefined set of access controls -// to the destination object. +// "destinationPredefinedAcl": Apply a predefined set of access controls to the +// destination object. // // Possible values: // @@ -12560,81 +8944,77 @@ func (r *ObjectsService) Compose(destinationBucket string, destinationObject str // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *ObjectsComposeCall) DestinationPredefinedAcl(destinationPredefinedAcl string) *ObjectsComposeCall { c.urlParams_.Set("destinationPredefinedAcl", destinationPredefinedAcl) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsComposeCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsComposeCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's current metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's current +// metageneration matches the given value. func (c *ObjectsComposeCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsComposeCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } -// KmsKeyName sets the optional parameter "kmsKeyName": Resource name of -// the Cloud KMS key, of the form -// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, -// -// that will be used to encrypt the object. Overrides the object -// -// metadata's kms_key_name value, if any. +// KmsKeyName sets the optional parameter "kmsKeyName": Resource name of the +// Cloud KMS key, of the form +// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that +// will be used to encrypt the object. Overrides the object metadata's +// kms_key_name value, if any. func (c *ObjectsComposeCall) KmsKeyName(kmsKeyName string) *ObjectsComposeCall { c.urlParams_.Set("kmsKeyName", kmsKeyName) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsComposeCall) UserProject(userProject string) *ObjectsComposeCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsComposeCall) Fields(s ...googleapi.Field) *ObjectsComposeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsComposeCall) Context(ctx context.Context) *ObjectsComposeCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsComposeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -12643,18 +9023,12 @@ func (c *ObjectsComposeCall) Header() http.Header { } func (c *ObjectsComposeCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.composerequest) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{destinationBucket}/o/{destinationObject}/compose") @@ -12672,12 +9046,10 @@ func (c *ObjectsComposeCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.compose" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsComposeCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -12708,88 +9080,7 @@ func (c *ObjectsComposeCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Concatenates a list of existing objects into a new object in the same bucket.", - // "httpMethod": "POST", - // "id": "storage.objects.compose", - // "parameterOrder": [ - // "destinationBucket", - // "destinationObject" - // ], - // "parameters": { - // "destinationBucket": { - // "description": "Name of the bucket containing the source objects. The destination object is stored in this bucket.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationObject": { - // "description": "Name of the new object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationPredefinedAcl": { - // "description": "Apply a predefined set of access controls to the destination object.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "kmsKeyName": { - // "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{destinationBucket}/o/{destinationObject}/compose", - // "request": { - // "$ref": "ComposeRequest" - // }, - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.copy": +} type ObjectsCopyCall struct { s *Service @@ -12803,22 +9094,20 @@ type ObjectsCopyCall struct { header_ http.Header } -// Copy: Copies a source object to a destination object. Optionally -// overrides metadata. +// Copy: Copies a source object to a destination object. Optionally overrides +// metadata. // -// - destinationBucket: Name of the bucket in which to store the new -// object. Overrides the provided object metadata's bucket value, if -// any.For information about how to URL encode object names to be path -// safe, see Encoding URI Path Parts +// - destinationBucket: Name of the bucket in which to store the new object. +// Overrides the provided object metadata's bucket value, if any.For +// information about how to URL encode object names to be path safe, see +// Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). // - destinationObject: Name of the new object. Required when the object -// metadata is not otherwise provided. Overrides the object metadata's -// name value, if any. -// - sourceBucket: Name of the bucket in which to find the source -// object. -// - sourceObject: Name of the source object. For information about how -// to URL encode object names to be path safe, see Encoding URI Path -// Parts +// metadata is not otherwise provided. Overrides the object metadata's name +// value, if any. +// - sourceBucket: Name of the bucket in which to find the source object. +// - sourceObject: Name of the source object. For information about how to URL +// encode object names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Copy(sourceBucket string, sourceObject string, destinationBucket string, destinationObject string, object *Object) *ObjectsCopyCall { c := &ObjectsCopyCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -12830,22 +9119,19 @@ func (r *ObjectsService) Copy(sourceBucket string, sourceObject string, destinat return c } -// DestinationKmsKeyName sets the optional parameter -// "destinationKmsKeyName": Resource name of the Cloud KMS key, of the -// form -// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, -// -// that will be used to encrypt the object. Overrides the object -// -// metadata's kms_key_name value, if any. +// DestinationKmsKeyName sets the optional parameter "destinationKmsKeyName": +// Resource name of the Cloud KMS key, of the form +// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that +// will be used to encrypt the object. Overrides the object metadata's +// kms_key_name value, if any. func (c *ObjectsCopyCall) DestinationKmsKeyName(destinationKmsKeyName string) *ObjectsCopyCall { c.urlParams_.Set("destinationKmsKeyName", destinationKmsKeyName) return c } // DestinationPredefinedAcl sets the optional parameter -// "destinationPredefinedAcl": Apply a predefined set of access controls -// to the destination object. +// "destinationPredefinedAcl": Apply a predefined set of access controls to the +// destination object. // // Possible values: // @@ -12853,103 +9139,97 @@ func (c *ObjectsCopyCall) DestinationKmsKeyName(destinationKmsKeyName string) *O // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *ObjectsCopyCall) DestinationPredefinedAcl(destinationPredefinedAcl string) *ObjectsCopyCall { c.urlParams_.Set("destinationPredefinedAcl", destinationPredefinedAcl) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the destination object's -// current generation matches the given value. Setting to 0 makes the -// operation succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the destination object's current generation +// matches the given value. Setting to 0 makes the operation succeed only if +// there are no live versions of the object. func (c *ObjectsCopyCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the destination object's current generation does not match the given -// value. If no live object exists, the precondition fails. Setting to 0 -// makes the operation succeed only if there is a live version of the -// object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the destination object's current +// generation does not match the given value. If no live object exists, the +// precondition fails. Setting to 0 makes the operation succeed only if there +// is a live version of the object. func (c *ObjectsCopyCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the destination object's current metageneration matches the given -// value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the destination object's current +// metageneration matches the given value. func (c *ObjectsCopyCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the destination object's current metageneration does not -// match the given value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// destination object's current metageneration does not match the given value. func (c *ObjectsCopyCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } // IfSourceGenerationMatch sets the optional parameter -// "ifSourceGenerationMatch": Makes the operation conditional on whether -// the source object's current generation matches the given value. +// "ifSourceGenerationMatch": Makes the operation conditional on whether the +// source object's current generation matches the given value. func (c *ObjectsCopyCall) IfSourceGenerationMatch(ifSourceGenerationMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifSourceGenerationMatch", fmt.Sprint(ifSourceGenerationMatch)) return c } // IfSourceGenerationNotMatch sets the optional parameter -// "ifSourceGenerationNotMatch": Makes the operation conditional on -// whether the source object's current generation does not match the -// given value. +// "ifSourceGenerationNotMatch": Makes the operation conditional on whether the +// source object's current generation does not match the given value. func (c *ObjectsCopyCall) IfSourceGenerationNotMatch(ifSourceGenerationNotMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifSourceGenerationNotMatch", fmt.Sprint(ifSourceGenerationNotMatch)) return c } // IfSourceMetagenerationMatch sets the optional parameter -// "ifSourceMetagenerationMatch": Makes the operation conditional on -// whether the source object's current metageneration matches the given -// value. +// "ifSourceMetagenerationMatch": Makes the operation conditional on whether +// the source object's current metageneration matches the given value. func (c *ObjectsCopyCall) IfSourceMetagenerationMatch(ifSourceMetagenerationMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifSourceMetagenerationMatch", fmt.Sprint(ifSourceMetagenerationMatch)) return c } // IfSourceMetagenerationNotMatch sets the optional parameter -// "ifSourceMetagenerationNotMatch": Makes the operation conditional on -// whether the source object's current metageneration does not match the -// given value. +// "ifSourceMetagenerationNotMatch": Makes the operation conditional on whether +// the source object's current metageneration does not match the given value. func (c *ObjectsCopyCall) IfSourceMetagenerationNotMatch(ifSourceMetagenerationNotMatch int64) *ObjectsCopyCall { c.urlParams_.Set("ifSourceMetagenerationNotMatch", fmt.Sprint(ifSourceMetagenerationNotMatch)) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl, unless the object resource -// specifies the acl property, when it defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl, unless the object resource specifies the acl +// property, when it defaults to full. // // Possible values: // @@ -12960,39 +9240,37 @@ func (c *ObjectsCopyCall) Projection(projection string) *ObjectsCopyCall { return c } -// SourceGeneration sets the optional parameter "sourceGeneration": If -// present, selects a specific revision of the source object (as opposed -// to the latest version, the default). +// SourceGeneration sets the optional parameter "sourceGeneration": If present, +// selects a specific revision of the source object (as opposed to the latest +// version, the default). func (c *ObjectsCopyCall) SourceGeneration(sourceGeneration int64) *ObjectsCopyCall { c.urlParams_.Set("sourceGeneration", fmt.Sprint(sourceGeneration)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsCopyCall) UserProject(userProject string) *ObjectsCopyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsCopyCall) Fields(s ...googleapi.Field) *ObjectsCopyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsCopyCall) Context(ctx context.Context) *ObjectsCopyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsCopyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13001,18 +9279,12 @@ func (c *ObjectsCopyCall) Header() http.Header { } func (c *ObjectsCopyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.object) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{sourceBucket}/o/{sourceObject}/copyTo/b/{destinationBucket}/o/{destinationObject}") @@ -13032,12 +9304,10 @@ func (c *ObjectsCopyCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.copy" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsCopyCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13068,157 +9338,7 @@ func (c *ObjectsCopyCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Copies a source object to a destination object. Optionally overrides metadata.", - // "httpMethod": "POST", - // "id": "storage.objects.copy", - // "parameterOrder": [ - // "sourceBucket", - // "sourceObject", - // "destinationBucket", - // "destinationObject" - // ], - // "parameters": { - // "destinationBucket": { - // "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationKmsKeyName": { - // "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", - // "location": "query", - // "type": "string" - // }, - // "destinationObject": { - // "description": "Name of the new object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationPredefinedAcl": { - // "description": "Apply a predefined set of access controls to the destination object.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the destination object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the destination object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the destination object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the destination object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceGenerationMatch": { - // "description": "Makes the operation conditional on whether the source object's current generation matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the source object's current generation does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "sourceBucket": { - // "description": "Name of the bucket in which to find the source object.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "sourceGeneration": { - // "description": "If present, selects a specific revision of the source object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "sourceObject": { - // "description": "Name of the source object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{sourceBucket}/o/{sourceObject}/copyTo/b/{destinationBucket}/o/{destinationObject}", - // "request": { - // "$ref": "Object" - // }, - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.delete": +} type ObjectsDeleteCall struct { s *Service @@ -13229,13 +9349,13 @@ type ObjectsDeleteCall struct { header_ http.Header } -// Delete: Deletes an object and its metadata. Deletions are permanent -// if versioning is not enabled for the bucket, or if the generation -// parameter is used. +// Delete: Deletes an object and its metadata. Deletions are permanent if +// versioning is not enabled for the bucket, or if the generation parameter is +// used. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Delete(bucket string, object string) *ObjectsDeleteCall { c := &ObjectsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13244,75 +9364,72 @@ func (r *ObjectsService) Delete(bucket string, object string) *ObjectsDeleteCall return c } -// Generation sets the optional parameter "generation": If present, -// permanently deletes a specific revision of this object (as opposed to -// the latest version, the default). +// Generation sets the optional parameter "generation": If present, permanently +// deletes a specific revision of this object (as opposed to the latest +// version, the default). func (c *ObjectsDeleteCall) Generation(generation int64) *ObjectsDeleteCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsDeleteCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsDeleteCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the object's current generation does not match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the object's current generation +// does not match the given value. If no live object exists, the precondition +// fails. Setting to 0 makes the operation succeed only if there is a live +// version of the object. func (c *ObjectsDeleteCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsDeleteCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's current metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's current +// metageneration matches the given value. func (c *ObjectsDeleteCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsDeleteCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the object's current metageneration does not match the given -// value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// object's current metageneration does not match the given value. func (c *ObjectsDeleteCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsDeleteCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsDeleteCall) UserProject(userProject string) *ObjectsDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsDeleteCall) Fields(s ...googleapi.Field) *ObjectsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsDeleteCall) Context(ctx context.Context) *ObjectsDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13321,12 +9438,7 @@ func (c *ObjectsDeleteCall) Header() http.Header { } func (c *ObjectsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -13356,74 +9468,7 @@ func (c *ObjectsDeleteCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Deletes an object and its metadata. Deletions are permanent if versioning is not enabled for the bucket, or if the generation parameter is used.", - // "httpMethod": "DELETE", - // "id": "storage.objects.delete", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, permanently deletes a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.get": +} type ObjectsGetCall struct { s *Service @@ -13438,8 +9483,8 @@ type ObjectsGetCall struct { // Get: Retrieves an object or its metadata. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Get(bucket string, object string) *ObjectsGetCall { c := &ObjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13448,52 +9493,51 @@ func (r *ObjectsService) Get(bucket string, object string) *ObjectsGetCall { return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectsGetCall) Generation(generation int64) *ObjectsGetCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsGetCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsGetCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the object's current generation does not match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the object's current generation +// does not match the given value. If no live object exists, the precondition +// fails. Setting to 0 makes the operation succeed only if there is a live +// version of the object. func (c *ObjectsGetCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsGetCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's current metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's current +// metageneration matches the given value. func (c *ObjectsGetCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsGetCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the object's current metageneration does not match the given -// value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// object's current metageneration does not match the given value. func (c *ObjectsGetCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsGetCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl. // // Possible values: // @@ -13505,48 +9549,44 @@ func (c *ObjectsGetCall) Projection(projection string) *ObjectsGetCall { } // SoftDeleted sets the optional parameter "softDeleted": If true, only -// soft-deleted object versions will be listed. The default is false. -// For more information, see Soft Delete. +// soft-deleted object versions will be listed. The default is false. For more +// information, see Soft Delete. func (c *ObjectsGetCall) SoftDeleted(softDeleted bool) *ObjectsGetCall { c.urlParams_.Set("softDeleted", fmt.Sprint(softDeleted)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsGetCall) UserProject(userProject string) *ObjectsGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsGetCall) Fields(s ...googleapi.Field) *ObjectsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ObjectsGetCall) IfNoneMatch(entityTag string) *ObjectsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do and Download -// methods. Any pending HTTP request will be aborted if the provided -// context is canceled. +// Context sets the context to be used in this call's Do and Download methods. func (c *ObjectsGetCall) Context(ctx context.Context) *ObjectsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13555,12 +9595,7 @@ func (c *ObjectsGetCall) Header() http.Header { } func (c *ObjectsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -13598,12 +9633,10 @@ func (c *ObjectsGetCall) Download(opts ...googleapi.CallOption) (*http.Response, } // Do executes the "storage.objects.get" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsGetCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13634,99 +9667,7 @@ func (c *ObjectsGetCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Retrieves an object or its metadata.", - // "httpMethod": "GET", - // "id": "storage.objects.get", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "softDeleted": { - // "description": "If true, only soft-deleted object versions will be listed. The default is false. For more information, see Soft Delete.", - // "location": "query", - // "type": "boolean" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}", - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ], - // "supportsMediaDownload": true, - // "useMediaDownloadService": true - // } - -} - -// method id "storage.objects.getIamPolicy": +} type ObjectsGetIamPolicyCall struct { s *Service @@ -13741,8 +9682,8 @@ type ObjectsGetIamPolicyCall struct { // GetIamPolicy: Returns an IAM policy for the specified object. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) GetIamPolicy(bucket string, object string) *ObjectsGetIamPolicyCall { c := &ObjectsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13751,49 +9692,45 @@ func (r *ObjectsService) GetIamPolicy(bucket string, object string) *ObjectsGetI return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectsGetIamPolicyCall) Generation(generation int64) *ObjectsGetIamPolicyCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsGetIamPolicyCall) UserProject(userProject string) *ObjectsGetIamPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsGetIamPolicyCall) Fields(s ...googleapi.Field) *ObjectsGetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ObjectsGetIamPolicyCall) IfNoneMatch(entityTag string) *ObjectsGetIamPolicyCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsGetIamPolicyCall) Context(ctx context.Context) *ObjectsGetIamPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsGetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -13802,12 +9739,7 @@ func (c *ObjectsGetIamPolicyCall) Header() http.Header { } func (c *ObjectsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -13829,12 +9761,10 @@ func (c *ObjectsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.objects.getIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -13865,55 +9795,7 @@ func (c *ObjectsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, err return nil, err } return ret, nil - // { - // "description": "Returns an IAM policy for the specified object.", - // "httpMethod": "GET", - // "id": "storage.objects.getIamPolicy", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/iam", - // "response": { - // "$ref": "Policy" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.insert": +} type ObjectsInsertCall struct { s *Service @@ -13928,8 +9810,8 @@ type ObjectsInsertCall struct { // Insert: Stores a new object and metadata. // -// - bucket: Name of the bucket in which to store the new object. -// Overrides the provided object metadata's bucket value, if any. +// - bucket: Name of the bucket in which to store the new object. Overrides the +// provided object metadata's bucket value, if any. func (r *ObjectsService) Insert(bucket string, object *Object) *ObjectsInsertCall { c := &ObjectsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.bucket = bucket @@ -13937,69 +9819,65 @@ func (r *ObjectsService) Insert(bucket string, object *Object) *ObjectsInsertCal return c } -// ContentEncoding sets the optional parameter "contentEncoding": If -// set, sets the contentEncoding property of the final object to this -// value. Setting this parameter is equivalent to setting the -// contentEncoding metadata property. This can be useful when uploading -// an object with uploadType=media to indicate the encoding of the -// content being uploaded. +// ContentEncoding sets the optional parameter "contentEncoding": If set, sets +// the contentEncoding property of the final object to this value. Setting this +// parameter is equivalent to setting the contentEncoding metadata property. +// This can be useful when uploading an object with uploadType=media to +// indicate the encoding of the content being uploaded. func (c *ObjectsInsertCall) ContentEncoding(contentEncoding string) *ObjectsInsertCall { c.urlParams_.Set("contentEncoding", contentEncoding) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsInsertCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsInsertCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the object's current generation does not match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the object's current generation +// does not match the given value. If no live object exists, the precondition +// fails. Setting to 0 makes the operation succeed only if there is a live +// version of the object. func (c *ObjectsInsertCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsInsertCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's current metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's current +// metageneration matches the given value. func (c *ObjectsInsertCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsInsertCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the object's current metageneration does not match the given -// value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// object's current metageneration does not match the given value. func (c *ObjectsInsertCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsInsertCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } -// KmsKeyName sets the optional parameter "kmsKeyName": Resource name of -// the Cloud KMS key, of the form -// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, -// -// that will be used to encrypt the object. Overrides the object -// -// metadata's kms_key_name value, if any. +// KmsKeyName sets the optional parameter "kmsKeyName": Resource name of the +// Cloud KMS key, of the form +// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that +// will be used to encrypt the object. Overrides the object metadata's +// kms_key_name value, if any. func (c *ObjectsInsertCall) KmsKeyName(kmsKeyName string) *ObjectsInsertCall { c.urlParams_.Set("kmsKeyName", kmsKeyName) return c } -// Name sets the optional parameter "name": Name of the object. Required -// when the object metadata is not otherwise provided. Overrides the -// object metadata's name value, if any. For information about how to -// URL encode object names to be path safe, see Encoding URI Path Parts +// Name sets the optional parameter "name": Name of the object. Required when +// the object metadata is not otherwise provided. Overrides the object +// metadata's name value, if any. For information about how to URL encode +// object names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (c *ObjectsInsertCall) Name(name string) *ObjectsInsertCall { c.urlParams_.Set("name", name) @@ -14015,30 +9893,30 @@ func (c *ObjectsInsertCall) Name(name string) *ObjectsInsertCall { // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *ObjectsInsertCall) PredefinedAcl(predefinedAcl string) *ObjectsInsertCall { c.urlParams_.Set("predefinedAcl", predefinedAcl) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl, unless the object resource -// specifies the acl property, when it defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl, unless the object resource specifies the acl +// property, when it defaults to full. // // Possible values: // @@ -14049,20 +9927,19 @@ func (c *ObjectsInsertCall) Projection(projection string) *ObjectsInsertCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsInsertCall) UserProject(userProject string) *ObjectsInsertCall { c.urlParams_.Set("userProject", userProject) return c } -// Media specifies the media to upload in one or more chunks. The chunk -// size may be controlled by supplying a MediaOption generated by +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by // googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the -// upload request will be determined by sniffing the contents of r, -// unless a MediaOption generated by googleapi.ContentType is -// supplied. +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. // At most one of Media and ResumableMedia may be set. func (c *ObjectsInsertCall) Media(r io.Reader, options ...googleapi.MediaOption) *ObjectsInsertCall { if ct := c.object.ContentType; ct != "" { @@ -14072,46 +9949,45 @@ func (c *ObjectsInsertCall) Media(r io.Reader, options ...googleapi.MediaOption) return c } -// ResumableMedia specifies the media to upload in chunks and can be -// canceled with ctx. +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. // // Deprecated: use Media instead. // -// At most one of Media and ResumableMedia may be set. mediaType -// identifies the MIME media type of the upload, such as "image/png". If -// mediaType is "", it will be auto-detected. The provided ctx will -// supersede any context previously provided to the Context method. +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. func (c *ObjectsInsertCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *ObjectsInsertCall { c.ctx_ = ctx c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) return c } -// ProgressUpdater provides a callback function that will be called -// after every chunk. It should be a low-latency function in order to -// not slow down the upload operation. This should only be called when -// using ResumableMedia (as opposed to Media). +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). func (c *ObjectsInsertCall) ProgressUpdater(pu googleapi.ProgressUpdater) *ObjectsInsertCall { c.mediaInfo_.SetProgressUpdater(pu) return c } -// WithRetry causes the library to retry the initial request of the -// upload(for resumable uploads) or the entire upload (for multipart -// uploads) ifa transient error occurs. This is contingent on ChunkSize -// being > 0 (sothat the input data may be buffered). The backoff -// argument will be used todetermine exponential backoff timing, and the -// errorFunc is used to determinewhich errors are considered retryable. -// By default, exponetial backoff will beapplied using gax defaults, and -// the following errors are retried: +// WithRetry causes the library to retry the initial request of the upload(for +// resumable uploads) or the entire upload (for multipart uploads) ifa +// transient error occurs. This is contingent on ChunkSize being > 0 (sothat +// the input data may be buffered). The backoff argument will be used +// todetermine exponential backoff timing, and the errorFunc is used to +// determinewhich errors are considered retryable. By default, exponetial +// backoff will beapplied using gax defaults, and the following errors are +// retried: // // - HTTP responses with codes 408, 429, 502, 503, and 504. // // - Transient network errors such as connection reset and // io.ErrUnexpectedEOF. // -// - Errors which are considered transient using the Temporary() -// interface. +// - Errors which are considered transient using the Temporary() interface. // // - Wrapped versions of these errors. func (c *ObjectsInsertCall) WithRetry(bo *gax.Backoff, errorFunc func(err error) bool) *ObjectsInsertCall { @@ -14123,16 +9999,14 @@ func (c *ObjectsInsertCall) WithRetry(bo *gax.Backoff, errorFunc func(err error) } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsInsertCall) Fields(s ...googleapi.Field) *ObjectsInsertCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. // This context will supersede any context previously provided to the // ResumableMedia method. func (c *ObjectsInsertCall) Context(ctx context.Context) *ObjectsInsertCall { @@ -14140,8 +10014,8 @@ func (c *ObjectsInsertCall) Context(ctx context.Context) *ObjectsInsertCall { return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14150,18 +10024,12 @@ func (c *ObjectsInsertCall) Header() http.Header { } func (c *ObjectsInsertCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.object) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o") @@ -14192,12 +10060,10 @@ func (c *ObjectsInsertCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.insert" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsInsertCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14246,132 +10112,7 @@ func (c *ObjectsInsertCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Stores a new object and metadata.", - // "httpMethod": "POST", - // "id": "storage.objects.insert", - // "mediaUpload": { - // "accept": [ - // "*/*" - // ], - // "protocols": { - // "resumable": { - // "multipart": true, - // "path": "/resumable/upload/storage/v1/b/{bucket}/o" - // }, - // "simple": { - // "multipart": true, - // "path": "/upload/storage/v1/b/{bucket}/o" - // } - // } - // }, - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "contentEncoding": { - // "description": "If set, sets the contentEncoding property of the final object to this value. Setting this parameter is equivalent to setting the contentEncoding metadata property. This can be useful when uploading an object with uploadType=media to indicate the encoding of the content being uploaded.", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "kmsKeyName": { - // "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "Name of the object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "query", - // "type": "string" - // }, - // "predefinedAcl": { - // "description": "Apply a predefined set of access controls to this object.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o", - // "request": { - // "$ref": "Object" - // }, - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ], - // "supportsMediaUpload": true - // } - -} - -// method id "storage.objects.list": +} type ObjectsListCall struct { s *Service @@ -14391,30 +10132,29 @@ func (r *ObjectsService) List(bucket string) *ObjectsListCall { return c } -// Delimiter sets the optional parameter "delimiter": Returns results in -// a directory-like mode. items will contain only objects whose names, -// aside from the prefix, do not contain delimiter. Objects whose names, -// aside from the prefix, contain delimiter will have their name, -// truncated after the delimiter, returned in prefixes. Duplicate -// prefixes are omitted. +// Delimiter sets the optional parameter "delimiter": Returns results in a +// directory-like mode. items will contain only objects whose names, aside from +// the prefix, do not contain delimiter. Objects whose names, aside from the +// prefix, contain delimiter will have their name, truncated after the +// delimiter, returned in prefixes. Duplicate prefixes are omitted. func (c *ObjectsListCall) Delimiter(delimiter string) *ObjectsListCall { c.urlParams_.Set("delimiter", delimiter) return c } -// EndOffset sets the optional parameter "endOffset": Filter results to -// objects whose names are lexicographically before endOffset. If -// startOffset is also set, the objects listed will have names between -// startOffset (inclusive) and endOffset (exclusive). +// EndOffset sets the optional parameter "endOffset": Filter results to objects +// whose names are lexicographically before endOffset. If startOffset is also +// set, the objects listed will have names between startOffset (inclusive) and +// endOffset (exclusive). func (c *ObjectsListCall) EndOffset(endOffset string) *ObjectsListCall { c.urlParams_.Set("endOffset", endOffset) return c } // IncludeFoldersAsPrefixes sets the optional parameter -// "includeFoldersAsPrefixes": Only applicable if delimiter is set to -// '/'. If true, will also include folders and managed folders (besides -// objects) in the returned prefixes. +// "includeFoldersAsPrefixes": Only applicable if delimiter is set to '/'. If +// true, will also include folders and managed folders (besides objects) in the +// returned prefixes. func (c *ObjectsListCall) IncludeFoldersAsPrefixes(includeFoldersAsPrefixes bool) *ObjectsListCall { c.urlParams_.Set("includeFoldersAsPrefixes", fmt.Sprint(includeFoldersAsPrefixes)) return c @@ -14422,47 +10162,45 @@ func (c *ObjectsListCall) IncludeFoldersAsPrefixes(includeFoldersAsPrefixes bool // IncludeTrailingDelimiter sets the optional parameter // "includeTrailingDelimiter": If true, objects that end in exactly one -// instance of delimiter will have their metadata included in items in -// addition to prefixes. +// instance of delimiter will have their metadata included in items in addition +// to prefixes. func (c *ObjectsListCall) IncludeTrailingDelimiter(includeTrailingDelimiter bool) *ObjectsListCall { c.urlParams_.Set("includeTrailingDelimiter", fmt.Sprint(includeTrailingDelimiter)) return c } -// MatchGlob sets the optional parameter "matchGlob": Filter results to -// objects and prefixes that match this glob pattern. +// MatchGlob sets the optional parameter "matchGlob": Filter results to objects +// and prefixes that match this glob pattern. func (c *ObjectsListCall) MatchGlob(matchGlob string) *ObjectsListCall { c.urlParams_.Set("matchGlob", matchGlob) return c } -// MaxResults sets the optional parameter "maxResults": Maximum number -// of items plus prefixes to return in a single page of responses. As -// duplicate prefixes are omitted, fewer total results may be returned -// than requested. The service will use this parameter or 1,000 items, -// whichever is smaller. +// MaxResults sets the optional parameter "maxResults": Maximum number of items +// plus prefixes to return in a single page of responses. As duplicate prefixes +// are omitted, fewer total results may be returned than requested. The service +// will use this parameter or 1,000 items, whichever is smaller. func (c *ObjectsListCall) MaxResults(maxResults int64) *ObjectsListCall { c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *ObjectsListCall) PageToken(pageToken string) *ObjectsListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// Prefix sets the optional parameter "prefix": Filter results to -// objects whose names begin with this prefix. +// Prefix sets the optional parameter "prefix": Filter results to objects whose +// names begin with this prefix. func (c *ObjectsListCall) Prefix(prefix string) *ObjectsListCall { c.urlParams_.Set("prefix", prefix) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl. // // Possible values: // @@ -14474,65 +10212,61 @@ func (c *ObjectsListCall) Projection(projection string) *ObjectsListCall { } // SoftDeleted sets the optional parameter "softDeleted": If true, only -// soft-deleted object versions will be listed. The default is false. -// For more information, see Soft Delete. +// soft-deleted object versions will be listed. The default is false. For more +// information, see Soft Delete. func (c *ObjectsListCall) SoftDeleted(softDeleted bool) *ObjectsListCall { c.urlParams_.Set("softDeleted", fmt.Sprint(softDeleted)) return c } -// StartOffset sets the optional parameter "startOffset": Filter results -// to objects whose names are lexicographically equal to or after -// startOffset. If endOffset is also set, the objects listed will have -// names between startOffset (inclusive) and endOffset (exclusive). +// StartOffset sets the optional parameter "startOffset": Filter results to +// objects whose names are lexicographically equal to or after startOffset. If +// endOffset is also set, the objects listed will have names between +// startOffset (inclusive) and endOffset (exclusive). func (c *ObjectsListCall) StartOffset(startOffset string) *ObjectsListCall { c.urlParams_.Set("startOffset", startOffset) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsListCall) UserProject(userProject string) *ObjectsListCall { c.urlParams_.Set("userProject", userProject) return c } -// Versions sets the optional parameter "versions": If true, lists all -// versions of an object as distinct results. The default is false. For -// more information, see Object Versioning. +// Versions sets the optional parameter "versions": If true, lists all versions +// of an object as distinct results. The default is false. For more +// information, see Object Versioning. func (c *ObjectsListCall) Versions(versions bool) *ObjectsListCall { c.urlParams_.Set("versions", fmt.Sprint(versions)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsListCall) Fields(s ...googleapi.Field) *ObjectsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ObjectsListCall) IfNoneMatch(entityTag string) *ObjectsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsListCall) Context(ctx context.Context) *ObjectsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14541,12 +10275,7 @@ func (c *ObjectsListCall) Header() http.Header { } func (c *ObjectsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -14567,12 +10296,10 @@ func (c *ObjectsListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.list" call. -// Exactly one of *Objects or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Objects.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Objects.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsListCall) Do(opts ...googleapi.CallOption) (*Objects, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14603,111 +10330,6 @@ func (c *ObjectsListCall) Do(opts ...googleapi.CallOption) (*Objects, error) { return nil, err } return ret, nil - // { - // "description": "Retrieves a list of objects matching the criteria.", - // "httpMethod": "GET", - // "id": "storage.objects.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which to look for objects.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "delimiter": { - // "description": "Returns results in a directory-like mode. items will contain only objects whose names, aside from the prefix, do not contain delimiter. Objects whose names, aside from the prefix, contain delimiter will have their name, truncated after the delimiter, returned in prefixes. Duplicate prefixes are omitted.", - // "location": "query", - // "type": "string" - // }, - // "endOffset": { - // "description": "Filter results to objects whose names are lexicographically before endOffset. If startOffset is also set, the objects listed will have names between startOffset (inclusive) and endOffset (exclusive).", - // "location": "query", - // "type": "string" - // }, - // "includeFoldersAsPrefixes": { - // "description": "Only applicable if delimiter is set to '/'. If true, will also include folders and managed folders (besides objects) in the returned prefixes.", - // "location": "query", - // "type": "boolean" - // }, - // "includeTrailingDelimiter": { - // "description": "If true, objects that end in exactly one instance of delimiter will have their metadata included in items in addition to prefixes.", - // "location": "query", - // "type": "boolean" - // }, - // "matchGlob": { - // "description": "Filter results to objects and prefixes that match this glob pattern.", - // "location": "query", - // "type": "string" - // }, - // "maxResults": { - // "default": "1000", - // "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", - // "format": "uint32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // }, - // "prefix": { - // "description": "Filter results to objects whose names begin with this prefix.", - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "softDeleted": { - // "description": "If true, only soft-deleted object versions will be listed. The default is false. For more information, see Soft Delete.", - // "location": "query", - // "type": "boolean" - // }, - // "startOffset": { - // "description": "Filter results to objects whose names are lexicographically equal to or after startOffset. If endOffset is also set, the objects listed will have names between startOffset (inclusive) and endOffset (exclusive).", - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // }, - // "versions": { - // "description": "If true, lists all versions of an object as distinct results. The default is false. For more information, see Object Versioning.", - // "location": "query", - // "type": "boolean" - // } - // }, - // "path": "b/{bucket}/o", - // "response": { - // "$ref": "Objects" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ], - // "supportsSubscription": true - // } - } // Pages invokes f for each page of results. @@ -14715,7 +10337,7 @@ func (c *ObjectsListCall) Do(opts ...googleapi.CallOption) (*Objects, error) { // The provided context supersedes any context provided to the Context method. func (c *ObjectsListCall) Pages(ctx context.Context, f func(*Objects) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -14731,8 +10353,6 @@ func (c *ObjectsListCall) Pages(ctx context.Context, f func(*Objects) error) err } } -// method id "storage.objects.patch": - type ObjectsPatchCall struct { s *Service bucket string @@ -14746,8 +10366,8 @@ type ObjectsPatchCall struct { // Patch: Patches an object's metadata. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Patch(bucket string, object string, object2 *Object) *ObjectsPatchCall { c := &ObjectsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -14757,45 +10377,44 @@ func (r *ObjectsService) Patch(bucket string, object string, object2 *Object) *O return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectsPatchCall) Generation(generation int64) *ObjectsPatchCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsPatchCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsPatchCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the object's current generation does not match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the object's current generation +// does not match the given value. If no live object exists, the precondition +// fails. Setting to 0 makes the operation succeed only if there is a live +// version of the object. func (c *ObjectsPatchCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsPatchCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's current metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's current +// metageneration matches the given value. func (c *ObjectsPatchCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsPatchCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the object's current metageneration does not match the given -// value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// object's current metageneration does not match the given value. func (c *ObjectsPatchCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsPatchCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c @@ -14803,8 +10422,8 @@ func (c *ObjectsPatchCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int // OverrideUnlockedRetention sets the optional parameter // "overrideUnlockedRetention": Must be true to remove the retention -// configuration, reduce its unlocked retention period, or change its -// mode from unlocked to locked. +// configuration, reduce its unlocked retention period, or change its mode from +// unlocked to locked. func (c *ObjectsPatchCall) OverrideUnlockedRetention(overrideUnlockedRetention bool) *ObjectsPatchCall { c.urlParams_.Set("overrideUnlockedRetention", fmt.Sprint(overrideUnlockedRetention)) return c @@ -14819,29 +10438,29 @@ func (c *ObjectsPatchCall) OverrideUnlockedRetention(overrideUnlockedRetention b // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *ObjectsPatchCall) PredefinedAcl(predefinedAcl string) *ObjectsPatchCall { c.urlParams_.Set("predefinedAcl", predefinedAcl) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to full. // // Possible values: // @@ -14852,31 +10471,29 @@ func (c *ObjectsPatchCall) Projection(projection string) *ObjectsPatchCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request, for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request, for Requester Pays buckets. func (c *ObjectsPatchCall) UserProject(userProject string) *ObjectsPatchCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsPatchCall) Fields(s ...googleapi.Field) *ObjectsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsPatchCall) Context(ctx context.Context) *ObjectsPatchCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -14885,18 +10502,12 @@ func (c *ObjectsPatchCall) Header() http.Header { } func (c *ObjectsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.object2) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/{object}") @@ -14914,12 +10525,10 @@ func (c *ObjectsPatchCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.patch" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsPatchCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -14950,118 +10559,7 @@ func (c *ObjectsPatchCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Patches an object's metadata.", - // "httpMethod": "PATCH", - // "id": "storage.objects.patch", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "overrideUnlockedRetention": { - // "description": "Must be true to remove the retention configuration, reduce its unlocked retention period, or change its mode from unlocked to locked.", - // "location": "query", - // "type": "boolean" - // }, - // "predefinedAcl": { - // "description": "Apply a predefined set of access controls to this object.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request, for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}", - // "request": { - // "$ref": "Object" - // }, - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objects.restore": +} type ObjectsRestoreCall struct { s *Service @@ -15076,8 +10574,8 @@ type ObjectsRestoreCall struct { // // - bucket: Name of the bucket in which the object resides. // - generation: Selects a specific revision of this object. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts. +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts. func (r *ObjectsService) Restore(bucket string, object string, generation int64) *ObjectsRestoreCall { c := &ObjectsRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.bucket = bucket @@ -15086,52 +10584,51 @@ func (r *ObjectsService) Restore(bucket string, object string, generation int64) return c } -// CopySourceAcl sets the optional parameter "copySourceAcl": If true, -// copies the source object's ACL; otherwise, uses the bucket's default -// object ACL. The default is false. +// CopySourceAcl sets the optional parameter "copySourceAcl": If true, copies +// the source object's ACL; otherwise, uses the bucket's default object ACL. +// The default is false. func (c *ObjectsRestoreCall) CopySourceAcl(copySourceAcl bool) *ObjectsRestoreCall { c.urlParams_.Set("copySourceAcl", fmt.Sprint(copySourceAcl)) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's one live -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's one live generation matches +// the given value. Setting to 0 makes the operation succeed only if there are +// no live versions of the object. func (c *ObjectsRestoreCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsRestoreCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// none of the object's live generations match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether none of the object's live +// generations match the given value. If no live object exists, the +// precondition fails. Setting to 0 makes the operation succeed only if there +// is a live version of the object. func (c *ObjectsRestoreCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsRestoreCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's one live metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's one live +// metageneration matches the given value. func (c *ObjectsRestoreCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsRestoreCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether none of the object's live metagenerations match the given -// value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether none +// of the object's live metagenerations match the given value. func (c *ObjectsRestoreCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsRestoreCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to full. // // Possible values: // @@ -15142,31 +10639,29 @@ func (c *ObjectsRestoreCall) Projection(projection string) *ObjectsRestoreCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsRestoreCall) UserProject(userProject string) *ObjectsRestoreCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsRestoreCall) Fields(s ...googleapi.Field) *ObjectsRestoreCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsRestoreCall) Context(ctx context.Context) *ObjectsRestoreCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsRestoreCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15175,12 +10670,7 @@ func (c *ObjectsRestoreCall) Header() http.Header { } func (c *ObjectsRestoreCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -15199,12 +10689,10 @@ func (c *ObjectsRestoreCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.restore" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsRestoreCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15235,96 +10723,7 @@ func (c *ObjectsRestoreCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Restores a soft-deleted object.", - // "httpMethod": "POST", - // "id": "storage.objects.restore", - // "parameterOrder": [ - // "bucket", - // "object", - // "generation" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "copySourceAcl": { - // "description": "If true, copies the source object's ACL; otherwise, uses the bucket's default object ACL. The default is false.", - // "location": "query", - // "type": "boolean" - // }, - // "generation": { - // "description": "Selects a specific revision of this object.", - // "format": "int64", - // "location": "query", - // "required": true, - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's one live generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether none of the object's live generations match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's one live metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether none of the object's live metagenerations match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see Encoding URI Path Parts.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/restore", - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objects.rewrite": +} type ObjectsRewriteCall struct { s *Service @@ -15341,19 +10740,16 @@ type ObjectsRewriteCall struct { // Rewrite: Rewrites a source object to a destination object. Optionally // overrides metadata. // -// - destinationBucket: Name of the bucket in which to store the new -// object. Overrides the provided object metadata's bucket value, if -// any. +// - destinationBucket: Name of the bucket in which to store the new object. +// Overrides the provided object metadata's bucket value, if any. // - destinationObject: Name of the new object. Required when the object -// metadata is not otherwise provided. Overrides the object metadata's -// name value, if any. For information about how to URL encode object -// names to be path safe, see Encoding URI Path Parts +// metadata is not otherwise provided. Overrides the object metadata's name +// value, if any. For information about how to URL encode object names to be +// path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). -// - sourceBucket: Name of the bucket in which to find the source -// object. -// - sourceObject: Name of the source object. For information about how -// to URL encode object names to be path safe, see Encoding URI Path -// Parts +// - sourceBucket: Name of the bucket in which to find the source object. +// - sourceObject: Name of the source object. For information about how to URL +// encode object names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Rewrite(sourceBucket string, sourceObject string, destinationBucket string, destinationObject string, object *Object) *ObjectsRewriteCall { c := &ObjectsRewriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -15365,22 +10761,19 @@ func (r *ObjectsService) Rewrite(sourceBucket string, sourceObject string, desti return c } -// DestinationKmsKeyName sets the optional parameter -// "destinationKmsKeyName": Resource name of the Cloud KMS key, of the -// form -// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, -// -// that will be used to encrypt the object. Overrides the object -// -// metadata's kms_key_name value, if any. +// DestinationKmsKeyName sets the optional parameter "destinationKmsKeyName": +// Resource name of the Cloud KMS key, of the form +// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that +// will be used to encrypt the object. Overrides the object metadata's +// kms_key_name value, if any. func (c *ObjectsRewriteCall) DestinationKmsKeyName(destinationKmsKeyName string) *ObjectsRewriteCall { c.urlParams_.Set("destinationKmsKeyName", destinationKmsKeyName) return c } // DestinationPredefinedAcl sets the optional parameter -// "destinationPredefinedAcl": Apply a predefined set of access controls -// to the destination object. +// "destinationPredefinedAcl": Apply a predefined set of access controls to the +// destination object. // // Possible values: // @@ -15388,94 +10781,89 @@ func (c *ObjectsRewriteCall) DestinationKmsKeyName(destinationKmsKeyName string) // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *ObjectsRewriteCall) DestinationPredefinedAcl(destinationPredefinedAcl string) *ObjectsRewriteCall { c.urlParams_.Set("destinationPredefinedAcl", destinationPredefinedAcl) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsRewriteCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the object's current generation does not match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the object's current generation +// does not match the given value. If no live object exists, the precondition +// fails. Setting to 0 makes the operation succeed only if there is a live +// version of the object. func (c *ObjectsRewriteCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the destination object's current metageneration matches the given -// value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the destination object's current +// metageneration matches the given value. func (c *ObjectsRewriteCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the destination object's current metageneration does not -// match the given value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// destination object's current metageneration does not match the given value. func (c *ObjectsRewriteCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c } // IfSourceGenerationMatch sets the optional parameter -// "ifSourceGenerationMatch": Makes the operation conditional on whether -// the source object's current generation matches the given value. +// "ifSourceGenerationMatch": Makes the operation conditional on whether the +// source object's current generation matches the given value. func (c *ObjectsRewriteCall) IfSourceGenerationMatch(ifSourceGenerationMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifSourceGenerationMatch", fmt.Sprint(ifSourceGenerationMatch)) return c } // IfSourceGenerationNotMatch sets the optional parameter -// "ifSourceGenerationNotMatch": Makes the operation conditional on -// whether the source object's current generation does not match the -// given value. +// "ifSourceGenerationNotMatch": Makes the operation conditional on whether the +// source object's current generation does not match the given value. func (c *ObjectsRewriteCall) IfSourceGenerationNotMatch(ifSourceGenerationNotMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifSourceGenerationNotMatch", fmt.Sprint(ifSourceGenerationNotMatch)) return c } // IfSourceMetagenerationMatch sets the optional parameter -// "ifSourceMetagenerationMatch": Makes the operation conditional on -// whether the source object's current metageneration matches the given -// value. +// "ifSourceMetagenerationMatch": Makes the operation conditional on whether +// the source object's current metageneration matches the given value. func (c *ObjectsRewriteCall) IfSourceMetagenerationMatch(ifSourceMetagenerationMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifSourceMetagenerationMatch", fmt.Sprint(ifSourceMetagenerationMatch)) return c } // IfSourceMetagenerationNotMatch sets the optional parameter -// "ifSourceMetagenerationNotMatch": Makes the operation conditional on -// whether the source object's current metageneration does not match the -// given value. +// "ifSourceMetagenerationNotMatch": Makes the operation conditional on whether +// the source object's current metageneration does not match the given value. func (c *ObjectsRewriteCall) IfSourceMetagenerationNotMatch(ifSourceMetagenerationNotMatch int64) *ObjectsRewriteCall { c.urlParams_.Set("ifSourceMetagenerationNotMatch", fmt.Sprint(ifSourceMetagenerationNotMatch)) return c @@ -15483,21 +10871,20 @@ func (c *ObjectsRewriteCall) IfSourceMetagenerationNotMatch(ifSourceMetagenerati // MaxBytesRewrittenPerCall sets the optional parameter // "maxBytesRewrittenPerCall": The maximum number of bytes that will be -// rewritten per rewrite request. Most callers shouldn't need to specify -// this parameter - it is primarily in place to support testing. If -// specified the value must be an integral multiple of 1 MiB (1048576). -// Also, this only applies to requests where the source and destination -// span locations and/or storage classes. Finally, this value must not -// change across rewrite calls else you'll get an error that the -// rewriteToken is invalid. +// rewritten per rewrite request. Most callers shouldn't need to specify this +// parameter - it is primarily in place to support testing. If specified the +// value must be an integral multiple of 1 MiB (1048576). Also, this only +// applies to requests where the source and destination span locations and/or +// storage classes. Finally, this value must not change across rewrite calls +// else you'll get an error that the rewriteToken is invalid. func (c *ObjectsRewriteCall) MaxBytesRewrittenPerCall(maxBytesRewrittenPerCall int64) *ObjectsRewriteCall { c.urlParams_.Set("maxBytesRewrittenPerCall", fmt.Sprint(maxBytesRewrittenPerCall)) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl, unless the object resource -// specifies the acl property, when it defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl, unless the object resource specifies the acl +// property, when it defaults to full. // // Possible values: // @@ -15508,50 +10895,47 @@ func (c *ObjectsRewriteCall) Projection(projection string) *ObjectsRewriteCall { return c } -// RewriteToken sets the optional parameter "rewriteToken": Include this -// field (from the previous rewrite response) on each rewrite request -// after the first one, until the rewrite response 'done' flag is true. -// Calls that provide a rewriteToken can omit all other request fields, -// but if included those fields must match the values provided in the -// first rewrite request. +// RewriteToken sets the optional parameter "rewriteToken": Include this field +// (from the previous rewrite response) on each rewrite request after the first +// one, until the rewrite response 'done' flag is true. Calls that provide a +// rewriteToken can omit all other request fields, but if included those fields +// must match the values provided in the first rewrite request. func (c *ObjectsRewriteCall) RewriteToken(rewriteToken string) *ObjectsRewriteCall { c.urlParams_.Set("rewriteToken", rewriteToken) return c } -// SourceGeneration sets the optional parameter "sourceGeneration": If -// present, selects a specific revision of the source object (as opposed -// to the latest version, the default). +// SourceGeneration sets the optional parameter "sourceGeneration": If present, +// selects a specific revision of the source object (as opposed to the latest +// version, the default). func (c *ObjectsRewriteCall) SourceGeneration(sourceGeneration int64) *ObjectsRewriteCall { c.urlParams_.Set("sourceGeneration", fmt.Sprint(sourceGeneration)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsRewriteCall) UserProject(userProject string) *ObjectsRewriteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsRewriteCall) Fields(s ...googleapi.Field) *ObjectsRewriteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsRewriteCall) Context(ctx context.Context) *ObjectsRewriteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsRewriteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15560,18 +10944,12 @@ func (c *ObjectsRewriteCall) Header() http.Header { } func (c *ObjectsRewriteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.object) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{sourceBucket}/o/{sourceObject}/rewriteTo/b/{destinationBucket}/o/{destinationObject}") @@ -15591,12 +10969,11 @@ func (c *ObjectsRewriteCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.rewrite" call. -// Exactly one of *RewriteResponse or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *RewriteResponse.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *RewriteResponse.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ObjectsRewriteCall) Do(opts ...googleapi.CallOption) (*RewriteResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15627,168 +11004,7 @@ func (c *ObjectsRewriteCall) Do(opts ...googleapi.CallOption) (*RewriteResponse, return nil, err } return ret, nil - // { - // "description": "Rewrites a source object to a destination object. Optionally overrides metadata.", - // "httpMethod": "POST", - // "id": "storage.objects.rewrite", - // "parameterOrder": [ - // "sourceBucket", - // "sourceObject", - // "destinationBucket", - // "destinationObject" - // ], - // "parameters": { - // "destinationBucket": { - // "description": "Name of the bucket in which to store the new object. Overrides the provided object metadata's bucket value, if any.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationKmsKeyName": { - // "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.", - // "location": "query", - // "type": "string" - // }, - // "destinationObject": { - // "description": "Name of the new object. Required when the object metadata is not otherwise provided. Overrides the object metadata's name value, if any. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "destinationPredefinedAcl": { - // "description": "Apply a predefined set of access controls to the destination object.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the destination object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the destination object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceGenerationMatch": { - // "description": "Makes the operation conditional on whether the source object's current generation matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the source object's current generation does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the source object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifSourceMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the source object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "maxBytesRewrittenPerCall": { - // "description": "The maximum number of bytes that will be rewritten per rewrite request. Most callers shouldn't need to specify this parameter - it is primarily in place to support testing. If specified the value must be an integral multiple of 1 MiB (1048576). Also, this only applies to requests where the source and destination span locations and/or storage classes. Finally, this value must not change across rewrite calls else you'll get an error that the rewriteToken is invalid.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl, unless the object resource specifies the acl property, when it defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "rewriteToken": { - // "description": "Include this field (from the previous rewrite response) on each rewrite request after the first one, until the rewrite response 'done' flag is true. Calls that provide a rewriteToken can omit all other request fields, but if included those fields must match the values provided in the first rewrite request.", - // "location": "query", - // "type": "string" - // }, - // "sourceBucket": { - // "description": "Name of the bucket in which to find the source object.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "sourceGeneration": { - // "description": "If present, selects a specific revision of the source object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "sourceObject": { - // "description": "Name of the source object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{sourceBucket}/o/{sourceObject}/rewriteTo/b/{destinationBucket}/o/{destinationObject}", - // "request": { - // "$ref": "Object" - // }, - // "response": { - // "$ref": "RewriteResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.setIamPolicy": +} type ObjectsSetIamPolicyCall struct { s *Service @@ -15803,8 +11019,8 @@ type ObjectsSetIamPolicyCall struct { // SetIamPolicy: Updates an IAM policy for the specified object. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) SetIamPolicy(bucket string, object string, policy *Policy) *ObjectsSetIamPolicyCall { c := &ObjectsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -15814,39 +11030,37 @@ func (r *ObjectsService) SetIamPolicy(bucket string, object string, policy *Poli return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectsSetIamPolicyCall) Generation(generation int64) *ObjectsSetIamPolicyCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsSetIamPolicyCall) UserProject(userProject string) *ObjectsSetIamPolicyCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsSetIamPolicyCall) Fields(s ...googleapi.Field) *ObjectsSetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsSetIamPolicyCall) Context(ctx context.Context) *ObjectsSetIamPolicyCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsSetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -15855,18 +11069,12 @@ func (c *ObjectsSetIamPolicyCall) Header() http.Header { } func (c *ObjectsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.policy) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/{object}/iam") @@ -15884,12 +11092,10 @@ func (c *ObjectsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.objects.setIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -15920,56 +11126,7 @@ func (c *ObjectsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, err return nil, err } return ret, nil - // { - // "description": "Updates an IAM policy for the specified object.", - // "httpMethod": "PUT", - // "id": "storage.objects.setIamPolicy", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/iam", - // "request": { - // "$ref": "Policy" - // }, - // "response": { - // "$ref": "Policy" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.testIamPermissions": +} type ObjectsTestIamPermissionsCall struct { s *Service @@ -15981,12 +11138,12 @@ type ObjectsTestIamPermissionsCall struct { header_ http.Header } -// TestIamPermissions: Tests a set of permissions on the given object to -// see which, if any, are held by the caller. +// TestIamPermissions: Tests a set of permissions on the given object to see +// which, if any, are held by the caller. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). // - permissions: Permissions to test. func (r *ObjectsService) TestIamPermissions(bucket string, object string, permissions []string) *ObjectsTestIamPermissionsCall { @@ -15997,49 +11154,45 @@ func (r *ObjectsService) TestIamPermissions(bucket string, object string, permis return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectsTestIamPermissionsCall) Generation(generation int64) *ObjectsTestIamPermissionsCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsTestIamPermissionsCall) UserProject(userProject string) *ObjectsTestIamPermissionsCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ObjectsTestIamPermissionsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ObjectsTestIamPermissionsCall) IfNoneMatch(entityTag string) *ObjectsTestIamPermissionsCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsTestIamPermissionsCall) Context(ctx context.Context) *ObjectsTestIamPermissionsCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsTestIamPermissionsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16048,12 +11201,7 @@ func (c *ObjectsTestIamPermissionsCall) Header() http.Header { } func (c *ObjectsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -16075,12 +11223,11 @@ func (c *ObjectsTestIamPermissionsCall) doRequest(alt string) (*http.Response, e } // Do executes the "storage.objects.testIamPermissions" call. -// Exactly one of *TestIamPermissionsResponse or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *TestIamPermissionsResponse.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *TestIamPermissionsResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *ObjectsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16111,63 +11258,7 @@ func (c *ObjectsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestI return nil, err } return ret, nil - // { - // "description": "Tests a set of permissions on the given object to see which, if any, are held by the caller.", - // "httpMethod": "GET", - // "id": "storage.objects.testIamPermissions", - // "parameterOrder": [ - // "bucket", - // "object", - // "permissions" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "permissions": { - // "description": "Permissions to test.", - // "location": "query", - // "repeated": true, - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}/iam/testPermissions", - // "response": { - // "$ref": "TestIamPermissionsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.objects.update": +} type ObjectsUpdateCall struct { s *Service @@ -16182,8 +11273,8 @@ type ObjectsUpdateCall struct { // Update: Updates an object's metadata. // // - bucket: Name of the bucket in which the object resides. -// - object: Name of the object. For information about how to URL encode -// object names to be path safe, see Encoding URI Path Parts +// - object: Name of the object. For information about how to URL encode object +// names to be path safe, see Encoding URI Path Parts // (https://cloud.google.com/storage/docs/request-endpoints#encoding). func (r *ObjectsService) Update(bucket string, object string, object2 *Object) *ObjectsUpdateCall { c := &ObjectsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -16193,45 +11284,44 @@ func (r *ObjectsService) Update(bucket string, object string, object2 *Object) * return c } -// Generation sets the optional parameter "generation": If present, -// selects a specific revision of this object (as opposed to the latest -// version, the default). +// Generation sets the optional parameter "generation": If present, selects a +// specific revision of this object (as opposed to the latest version, the +// default). func (c *ObjectsUpdateCall) Generation(generation int64) *ObjectsUpdateCall { c.urlParams_.Set("generation", fmt.Sprint(generation)) return c } -// IfGenerationMatch sets the optional parameter "ifGenerationMatch": -// Makes the operation conditional on whether the object's current -// generation matches the given value. Setting to 0 makes the operation -// succeed only if there are no live versions of the object. +// IfGenerationMatch sets the optional parameter "ifGenerationMatch": Makes the +// operation conditional on whether the object's current generation matches the +// given value. Setting to 0 makes the operation succeed only if there are no +// live versions of the object. func (c *ObjectsUpdateCall) IfGenerationMatch(ifGenerationMatch int64) *ObjectsUpdateCall { c.urlParams_.Set("ifGenerationMatch", fmt.Sprint(ifGenerationMatch)) return c } -// IfGenerationNotMatch sets the optional parameter -// "ifGenerationNotMatch": Makes the operation conditional on whether -// the object's current generation does not match the given value. If no -// live object exists, the precondition fails. Setting to 0 makes the -// operation succeed only if there is a live version of the object. +// IfGenerationNotMatch sets the optional parameter "ifGenerationNotMatch": +// Makes the operation conditional on whether the object's current generation +// does not match the given value. If no live object exists, the precondition +// fails. Setting to 0 makes the operation succeed only if there is a live +// version of the object. func (c *ObjectsUpdateCall) IfGenerationNotMatch(ifGenerationNotMatch int64) *ObjectsUpdateCall { c.urlParams_.Set("ifGenerationNotMatch", fmt.Sprint(ifGenerationNotMatch)) return c } -// IfMetagenerationMatch sets the optional parameter -// "ifMetagenerationMatch": Makes the operation conditional on whether -// the object's current metageneration matches the given value. +// IfMetagenerationMatch sets the optional parameter "ifMetagenerationMatch": +// Makes the operation conditional on whether the object's current +// metageneration matches the given value. func (c *ObjectsUpdateCall) IfMetagenerationMatch(ifMetagenerationMatch int64) *ObjectsUpdateCall { c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch)) return c } // IfMetagenerationNotMatch sets the optional parameter -// "ifMetagenerationNotMatch": Makes the operation conditional on -// whether the object's current metageneration does not match the given -// value. +// "ifMetagenerationNotMatch": Makes the operation conditional on whether the +// object's current metageneration does not match the given value. func (c *ObjectsUpdateCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int64) *ObjectsUpdateCall { c.urlParams_.Set("ifMetagenerationNotMatch", fmt.Sprint(ifMetagenerationNotMatch)) return c @@ -16239,8 +11329,8 @@ func (c *ObjectsUpdateCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch in // OverrideUnlockedRetention sets the optional parameter // "overrideUnlockedRetention": Must be true to remove the retention -// configuration, reduce its unlocked retention period, or change its -// mode from unlocked to locked. +// configuration, reduce its unlocked retention period, or change its mode from +// unlocked to locked. func (c *ObjectsUpdateCall) OverrideUnlockedRetention(overrideUnlockedRetention bool) *ObjectsUpdateCall { c.urlParams_.Set("overrideUnlockedRetention", fmt.Sprint(overrideUnlockedRetention)) return c @@ -16255,29 +11345,29 @@ func (c *ObjectsUpdateCall) OverrideUnlockedRetention(overrideUnlockedRetention // // allAuthenticatedUsers get READER access. // -// "bucketOwnerFullControl" - Object owner gets OWNER access, and +// "bucketOwnerFullControl" - Object owner gets OWNER access, and project // -// project team owners get OWNER access. +// team owners get OWNER access. // -// "bucketOwnerRead" - Object owner gets OWNER access, and project +// "bucketOwnerRead" - Object owner gets OWNER access, and project team // -// team owners get READER access. +// owners get READER access. // // "private" - Object owner gets OWNER access. // "projectPrivate" - Object owner gets OWNER access, and project team // // members get access according to their roles. // -// "publicRead" - Object owner gets OWNER access, and allUsers get +// "publicRead" - Object owner gets OWNER access, and allUsers get READER // -// READER access. +// access. func (c *ObjectsUpdateCall) PredefinedAcl(predefinedAcl string) *ObjectsUpdateCall { c.urlParams_.Set("predefinedAcl", predefinedAcl) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to full. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to full. // // Possible values: // @@ -16288,31 +11378,29 @@ func (c *ObjectsUpdateCall) Projection(projection string) *ObjectsUpdateCall { return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsUpdateCall) UserProject(userProject string) *ObjectsUpdateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsUpdateCall) Fields(s ...googleapi.Field) *ObjectsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsUpdateCall) Context(ctx context.Context) *ObjectsUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16321,18 +11409,12 @@ func (c *ObjectsUpdateCall) Header() http.Header { } func (c *ObjectsUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.object2) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/{object}") @@ -16350,12 +11432,10 @@ func (c *ObjectsUpdateCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.update" call. -// Exactly one of *Object or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Object.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Object.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsUpdateCall) Do(opts ...googleapi.CallOption) (*Object, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16386,118 +11466,7 @@ func (c *ObjectsUpdateCall) Do(opts ...googleapi.CallOption) (*Object, error) { return nil, err } return ret, nil - // { - // "description": "Updates an object's metadata.", - // "httpMethod": "PUT", - // "id": "storage.objects.update", - // "parameterOrder": [ - // "bucket", - // "object" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which the object resides.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "generation": { - // "description": "If present, selects a specific revision of this object (as opposed to the latest version, the default).", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifGenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration matches the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "ifMetagenerationNotMatch": { - // "description": "Makes the operation conditional on whether the object's current metageneration does not match the given value.", - // "format": "int64", - // "location": "query", - // "type": "string" - // }, - // "object": { - // "description": "Name of the object. For information about how to URL encode object names to be path safe, see [Encoding URI Path Parts](https://cloud.google.com/storage/docs/request-endpoints#encoding).", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "overrideUnlockedRetention": { - // "description": "Must be true to remove the retention configuration, reduce its unlocked retention period, or change its mode from unlocked to locked.", - // "location": "query", - // "type": "boolean" - // }, - // "predefinedAcl": { - // "description": "Apply a predefined set of access controls to this object.", - // "enum": [ - // "authenticatedRead", - // "bucketOwnerFullControl", - // "bucketOwnerRead", - // "private", - // "projectPrivate", - // "publicRead" - // ], - // "enumDescriptions": [ - // "Object owner gets OWNER access, and allAuthenticatedUsers get READER access.", - // "Object owner gets OWNER access, and project team owners get OWNER access.", - // "Object owner gets OWNER access, and project team owners get READER access.", - // "Object owner gets OWNER access.", - // "Object owner gets OWNER access, and project team members get access according to their roles.", - // "Object owner gets OWNER access, and allUsers get READER access." - // ], - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to full.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/o/{object}", - // "request": { - // "$ref": "Object" - // }, - // "response": { - // "$ref": "Object" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.objects.watchAll": +} type ObjectsWatchAllCall struct { s *Service @@ -16518,21 +11487,20 @@ func (r *ObjectsService) WatchAll(bucket string, channel *Channel) *ObjectsWatch return c } -// Delimiter sets the optional parameter "delimiter": Returns results in -// a directory-like mode. items will contain only objects whose names, -// aside from the prefix, do not contain delimiter. Objects whose names, -// aside from the prefix, contain delimiter will have their name, -// truncated after the delimiter, returned in prefixes. Duplicate -// prefixes are omitted. +// Delimiter sets the optional parameter "delimiter": Returns results in a +// directory-like mode. items will contain only objects whose names, aside from +// the prefix, do not contain delimiter. Objects whose names, aside from the +// prefix, contain delimiter will have their name, truncated after the +// delimiter, returned in prefixes. Duplicate prefixes are omitted. func (c *ObjectsWatchAllCall) Delimiter(delimiter string) *ObjectsWatchAllCall { c.urlParams_.Set("delimiter", delimiter) return c } -// EndOffset sets the optional parameter "endOffset": Filter results to -// objects whose names are lexicographically before endOffset. If -// startOffset is also set, the objects listed will have names between -// startOffset (inclusive) and endOffset (exclusive). +// EndOffset sets the optional parameter "endOffset": Filter results to objects +// whose names are lexicographically before endOffset. If startOffset is also +// set, the objects listed will have names between startOffset (inclusive) and +// endOffset (exclusive). func (c *ObjectsWatchAllCall) EndOffset(endOffset string) *ObjectsWatchAllCall { c.urlParams_.Set("endOffset", endOffset) return c @@ -16540,40 +11508,38 @@ func (c *ObjectsWatchAllCall) EndOffset(endOffset string) *ObjectsWatchAllCall { // IncludeTrailingDelimiter sets the optional parameter // "includeTrailingDelimiter": If true, objects that end in exactly one -// instance of delimiter will have their metadata included in items in -// addition to prefixes. +// instance of delimiter will have their metadata included in items in addition +// to prefixes. func (c *ObjectsWatchAllCall) IncludeTrailingDelimiter(includeTrailingDelimiter bool) *ObjectsWatchAllCall { c.urlParams_.Set("includeTrailingDelimiter", fmt.Sprint(includeTrailingDelimiter)) return c } -// MaxResults sets the optional parameter "maxResults": Maximum number -// of items plus prefixes to return in a single page of responses. As -// duplicate prefixes are omitted, fewer total results may be returned -// than requested. The service will use this parameter or 1,000 items, -// whichever is smaller. +// MaxResults sets the optional parameter "maxResults": Maximum number of items +// plus prefixes to return in a single page of responses. As duplicate prefixes +// are omitted, fewer total results may be returned than requested. The service +// will use this parameter or 1,000 items, whichever is smaller. func (c *ObjectsWatchAllCall) MaxResults(maxResults int64) *ObjectsWatchAllCall { c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *ObjectsWatchAllCall) PageToken(pageToken string) *ObjectsWatchAllCall { c.urlParams_.Set("pageToken", pageToken) return c } -// Prefix sets the optional parameter "prefix": Filter results to -// objects whose names begin with this prefix. +// Prefix sets the optional parameter "prefix": Filter results to objects whose +// names begin with this prefix. func (c *ObjectsWatchAllCall) Prefix(prefix string) *ObjectsWatchAllCall { c.urlParams_.Set("prefix", prefix) return c } -// Projection sets the optional parameter "projection": Set of -// properties to return. Defaults to noAcl. +// Projection sets the optional parameter "projection": Set of properties to +// return. Defaults to noAcl. // // Possible values: // @@ -16584,48 +11550,46 @@ func (c *ObjectsWatchAllCall) Projection(projection string) *ObjectsWatchAllCall return c } -// StartOffset sets the optional parameter "startOffset": Filter results -// to objects whose names are lexicographically equal to or after -// startOffset. If endOffset is also set, the objects listed will have -// names between startOffset (inclusive) and endOffset (exclusive). +// StartOffset sets the optional parameter "startOffset": Filter results to +// objects whose names are lexicographically equal to or after startOffset. If +// endOffset is also set, the objects listed will have names between +// startOffset (inclusive) and endOffset (exclusive). func (c *ObjectsWatchAllCall) StartOffset(startOffset string) *ObjectsWatchAllCall { c.urlParams_.Set("startOffset", startOffset) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. Required for Requester Pays buckets. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. Required for Requester Pays buckets. func (c *ObjectsWatchAllCall) UserProject(userProject string) *ObjectsWatchAllCall { c.urlParams_.Set("userProject", userProject) return c } -// Versions sets the optional parameter "versions": If true, lists all -// versions of an object as distinct results. The default is false. For -// more information, see Object Versioning. +// Versions sets the optional parameter "versions": If true, lists all versions +// of an object as distinct results. The default is false. For more +// information, see Object Versioning. func (c *ObjectsWatchAllCall) Versions(versions bool) *ObjectsWatchAllCall { c.urlParams_.Set("versions", fmt.Sprint(versions)) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ObjectsWatchAllCall) Fields(s ...googleapi.Field) *ObjectsWatchAllCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ObjectsWatchAllCall) Context(ctx context.Context) *ObjectsWatchAllCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ObjectsWatchAllCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16634,18 +11598,12 @@ func (c *ObjectsWatchAllCall) Header() http.Header { } func (c *ObjectsWatchAllCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.channel) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/o/watch") @@ -16662,12 +11620,10 @@ func (c *ObjectsWatchAllCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.objects.watchAll" call. -// Exactly one of *Channel or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Channel.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *Channel.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ObjectsWatchAllCall) Do(opts ...googleapi.CallOption) (*Channel, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -16698,103 +11654,7 @@ func (c *ObjectsWatchAllCall) Do(opts ...googleapi.CallOption) (*Channel, error) return nil, err } return ret, nil - // { - // "description": "Watch for changes on all objects in a bucket.", - // "httpMethod": "POST", - // "id": "storage.objects.watchAll", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which to look for objects.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "delimiter": { - // "description": "Returns results in a directory-like mode. items will contain only objects whose names, aside from the prefix, do not contain delimiter. Objects whose names, aside from the prefix, contain delimiter will have their name, truncated after the delimiter, returned in prefixes. Duplicate prefixes are omitted.", - // "location": "query", - // "type": "string" - // }, - // "endOffset": { - // "description": "Filter results to objects whose names are lexicographically before endOffset. If startOffset is also set, the objects listed will have names between startOffset (inclusive) and endOffset (exclusive).", - // "location": "query", - // "type": "string" - // }, - // "includeTrailingDelimiter": { - // "description": "If true, objects that end in exactly one instance of delimiter will have their metadata included in items in addition to prefixes.", - // "location": "query", - // "type": "boolean" - // }, - // "maxResults": { - // "default": "1000", - // "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", - // "format": "uint32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // }, - // "prefix": { - // "description": "Filter results to objects whose names begin with this prefix.", - // "location": "query", - // "type": "string" - // }, - // "projection": { - // "description": "Set of properties to return. Defaults to noAcl.", - // "enum": [ - // "full", - // "noAcl" - // ], - // "enumDescriptions": [ - // "Include all properties.", - // "Omit the owner, acl property." - // ], - // "location": "query", - // "type": "string" - // }, - // "startOffset": { - // "description": "Filter results to objects whose names are lexicographically equal to or after startOffset. If endOffset is also set, the objects listed will have names between startOffset (inclusive) and endOffset (exclusive).", - // "location": "query", - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request. Required for Requester Pays buckets.", - // "location": "query", - // "type": "string" - // }, - // "versions": { - // "description": "If true, lists all versions of an object as distinct results. The default is false. For more information, see Object Versioning.", - // "location": "query", - // "type": "boolean" - // } - // }, - // "path": "b/{bucket}/o/watch", - // "request": { - // "$ref": "Channel", - // "parameterName": "resource" - // }, - // "response": { - // "$ref": "Channel" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ], - // "supportsSubscription": true - // } - -} - -// method id "storage.buckets.operations.cancel": +} type OperationsCancelCall struct { s *Service @@ -16805,9 +11665,9 @@ type OperationsCancelCall struct { header_ http.Header } -// Cancel: Starts asynchronous cancellation on a long-running operation. -// The server makes a best effort to cancel the operation, but success -// is not guaranteed. +// Cancel: Starts asynchronous cancellation on a long-running operation. The +// server makes a best effort to cancel the operation, but success is not +// guaranteed. // // - bucket: The parent bucket of the operation resource. // - operationId: The ID of the operation resource. @@ -16819,23 +11679,21 @@ func (r *OperationsService) Cancel(bucket string, operationId string) *Operation } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *OperationsCancelCall) Fields(s ...googleapi.Field) *OperationsCancelCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *OperationsCancelCall) Context(ctx context.Context) *OperationsCancelCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *OperationsCancelCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16844,12 +11702,7 @@ func (c *OperationsCancelCall) Header() http.Header { } func (c *OperationsCancelCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -16879,39 +11732,7 @@ func (c *OperationsCancelCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed.", - // "httpMethod": "POST", - // "id": "storage.buckets.operations.cancel", - // "parameterOrder": [ - // "bucket", - // "operationId" - // ], - // "parameters": { - // "bucket": { - // "description": "The parent bucket of the operation resource.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "operationId": { - // "description": "The ID of the operation resource.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/operations/{operationId}/cancel", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.operations.get": +} type OperationsGetCall struct { s *Service @@ -16935,33 +11756,29 @@ func (r *OperationsService) Get(bucket string, operationId string) *OperationsGe } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *OperationsGetCall) Fields(s ...googleapi.Field) *OperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *OperationsGetCall) IfNoneMatch(entityTag string) *OperationsGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *OperationsGetCall) Context(ctx context.Context) *OperationsGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *OperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -16970,12 +11787,7 @@ func (c *OperationsGetCall) Header() http.Header { } func (c *OperationsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -16997,12 +11809,11 @@ func (c *OperationsGetCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *OperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17033,44 +11844,7 @@ func (c *OperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunning return nil, err } return ret, nil - // { - // "description": "Gets the latest state of a long-running operation.", - // "httpMethod": "GET", - // "id": "storage.buckets.operations.get", - // "parameterOrder": [ - // "bucket", - // "operationId" - // ], - // "parameters": { - // "bucket": { - // "description": "The parent bucket of the operation resource.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "operationId": { - // "description": "The ID of the operation resource.", - // "location": "path", - // "required": true, - // "type": "string" - // } - // }, - // "path": "b/{bucket}/operations/{operationId}", - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.buckets.operations.list": +} type OperationsListCall struct { s *Service @@ -17081,8 +11855,7 @@ type OperationsListCall struct { header_ http.Header } -// List: Lists operations that match the specified filter in the -// request. +// List: Lists operations that match the specified filter in the request. // // - bucket: Name of the bucket in which to look for operations. func (r *OperationsService) List(bucket string) *OperationsListCall { @@ -17091,59 +11864,54 @@ func (r *OperationsService) List(bucket string) *OperationsListCall { return c } -// Filter sets the optional parameter "filter": A filter to narrow down -// results to a preferred subset. The filtering language is documented -// in more detail in AIP-160 (https://google.aip.dev/160). +// Filter sets the optional parameter "filter": A filter to narrow down results +// to a preferred subset. The filtering language is documented in more detail +// in AIP-160 (https://google.aip.dev/160). func (c *OperationsListCall) Filter(filter string) *OperationsListCall { c.urlParams_.Set("filter", filter) return c } -// PageSize sets the optional parameter "pageSize": Maximum number of -// items to return in a single page of responses. Fewer total results -// may be returned than requested. The service uses this parameter or -// 100 items, whichever is smaller. +// PageSize sets the optional parameter "pageSize": Maximum number of items to +// return in a single page of responses. Fewer total results may be returned +// than requested. The service uses this parameter or 100 items, whichever is +// smaller. func (c *OperationsListCall) PageSize(pageSize int64) *OperationsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *OperationsListCall) PageToken(pageToken string) *OperationsListCall { c.urlParams_.Set("pageToken", pageToken) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *OperationsListCall) Fields(s ...googleapi.Field) *OperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *OperationsListCall) IfNoneMatch(entityTag string) *OperationsListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *OperationsListCall) Context(ctx context.Context) *OperationsListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *OperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17152,12 +11920,7 @@ func (c *OperationsListCall) Header() http.Header { } func (c *OperationsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -17178,13 +11941,11 @@ func (c *OperationsListCall) doRequest(alt string) (*http.Response, error) { } // Do executes the "storage.buckets.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if -// a response was returned at all) in error.(*googleapi.Error).Header. -// Use googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17215,51 +11976,6 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunnin return nil, err } return ret, nil - // { - // "description": "Lists operations that match the specified filter in the request.", - // "httpMethod": "GET", - // "id": "storage.buckets.operations.list", - // "parameterOrder": [ - // "bucket" - // ], - // "parameters": { - // "bucket": { - // "description": "Name of the bucket in which to look for operations.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "filter": { - // "description": "A filter to narrow down results to a preferred subset. The filtering language is documented in more detail in [AIP-160](https://google.aip.dev/160).", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Maximum number of items to return in a single page of responses. Fewer total results may be returned than requested. The service uses this parameter or 100 items, whichever is smaller.", - // "format": "int32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "b/{bucket}/operations", - // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - } // Pages invokes f for each page of results. @@ -17267,7 +11983,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunnin // The provided context supersedes any context provided to the Context method. func (c *OperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -17283,8 +11999,6 @@ func (c *OperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunnin } } -// method id "storage.projects.hmacKeys.create": - type ProjectsHmacKeysCreateCall struct { s *Service projectId string @@ -17304,31 +12018,29 @@ func (r *ProjectsHmacKeysService) Create(projectId string, serviceAccountEmail s return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *ProjectsHmacKeysCreateCall) UserProject(userProject string) *ProjectsHmacKeysCreateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsHmacKeysCreateCall) Fields(s ...googleapi.Field) *ProjectsHmacKeysCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsHmacKeysCreateCall) Context(ctx context.Context) *ProjectsHmacKeysCreateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsHmacKeysCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17337,12 +12049,7 @@ func (c *ProjectsHmacKeysCreateCall) Header() http.Header { } func (c *ProjectsHmacKeysCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -17360,12 +12067,10 @@ func (c *ProjectsHmacKeysCreateCall) doRequest(alt string) (*http.Response, erro } // Do executes the "storage.projects.hmacKeys.create" call. -// Exactly one of *HmacKey or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *HmacKey.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to -// check whether the returned error was because http.StatusNotModified -// was returned. +// Any non-2xx status code is an error. Response headers are in either +// *HmacKey.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsHmacKeysCreateCall) Do(opts ...googleapi.CallOption) (*HmacKey, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17396,46 +12101,7 @@ func (c *ProjectsHmacKeysCreateCall) Do(opts ...googleapi.CallOption) (*HmacKey, return nil, err } return ret, nil - // { - // "description": "Creates a new HMAC key for the specified service account.", - // "httpMethod": "POST", - // "id": "storage.projects.hmacKeys.create", - // "parameterOrder": [ - // "projectId", - // "serviceAccountEmail" - // ], - // "parameters": { - // "projectId": { - // "description": "Project ID owning the service account.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "serviceAccountEmail": { - // "description": "Email address of the service account.", - // "location": "query", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "projects/{projectId}/hmacKeys", - // "response": { - // "$ref": "HmacKey" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.projects.hmacKeys.delete": +} type ProjectsHmacKeysDeleteCall struct { s *Service @@ -17457,31 +12123,29 @@ func (r *ProjectsHmacKeysService) Delete(projectId string, accessId string) *Pro return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *ProjectsHmacKeysDeleteCall) UserProject(userProject string) *ProjectsHmacKeysDeleteCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsHmacKeysDeleteCall) Fields(s ...googleapi.Field) *ProjectsHmacKeysDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsHmacKeysDeleteCall) Context(ctx context.Context) *ProjectsHmacKeysDeleteCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsHmacKeysDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17490,12 +12154,7 @@ func (c *ProjectsHmacKeysDeleteCall) Header() http.Header { } func (c *ProjectsHmacKeysDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") @@ -17525,44 +12184,7 @@ func (c *ProjectsHmacKeysDeleteCall) Do(opts ...googleapi.CallOption) error { return gensupport.WrapError(err) } return nil - // { - // "description": "Deletes an HMAC key.", - // "httpMethod": "DELETE", - // "id": "storage.projects.hmacKeys.delete", - // "parameterOrder": [ - // "projectId", - // "accessId" - // ], - // "parameters": { - // "accessId": { - // "description": "Name of the HMAC key to be deleted.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Project ID owning the requested key", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "projects/{projectId}/hmacKeys/{accessId}", - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - -} - -// method id "storage.projects.hmacKeys.get": +} type ProjectsHmacKeysGetCall struct { s *Service @@ -17576,9 +12198,8 @@ type ProjectsHmacKeysGetCall struct { // Get: Retrieves an HMAC key's metadata // -// - accessId: Name of the HMAC key. -// - projectId: Project ID owning the service account of the requested -// key. +// - accessId: Name of the HMAC key. +// - projectId: Project ID owning the service account of the requested key. func (r *ProjectsHmacKeysService) Get(projectId string, accessId string) *ProjectsHmacKeysGetCall { c := &ProjectsHmacKeysGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17586,41 +12207,37 @@ func (r *ProjectsHmacKeysService) Get(projectId string, accessId string) *Projec return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *ProjectsHmacKeysGetCall) UserProject(userProject string) *ProjectsHmacKeysGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsHmacKeysGetCall) Fields(s ...googleapi.Field) *ProjectsHmacKeysGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsHmacKeysGetCall) IfNoneMatch(entityTag string) *ProjectsHmacKeysGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsHmacKeysGetCall) Context(ctx context.Context) *ProjectsHmacKeysGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsHmacKeysGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17629,12 +12246,7 @@ func (c *ProjectsHmacKeysGetCall) Header() http.Header { } func (c *ProjectsHmacKeysGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -17656,12 +12268,11 @@ func (c *ProjectsHmacKeysGetCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.projects.hmacKeys.get" call. -// Exactly one of *HmacKeyMetadata or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *HmacKeyMetadata.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *HmacKeyMetadata.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsHmacKeysGetCall) Do(opts ...googleapi.CallOption) (*HmacKeyMetadata, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17692,48 +12303,7 @@ func (c *ProjectsHmacKeysGetCall) Do(opts ...googleapi.CallOption) (*HmacKeyMeta return nil, err } return ret, nil - // { - // "description": "Retrieves an HMAC key's metadata", - // "httpMethod": "GET", - // "id": "storage.projects.hmacKeys.get", - // "parameterOrder": [ - // "projectId", - // "accessId" - // ], - // "parameters": { - // "accessId": { - // "description": "Name of the HMAC key.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Project ID owning the service account of the requested key.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "projects/{projectId}/hmacKeys/{accessId}", - // "response": { - // "$ref": "HmacKeyMetadata" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only" - // ] - // } - -} - -// method id "storage.projects.hmacKeys.list": +} type ProjectsHmacKeysListCall struct { s *Service @@ -17753,76 +12323,69 @@ func (r *ProjectsHmacKeysService) List(projectId string) *ProjectsHmacKeysListCa return c } -// MaxResults sets the optional parameter "maxResults": Maximum number -// of items to return in a single page of responses. The service uses -// this parameter or 250 items, whichever is smaller. The max number of -// items per page will also be limited by the number of distinct service -// accounts in the response. If the number of service accounts in a -// single response is too high, the page will truncated and a next page -// token will be returned. +// MaxResults sets the optional parameter "maxResults": Maximum number of items +// to return in a single page of responses. The service uses this parameter or +// 250 items, whichever is smaller. The max number of items per page will also +// be limited by the number of distinct service accounts in the response. If +// the number of service accounts in a single response is too high, the page +// will truncated and a next page token will be returned. func (c *ProjectsHmacKeysListCall) MaxResults(maxResults int64) *ProjectsHmacKeysListCall { c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) return c } -// PageToken sets the optional parameter "pageToken": A -// previously-returned page token representing part of the larger set of -// results to view. +// PageToken sets the optional parameter "pageToken": A previously-returned +// page token representing part of the larger set of results to view. func (c *ProjectsHmacKeysListCall) PageToken(pageToken string) *ProjectsHmacKeysListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// ServiceAccountEmail sets the optional parameter -// "serviceAccountEmail": If present, only keys for the given service -// account are returned. +// ServiceAccountEmail sets the optional parameter "serviceAccountEmail": If +// present, only keys for the given service account are returned. func (c *ProjectsHmacKeysListCall) ServiceAccountEmail(serviceAccountEmail string) *ProjectsHmacKeysListCall { c.urlParams_.Set("serviceAccountEmail", serviceAccountEmail) return c } -// ShowDeletedKeys sets the optional parameter "showDeletedKeys": -// Whether or not to show keys in the DELETED state. +// ShowDeletedKeys sets the optional parameter "showDeletedKeys": Whether or +// not to show keys in the DELETED state. func (c *ProjectsHmacKeysListCall) ShowDeletedKeys(showDeletedKeys bool) *ProjectsHmacKeysListCall { c.urlParams_.Set("showDeletedKeys", fmt.Sprint(showDeletedKeys)) return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *ProjectsHmacKeysListCall) UserProject(userProject string) *ProjectsHmacKeysListCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsHmacKeysListCall) Fields(s ...googleapi.Field) *ProjectsHmacKeysListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsHmacKeysListCall) IfNoneMatch(entityTag string) *ProjectsHmacKeysListCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsHmacKeysListCall) Context(ctx context.Context) *ProjectsHmacKeysListCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsHmacKeysListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -17831,12 +12394,7 @@ func (c *ProjectsHmacKeysListCall) Header() http.Header { } func (c *ProjectsHmacKeysListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -17857,12 +12415,11 @@ func (c *ProjectsHmacKeysListCall) doRequest(alt string) (*http.Response, error) } // Do executes the "storage.projects.hmacKeys.list" call. -// Exactly one of *HmacKeysMetadata or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *HmacKeysMetadata.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *HmacKeysMetadata.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsHmacKeysListCall) Do(opts ...googleapi.CallOption) (*HmacKeysMetadata, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -17893,61 +12450,6 @@ func (c *ProjectsHmacKeysListCall) Do(opts ...googleapi.CallOption) (*HmacKeysMe return nil, err } return ret, nil - // { - // "description": "Retrieves a list of HMAC keys matching the criteria.", - // "httpMethod": "GET", - // "id": "storage.projects.hmacKeys.list", - // "parameterOrder": [ - // "projectId" - // ], - // "parameters": { - // "maxResults": { - // "default": "250", - // "description": "Maximum number of items to return in a single page of responses. The service uses this parameter or 250 items, whichever is smaller. The max number of items per page will also be limited by the number of distinct service accounts in the response. If the number of service accounts in a single response is too high, the page will truncated and a next page token will be returned.", - // "format": "uint32", - // "location": "query", - // "minimum": "0", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A previously-returned page token representing part of the larger set of results to view.", - // "location": "query", - // "type": "string" - // }, - // "projectId": { - // "description": "Name of the project in which to look for HMAC keys.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "serviceAccountEmail": { - // "description": "If present, only keys for the given service account are returned.", - // "location": "query", - // "type": "string" - // }, - // "showDeletedKeys": { - // "description": "Whether or not to show keys in the DELETED state.", - // "location": "query", - // "type": "boolean" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "projects/{projectId}/hmacKeys", - // "response": { - // "$ref": "HmacKeysMetadata" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only" - // ] - // } - } // Pages invokes f for each page of results. @@ -17955,7 +12457,7 @@ func (c *ProjectsHmacKeysListCall) Do(opts ...googleapi.CallOption) (*HmacKeysMe // The provided context supersedes any context provided to the Context method. func (c *ProjectsHmacKeysListCall) Pages(ctx context.Context, f func(*HmacKeysMetadata) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) for { x, err := c.Do() if err != nil { @@ -17971,8 +12473,6 @@ func (c *ProjectsHmacKeysListCall) Pages(ctx context.Context, f func(*HmacKeysMe } } -// method id "storage.projects.hmacKeys.update": - type ProjectsHmacKeysUpdateCall struct { s *Service projectId string @@ -17986,9 +12486,8 @@ type ProjectsHmacKeysUpdateCall struct { // Update: Updates the state of an HMAC key. See the HMAC Key resource // descriptor for valid states. // -// - accessId: Name of the HMAC key being updated. -// - projectId: Project ID owning the service account of the updated -// key. +// - accessId: Name of the HMAC key being updated. +// - projectId: Project ID owning the service account of the updated key. func (r *ProjectsHmacKeysService) Update(projectId string, accessId string, hmackeymetadata *HmacKeyMetadata) *ProjectsHmacKeysUpdateCall { c := &ProjectsHmacKeysUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.projectId = projectId @@ -17997,31 +12496,29 @@ func (r *ProjectsHmacKeysService) Update(projectId string, accessId string, hmac return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *ProjectsHmacKeysUpdateCall) UserProject(userProject string) *ProjectsHmacKeysUpdateCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsHmacKeysUpdateCall) Fields(s ...googleapi.Field) *ProjectsHmacKeysUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsHmacKeysUpdateCall) Context(ctx context.Context) *ProjectsHmacKeysUpdateCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsHmacKeysUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18030,18 +12527,12 @@ func (c *ProjectsHmacKeysUpdateCall) Header() http.Header { } func (c *ProjectsHmacKeysUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) var body io.Reader = nil body, err := googleapi.WithoutDataWrapper.JSONReader(c.hmackeymetadata) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{projectId}/hmacKeys/{accessId}") @@ -18059,12 +12550,11 @@ func (c *ProjectsHmacKeysUpdateCall) doRequest(alt string) (*http.Response, erro } // Do executes the "storage.projects.hmacKeys.update" call. -// Exactly one of *HmacKeyMetadata or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *HmacKeyMetadata.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *HmacKeyMetadata.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. func (c *ProjectsHmacKeysUpdateCall) Do(opts ...googleapi.CallOption) (*HmacKeyMetadata, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18095,49 +12585,7 @@ func (c *ProjectsHmacKeysUpdateCall) Do(opts ...googleapi.CallOption) (*HmacKeyM return nil, err } return ret, nil - // { - // "description": "Updates the state of an HMAC key. See the HMAC Key resource descriptor for valid states.", - // "httpMethod": "PUT", - // "id": "storage.projects.hmacKeys.update", - // "parameterOrder": [ - // "projectId", - // "accessId" - // ], - // "parameters": { - // "accessId": { - // "description": "Name of the HMAC key being updated.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "projectId": { - // "description": "Project ID owning the service account of the updated key.", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "projects/{projectId}/hmacKeys/{accessId}", - // "request": { - // "$ref": "HmacKeyMetadata" - // }, - // "response": { - // "$ref": "HmacKeyMetadata" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/devstorage.full_control" - // ] - // } - -} - -// method id "storage.projects.serviceAccount.get": +} type ProjectsServiceAccountGetCall struct { s *Service @@ -18148,8 +12596,8 @@ type ProjectsServiceAccountGetCall struct { header_ http.Header } -// Get: Get the email address of this project's Google Cloud Storage -// service account. +// Get: Get the email address of this project's Google Cloud Storage service +// account. // // - projectId: Project ID. func (r *ProjectsServiceAccountService) Get(projectId string) *ProjectsServiceAccountGetCall { @@ -18158,41 +12606,37 @@ func (r *ProjectsServiceAccountService) Get(projectId string) *ProjectsServiceAc return c } -// UserProject sets the optional parameter "userProject": The project to -// be billed for this request. +// UserProject sets the optional parameter "userProject": The project to be +// billed for this request. func (c *ProjectsServiceAccountGetCall) UserProject(userProject string) *ProjectsServiceAccountGetCall { c.urlParams_.Set("userProject", userProject) return c } // Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. func (c *ProjectsServiceAccountGetCall) Fields(s ...googleapi.Field) *ProjectsServiceAccountGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. func (c *ProjectsServiceAccountGetCall) IfNoneMatch(entityTag string) *ProjectsServiceAccountGetCall { c.ifNoneMatch_ = entityTag return c } -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. +// Context sets the context to be used in this call's Do method. func (c *ProjectsServiceAccountGetCall) Context(ctx context.Context) *ProjectsServiceAccountGetCall { c.ctx_ = ctx return c } -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. func (c *ProjectsServiceAccountGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) @@ -18201,12 +12645,7 @@ func (c *ProjectsServiceAccountGetCall) Header() http.Header { } func (c *ProjectsServiceAccountGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } @@ -18227,12 +12666,10 @@ func (c *ProjectsServiceAccountGetCall) doRequest(alt string) (*http.Response, e } // Do executes the "storage.projects.serviceAccount.get" call. -// Exactly one of *ServiceAccount or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *ServiceAccount.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. +// Any non-2xx status code is an error. Response headers are in either +// *ServiceAccount.ServerResponse.Header or (if a response was returned at all) +// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. func (c *ProjectsServiceAccountGetCall) Do(opts ...googleapi.CallOption) (*ServiceAccount, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") @@ -18263,37 +12700,4 @@ func (c *ProjectsServiceAccountGetCall) Do(opts ...googleapi.CallOption) (*Servi return nil, err } return ret, nil - // { - // "description": "Get the email address of this project's Google Cloud Storage service account.", - // "httpMethod": "GET", - // "id": "storage.projects.serviceAccount.get", - // "parameterOrder": [ - // "projectId" - // ], - // "parameters": { - // "projectId": { - // "description": "Project ID", - // "location": "path", - // "required": true, - // "type": "string" - // }, - // "userProject": { - // "description": "The project to be billed for this request.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "projects/{projectId}/serviceAccount", - // "response": { - // "$ref": "ServiceAccount" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-platform.read-only", - // "https://www.googleapis.com/auth/devstorage.full_control", - // "https://www.googleapis.com/auth/devstorage.read_only", - // "https://www.googleapis.com/auth/devstorage.read_write" - // ] - // } - } diff --git a/vendor/google.golang.org/protobuf/encoding/protojson/encode.go b/vendor/google.golang.org/protobuf/encoding/protojson/encode.go index 3f75098b6f..29846df222 100644 --- a/vendor/google.golang.org/protobuf/encoding/protojson/encode.go +++ b/vendor/google.golang.org/protobuf/encoding/protojson/encode.go @@ -25,15 +25,17 @@ const defaultIndent = " " // Format formats the message as a multiline string. // This function is only intended for human consumption and ignores errors. -// Do not depend on the output being stable. It may change over time across -// different versions of the program. +// Do not depend on the output being stable. Its output will change across +// different builds of your program, even when using the same version of the +// protobuf module. func Format(m proto.Message) string { return MarshalOptions{Multiline: true}.Format(m) } // Marshal writes the given [proto.Message] in JSON format using default options. -// Do not depend on the output being stable. It may change over time across -// different versions of the program. +// Do not depend on the output being stable. Its output will change across +// different builds of your program, even when using the same version of the +// protobuf module. func Marshal(m proto.Message) ([]byte, error) { return MarshalOptions{}.Marshal(m) } @@ -110,8 +112,9 @@ type MarshalOptions struct { // Format formats the message as a string. // This method is only intended for human consumption and ignores errors. -// Do not depend on the output being stable. It may change over time across -// different versions of the program. +// Do not depend on the output being stable. Its output will change across +// different builds of your program, even when using the same version of the +// protobuf module. func (o MarshalOptions) Format(m proto.Message) string { if m == nil || !m.ProtoReflect().IsValid() { return "" // invalid syntax, but okay since this is for debugging @@ -122,8 +125,9 @@ func (o MarshalOptions) Format(m proto.Message) string { } // Marshal marshals the given [proto.Message] in the JSON format using options in -// MarshalOptions. Do not depend on the output being stable. It may change over -// time across different versions of the program. +// Do not depend on the output being stable. Its output will change across +// different builds of your program, even when using the same version of the +// protobuf module. func (o MarshalOptions) Marshal(m proto.Message) ([]byte, error) { return o.marshal(nil, m) } diff --git a/vendor/google.golang.org/protobuf/encoding/prototext/encode.go b/vendor/google.golang.org/protobuf/encoding/prototext/encode.go index 95967e8112..1f57e6610a 100644 --- a/vendor/google.golang.org/protobuf/encoding/prototext/encode.go +++ b/vendor/google.golang.org/protobuf/encoding/prototext/encode.go @@ -27,15 +27,17 @@ const defaultIndent = " " // Format formats the message as a multiline string. // This function is only intended for human consumption and ignores errors. -// Do not depend on the output being stable. It may change over time across -// different versions of the program. +// Do not depend on the output being stable. Its output will change across +// different builds of your program, even when using the same version of the +// protobuf module. func Format(m proto.Message) string { return MarshalOptions{Multiline: true}.Format(m) } // Marshal writes the given [proto.Message] in textproto format using default -// options. Do not depend on the output being stable. It may change over time -// across different versions of the program. +// options. Do not depend on the output being stable. Its output will change +// across different builds of your program, even when using the same version of +// the protobuf module. func Marshal(m proto.Message) ([]byte, error) { return MarshalOptions{}.Marshal(m) } @@ -84,8 +86,9 @@ type MarshalOptions struct { // Format formats the message as a string. // This method is only intended for human consumption and ignores errors. -// Do not depend on the output being stable. It may change over time across -// different versions of the program. +// Do not depend on the output being stable. Its output will change across +// different builds of your program, even when using the same version of the +// protobuf module. func (o MarshalOptions) Format(m proto.Message) string { if m == nil || !m.ProtoReflect().IsValid() { return "" // invalid syntax, but okay since this is for debugging @@ -98,8 +101,9 @@ func (o MarshalOptions) Format(m proto.Message) string { } // Marshal writes the given [proto.Message] in textproto format using options in -// MarshalOptions object. Do not depend on the output being stable. It may -// change over time across different versions of the program. +// MarshalOptions object. Do not depend on the output being stable. Its output +// will change across different builds of your program, even when using the +// same version of the protobuf module. func (o MarshalOptions) Marshal(m proto.Message) ([]byte, error) { return o.marshal(nil, m) } diff --git a/vendor/google.golang.org/protobuf/internal/descfmt/stringer.go b/vendor/google.golang.org/protobuf/internal/descfmt/stringer.go index a45625c8d1..87e46bd4df 100644 --- a/vendor/google.golang.org/protobuf/internal/descfmt/stringer.go +++ b/vendor/google.golang.org/protobuf/internal/descfmt/stringer.go @@ -252,6 +252,7 @@ func formatDescOpt(t protoreflect.Descriptor, isRoot, allowMulti bool, record fu {rv.MethodByName("Values"), "Values"}, {rv.MethodByName("ReservedNames"), "ReservedNames"}, {rv.MethodByName("ReservedRanges"), "ReservedRanges"}, + {rv.MethodByName("IsClosed"), "IsClosed"}, }...) case protoreflect.EnumValueDescriptor: diff --git a/vendor/google.golang.org/protobuf/internal/editiondefaults/editions_defaults.binpb b/vendor/google.golang.org/protobuf/internal/editiondefaults/editions_defaults.binpb index 18f0756874367adcdb790ffde125b6a7388b4eaa..f691305eb4f73440cd48caba949023eab52ef304 100644 GIT binary patch literal 78 zcmd-Q6B6WL6kw8IQef6#G+?@9$Hc)X@r<1dB+ewjD8Z<}1Qcfki8Dw%hln$xi@#u3 Kc*d^rf*k;APzzxI literal 63 zcmd-Q6yo7v6kw8IQef6#G+>f=#?A#2ViI7KU{qiN3NcDNhX^qu3B6!fc*d^rf*k<7 Cln3+x diff --git a/vendor/google.golang.org/protobuf/internal/editionssupport/editions.go b/vendor/google.golang.org/protobuf/internal/editionssupport/editions.go new file mode 100644 index 0000000000..029a6a12d7 --- /dev/null +++ b/vendor/google.golang.org/protobuf/internal/editionssupport/editions.go @@ -0,0 +1,13 @@ +// Copyright 2024 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. + +// Package editionssupport defines constants for editions that are supported. +package editionssupport + +import descriptorpb "google.golang.org/protobuf/types/descriptorpb" + +const ( + Minimum = descriptorpb.Edition_EDITION_PROTO2 + Maximum = descriptorpb.Edition_EDITION_2023 +) diff --git a/vendor/google.golang.org/protobuf/internal/encoding/tag/tag.go b/vendor/google.golang.org/protobuf/internal/encoding/tag/tag.go index 373d208374..7e87c76044 100644 --- a/vendor/google.golang.org/protobuf/internal/encoding/tag/tag.go +++ b/vendor/google.golang.org/protobuf/internal/encoding/tag/tag.go @@ -32,6 +32,7 @@ var byteType = reflect.TypeOf(byte(0)) func Unmarshal(tag string, goType reflect.Type, evs protoreflect.EnumValueDescriptors) protoreflect.FieldDescriptor { f := new(filedesc.Field) f.L0.ParentFile = filedesc.SurrogateProto2 + f.L1.EditionFeatures = f.L0.ParentFile.L1.EditionFeatures for len(tag) > 0 { i := strings.IndexByte(tag, ',') if i < 0 { @@ -107,8 +108,7 @@ func Unmarshal(tag string, goType reflect.Type, evs protoreflect.EnumValueDescri f.L1.StringName.InitJSON(jsonName) } case s == "packed": - f.L1.HasPacked = true - f.L1.IsPacked = true + f.L1.EditionFeatures.IsPacked = true case strings.HasPrefix(s, "weak="): f.L1.IsWeak = true f.L1.Message = filedesc.PlaceholderMessage(protoreflect.FullName(s[len("weak="):])) diff --git a/vendor/google.golang.org/protobuf/internal/errors/errors.go b/vendor/google.golang.org/protobuf/internal/errors/errors.go index 20c17b35e3..d96719829c 100644 --- a/vendor/google.golang.org/protobuf/internal/errors/errors.go +++ b/vendor/google.golang.org/protobuf/internal/errors/errors.go @@ -87,3 +87,18 @@ func InvalidUTF8(name string) error { func RequiredNotSet(name string) error { return New("required field %v not set", name) } + +type SizeMismatchError struct { + Calculated, Measured int +} + +func (e *SizeMismatchError) Error() string { + return fmt.Sprintf("size mismatch (see https://github.com/golang/protobuf/issues/1609): calculated=%d, measured=%d", e.Calculated, e.Measured) +} + +func MismatchedSizeCalculation(calculated, measured int) error { + return &SizeMismatchError{ + Calculated: calculated, + Measured: measured, + } +} diff --git a/vendor/google.golang.org/protobuf/internal/filedesc/desc.go b/vendor/google.golang.org/protobuf/internal/filedesc/desc.go index 8826bcf402..ece53bea32 100644 --- a/vendor/google.golang.org/protobuf/internal/filedesc/desc.go +++ b/vendor/google.golang.org/protobuf/internal/filedesc/desc.go @@ -7,6 +7,7 @@ package filedesc import ( "bytes" "fmt" + "strings" "sync" "sync/atomic" @@ -108,9 +109,12 @@ func (fd *File) ParentFile() protoreflect.FileDescriptor { return fd } func (fd *File) Parent() protoreflect.Descriptor { return nil } func (fd *File) Index() int { return 0 } func (fd *File) Syntax() protoreflect.Syntax { return fd.L1.Syntax } -func (fd *File) Name() protoreflect.Name { return fd.L1.Package.Name() } -func (fd *File) FullName() protoreflect.FullName { return fd.L1.Package } -func (fd *File) IsPlaceholder() bool { return false } + +// Not exported and just used to reconstruct the original FileDescriptor proto +func (fd *File) Edition() int32 { return int32(fd.L1.Edition) } +func (fd *File) Name() protoreflect.Name { return fd.L1.Package.Name() } +func (fd *File) FullName() protoreflect.FullName { return fd.L1.Package } +func (fd *File) IsPlaceholder() bool { return false } func (fd *File) Options() protoreflect.ProtoMessage { if f := fd.lazyInit().Options; f != nil { return f() @@ -202,6 +206,9 @@ func (ed *Enum) lazyInit() *EnumL2 { ed.L0.ParentFile.lazyInit() // implicitly initializes L2 return ed.L2 } +func (ed *Enum) IsClosed() bool { + return !ed.L1.EditionFeatures.IsOpenEnum +} func (ed *EnumValue) Options() protoreflect.ProtoMessage { if f := ed.L1.Options; f != nil { @@ -251,10 +258,6 @@ type ( StringName stringName IsProto3Optional bool // promoted from google.protobuf.FieldDescriptorProto IsWeak bool // promoted from google.protobuf.FieldOptions - HasPacked bool // promoted from google.protobuf.FieldOptions - IsPacked bool // promoted from google.protobuf.FieldOptions - HasEnforceUTF8 bool // promoted from google.protobuf.FieldOptions - EnforceUTF8 bool // promoted from google.protobuf.FieldOptions Default defaultValue ContainingOneof protoreflect.OneofDescriptor // must be consistent with Message.Oneofs.Fields Enum protoreflect.EnumDescriptor @@ -331,8 +334,7 @@ func (fd *Field) HasPresence() bool { if fd.L1.Cardinality == protoreflect.Repeated { return false } - explicitFieldPresence := fd.Syntax() == protoreflect.Editions && fd.L1.EditionFeatures.IsFieldPresence - return fd.Syntax() == protoreflect.Proto2 || explicitFieldPresence || fd.L1.Message != nil || fd.L1.ContainingOneof != nil + return fd.IsExtension() || fd.L1.EditionFeatures.IsFieldPresence || fd.L1.Message != nil || fd.L1.ContainingOneof != nil } func (fd *Field) HasOptionalKeyword() bool { return (fd.L0.ParentFile.L1.Syntax == protoreflect.Proto2 && fd.L1.Cardinality == protoreflect.Optional && fd.L1.ContainingOneof == nil) || fd.L1.IsProto3Optional @@ -345,14 +347,7 @@ func (fd *Field) IsPacked() bool { case protoreflect.StringKind, protoreflect.BytesKind, protoreflect.MessageKind, protoreflect.GroupKind: return false } - if fd.L0.ParentFile.L1.Syntax == protoreflect.Editions { - return fd.L1.EditionFeatures.IsPacked - } - if fd.L0.ParentFile.L1.Syntax == protoreflect.Proto3 { - // proto3 repeated fields are packed by default. - return !fd.L1.HasPacked || fd.L1.IsPacked - } - return fd.L1.IsPacked + return fd.L1.EditionFeatures.IsPacked } func (fd *Field) IsExtension() bool { return false } func (fd *Field) IsWeak() bool { return fd.L1.IsWeak } @@ -399,13 +394,7 @@ func (fd *Field) ProtoType(protoreflect.FieldDescriptor) {} // WARNING: This method is exempt from the compatibility promise and may be // removed in the future without warning. func (fd *Field) EnforceUTF8() bool { - if fd.L0.ParentFile.L1.Syntax == protoreflect.Editions { - return fd.L1.EditionFeatures.IsUTF8Validated - } - if fd.L1.HasEnforceUTF8 { - return fd.L1.EnforceUTF8 - } - return fd.L0.ParentFile.L1.Syntax == protoreflect.Proto3 + return fd.L1.EditionFeatures.IsUTF8Validated } func (od *Oneof) IsSynthetic() bool { @@ -438,7 +427,6 @@ type ( Options func() protoreflect.ProtoMessage StringName stringName IsProto3Optional bool // promoted from google.protobuf.FieldDescriptorProto - IsPacked bool // promoted from google.protobuf.FieldOptions Default defaultValue Enum protoreflect.EnumDescriptor Message protoreflect.MessageDescriptor @@ -461,7 +449,16 @@ func (xd *Extension) HasPresence() bool { return xd.L1.Cardi func (xd *Extension) HasOptionalKeyword() bool { return (xd.L0.ParentFile.L1.Syntax == protoreflect.Proto2 && xd.L1.Cardinality == protoreflect.Optional) || xd.lazyInit().IsProto3Optional } -func (xd *Extension) IsPacked() bool { return xd.lazyInit().IsPacked } +func (xd *Extension) IsPacked() bool { + if xd.L1.Cardinality != protoreflect.Repeated { + return false + } + switch xd.L1.Kind { + case protoreflect.StringKind, protoreflect.BytesKind, protoreflect.MessageKind, protoreflect.GroupKind: + return false + } + return xd.L1.EditionFeatures.IsPacked +} func (xd *Extension) IsExtension() bool { return true } func (xd *Extension) IsWeak() bool { return false } func (xd *Extension) IsList() bool { return xd.Cardinality() == protoreflect.Repeated } @@ -542,8 +539,9 @@ func (md *Method) ProtoInternal(pragma.DoNotImplement) {} // Surrogate files are can be used to create standalone descriptors // where the syntax is only information derived from the parent file. var ( - SurrogateProto2 = &File{L1: FileL1{Syntax: protoreflect.Proto2}, L2: &FileL2{}} - SurrogateProto3 = &File{L1: FileL1{Syntax: protoreflect.Proto3}, L2: &FileL2{}} + SurrogateProto2 = &File{L1: FileL1{Syntax: protoreflect.Proto2}, L2: &FileL2{}} + SurrogateProto3 = &File{L1: FileL1{Syntax: protoreflect.Proto3}, L2: &FileL2{}} + SurrogateEdition2023 = &File{L1: FileL1{Syntax: protoreflect.Editions, Edition: Edition2023}, L2: &FileL2{}} ) type ( @@ -585,6 +583,34 @@ func (s *stringName) InitJSON(name string) { s.nameJSON = name } +// Returns true if this field is structured like the synthetic field of a proto2 +// group. This allows us to expand our treatment of delimited fields without +// breaking proto2 files that have been upgraded to editions. +func isGroupLike(fd protoreflect.FieldDescriptor) bool { + // Groups are always group types. + if fd.Kind() != protoreflect.GroupKind { + return false + } + + // Group fields are always the lowercase type name. + if strings.ToLower(string(fd.Message().Name())) != string(fd.Name()) { + return false + } + + // Groups could only be defined in the same file they're used. + if fd.Message().ParentFile() != fd.ParentFile() { + return false + } + + // Group messages are always defined in the same scope as the field. File + // level extensions will compare NULL == NULL here, which is why the file + // comparison above is necessary to ensure both come from the same file. + if fd.IsExtension() { + return fd.Parent() == fd.Message().Parent() + } + return fd.ContainingMessage() == fd.Message().Parent() +} + func (s *stringName) lazyInit(fd protoreflect.FieldDescriptor) *stringName { s.once.Do(func() { if fd.IsExtension() { @@ -605,7 +631,7 @@ func (s *stringName) lazyInit(fd protoreflect.FieldDescriptor) *stringName { // Format the text name. s.nameText = string(fd.Name()) - if fd.Kind() == protoreflect.GroupKind { + if isGroupLike(fd) { s.nameText = string(fd.Message().Name()) } } diff --git a/vendor/google.golang.org/protobuf/internal/filedesc/desc_init.go b/vendor/google.golang.org/protobuf/internal/filedesc/desc_init.go index 237e64fd23..3bc3b1cdf8 100644 --- a/vendor/google.golang.org/protobuf/internal/filedesc/desc_init.go +++ b/vendor/google.golang.org/protobuf/internal/filedesc/desc_init.go @@ -113,8 +113,10 @@ func (fd *File) unmarshalSeed(b []byte) { switch string(v) { case "proto2": fd.L1.Syntax = protoreflect.Proto2 + fd.L1.Edition = EditionProto2 case "proto3": fd.L1.Syntax = protoreflect.Proto3 + fd.L1.Edition = EditionProto3 case "editions": fd.L1.Syntax = protoreflect.Editions default: @@ -177,11 +179,10 @@ func (fd *File) unmarshalSeed(b []byte) { // If syntax is missing, it is assumed to be proto2. if fd.L1.Syntax == 0 { fd.L1.Syntax = protoreflect.Proto2 + fd.L1.Edition = EditionProto2 } - if fd.L1.Syntax == protoreflect.Editions { - fd.L1.EditionFeatures = getFeaturesFor(fd.L1.Edition) - } + fd.L1.EditionFeatures = getFeaturesFor(fd.L1.Edition) // Parse editions features from options if any if options != nil { @@ -267,6 +268,7 @@ func (ed *Enum) unmarshalSeed(b []byte, sb *strs.Builder, pf *File, pd protorefl ed.L0.ParentFile = pf ed.L0.Parent = pd ed.L0.Index = i + ed.L1.EditionFeatures = featuresFromParentDesc(ed.Parent()) var numValues int for b := b; len(b) > 0; { @@ -443,6 +445,7 @@ func (xd *Extension) unmarshalSeed(b []byte, sb *strs.Builder, pf *File, pd prot xd.L0.ParentFile = pf xd.L0.Parent = pd xd.L0.Index = i + xd.L1.EditionFeatures = featuresFromParentDesc(pd) for len(b) > 0 { num, typ, n := protowire.ConsumeTag(b) @@ -467,6 +470,38 @@ func (xd *Extension) unmarshalSeed(b []byte, sb *strs.Builder, pf *File, pd prot xd.L0.FullName = appendFullName(sb, pd.FullName(), v) case genid.FieldDescriptorProto_Extendee_field_number: xd.L1.Extendee = PlaceholderMessage(makeFullName(sb, v)) + case genid.FieldDescriptorProto_Options_field_number: + xd.unmarshalOptions(v) + } + default: + m := protowire.ConsumeFieldValue(num, typ, b) + b = b[m:] + } + } + + if xd.L1.Kind == protoreflect.MessageKind && xd.L1.EditionFeatures.IsDelimitedEncoded { + xd.L1.Kind = protoreflect.GroupKind + } +} + +func (xd *Extension) unmarshalOptions(b []byte) { + for len(b) > 0 { + num, typ, n := protowire.ConsumeTag(b) + b = b[n:] + switch typ { + case protowire.VarintType: + v, m := protowire.ConsumeVarint(b) + b = b[m:] + switch num { + case genid.FieldOptions_Packed_field_number: + xd.L1.EditionFeatures.IsPacked = protowire.DecodeBool(v) + } + case protowire.BytesType: + v, m := protowire.ConsumeBytes(b) + b = b[m:] + switch num { + case genid.FieldOptions_Features_field_number: + xd.L1.EditionFeatures = unmarshalFeatureSet(v, xd.L1.EditionFeatures) } default: m := protowire.ConsumeFieldValue(num, typ, b) diff --git a/vendor/google.golang.org/protobuf/internal/filedesc/desc_lazy.go b/vendor/google.golang.org/protobuf/internal/filedesc/desc_lazy.go index 482a61cc10..570181eb48 100644 --- a/vendor/google.golang.org/protobuf/internal/filedesc/desc_lazy.go +++ b/vendor/google.golang.org/protobuf/internal/filedesc/desc_lazy.go @@ -466,10 +466,10 @@ func (fd *Field) unmarshalFull(b []byte, sb *strs.Builder, pf *File, pd protoref b = b[m:] } } - if fd.Syntax() == protoreflect.Editions && fd.L1.Kind == protoreflect.MessageKind && fd.L1.EditionFeatures.IsDelimitedEncoded { + if fd.L1.Kind == protoreflect.MessageKind && fd.L1.EditionFeatures.IsDelimitedEncoded { fd.L1.Kind = protoreflect.GroupKind } - if fd.Syntax() == protoreflect.Editions && fd.L1.EditionFeatures.IsLegacyRequired { + if fd.L1.EditionFeatures.IsLegacyRequired { fd.L1.Cardinality = protoreflect.Required } if rawTypeName != nil { @@ -496,13 +496,11 @@ func (fd *Field) unmarshalOptions(b []byte) { b = b[m:] switch num { case genid.FieldOptions_Packed_field_number: - fd.L1.HasPacked = true - fd.L1.IsPacked = protowire.DecodeBool(v) + fd.L1.EditionFeatures.IsPacked = protowire.DecodeBool(v) case genid.FieldOptions_Weak_field_number: fd.L1.IsWeak = protowire.DecodeBool(v) case FieldOptions_EnforceUTF8: - fd.L1.HasEnforceUTF8 = true - fd.L1.EnforceUTF8 = protowire.DecodeBool(v) + fd.L1.EditionFeatures.IsUTF8Validated = protowire.DecodeBool(v) } case protowire.BytesType: v, m := protowire.ConsumeBytes(b) @@ -548,7 +546,6 @@ func (od *Oneof) unmarshalFull(b []byte, sb *strs.Builder, pf *File, pd protoref func (xd *Extension) unmarshalFull(b []byte, sb *strs.Builder) { var rawTypeName []byte var rawOptions []byte - xd.L1.EditionFeatures = featuresFromParentDesc(xd.L1.Extendee) xd.L2 = new(ExtensionL2) for len(b) > 0 { num, typ, n := protowire.ConsumeTag(b) @@ -572,7 +569,6 @@ func (xd *Extension) unmarshalFull(b []byte, sb *strs.Builder) { case genid.FieldDescriptorProto_TypeName_field_number: rawTypeName = v case genid.FieldDescriptorProto_Options_field_number: - xd.unmarshalOptions(v) rawOptions = appendOptions(rawOptions, v) } default: @@ -580,12 +576,6 @@ func (xd *Extension) unmarshalFull(b []byte, sb *strs.Builder) { b = b[m:] } } - if xd.Syntax() == protoreflect.Editions && xd.L1.Kind == protoreflect.MessageKind && xd.L1.EditionFeatures.IsDelimitedEncoded { - xd.L1.Kind = protoreflect.GroupKind - } - if xd.Syntax() == protoreflect.Editions && xd.L1.EditionFeatures.IsLegacyRequired { - xd.L1.Cardinality = protoreflect.Required - } if rawTypeName != nil { name := makeFullName(sb, rawTypeName) switch xd.L1.Kind { @@ -598,32 +588,6 @@ func (xd *Extension) unmarshalFull(b []byte, sb *strs.Builder) { xd.L2.Options = xd.L0.ParentFile.builder.optionsUnmarshaler(&descopts.Field, rawOptions) } -func (xd *Extension) unmarshalOptions(b []byte) { - for len(b) > 0 { - num, typ, n := protowire.ConsumeTag(b) - b = b[n:] - switch typ { - case protowire.VarintType: - v, m := protowire.ConsumeVarint(b) - b = b[m:] - switch num { - case genid.FieldOptions_Packed_field_number: - xd.L2.IsPacked = protowire.DecodeBool(v) - } - case protowire.BytesType: - v, m := protowire.ConsumeBytes(b) - b = b[m:] - switch num { - case genid.FieldOptions_Features_field_number: - xd.L1.EditionFeatures = unmarshalFeatureSet(v, xd.L1.EditionFeatures) - } - default: - m := protowire.ConsumeFieldValue(num, typ, b) - b = b[m:] - } - } -} - func (sd *Service) unmarshalFull(b []byte, sb *strs.Builder) { var rawMethods [][]byte var rawOptions []byte diff --git a/vendor/google.golang.org/protobuf/internal/filedesc/editions.go b/vendor/google.golang.org/protobuf/internal/filedesc/editions.go index 0375a49d40..d1e16a26d5 100644 --- a/vendor/google.golang.org/protobuf/internal/filedesc/editions.go +++ b/vendor/google.golang.org/protobuf/internal/filedesc/editions.go @@ -14,9 +14,13 @@ import ( ) var defaultsCache = make(map[Edition]EditionFeatures) +var defaultsKeys = []Edition{} func init() { unmarshalEditionDefaults(editiondefaults.Defaults) + SurrogateProto2.L1.EditionFeatures = getFeaturesFor(EditionProto2) + SurrogateProto3.L1.EditionFeatures = getFeaturesFor(EditionProto3) + SurrogateEdition2023.L1.EditionFeatures = getFeaturesFor(Edition2023) } func unmarshalGoFeature(b []byte, parent EditionFeatures) EditionFeatures { @@ -110,6 +114,7 @@ func unmarshalEditionDefault(b []byte) { } } defaultsCache[ed] = fs + defaultsKeys = append(defaultsKeys, ed) } func unmarshalEditionDefaults(b []byte) { @@ -135,8 +140,15 @@ func unmarshalEditionDefaults(b []byte) { } func getFeaturesFor(ed Edition) EditionFeatures { - if def, ok := defaultsCache[ed]; ok { - return def + match := EditionUnknown + for _, key := range defaultsKeys { + if key > ed { + break + } + match = key + } + if match == EditionUnknown { + panic(fmt.Sprintf("unsupported edition: %v", ed)) } - panic(fmt.Sprintf("unsupported edition: %v", ed)) + return defaultsCache[match] } diff --git a/vendor/google.golang.org/protobuf/internal/filedesc/placeholder.go b/vendor/google.golang.org/protobuf/internal/filedesc/placeholder.go index 28240ebc5c..bfb3b84170 100644 --- a/vendor/google.golang.org/protobuf/internal/filedesc/placeholder.go +++ b/vendor/google.golang.org/protobuf/internal/filedesc/placeholder.go @@ -63,6 +63,7 @@ func (e PlaceholderEnum) Options() protoreflect.ProtoMessage { return des func (e PlaceholderEnum) Values() protoreflect.EnumValueDescriptors { return emptyEnumValues } func (e PlaceholderEnum) ReservedNames() protoreflect.Names { return emptyNames } func (e PlaceholderEnum) ReservedRanges() protoreflect.EnumRanges { return emptyEnumRanges } +func (e PlaceholderEnum) IsClosed() bool { return false } func (e PlaceholderEnum) ProtoType(protoreflect.EnumDescriptor) { return } func (e PlaceholderEnum) ProtoInternal(pragma.DoNotImplement) { return } diff --git a/vendor/google.golang.org/protobuf/internal/genid/go_features_gen.go b/vendor/google.golang.org/protobuf/internal/genid/go_features_gen.go index fd9015e8ee..9a652a2b42 100644 --- a/vendor/google.golang.org/protobuf/internal/genid/go_features_gen.go +++ b/vendor/google.golang.org/protobuf/internal/genid/go_features_gen.go @@ -10,7 +10,7 @@ import ( protoreflect "google.golang.org/protobuf/reflect/protoreflect" ) -const File_reflect_protodesc_proto_go_features_proto = "reflect/protodesc/proto/go_features.proto" +const File_google_protobuf_go_features_proto = "google/protobuf/go_features.proto" // Names for google.protobuf.GoFeatures. const ( diff --git a/vendor/google.golang.org/protobuf/internal/impl/codec_field.go b/vendor/google.golang.org/protobuf/internal/impl/codec_field.go index 3fadd241e1..78ee47e44b 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/codec_field.go +++ b/vendor/google.golang.org/protobuf/internal/impl/codec_field.go @@ -233,9 +233,15 @@ func sizeMessageInfo(p pointer, f *coderFieldInfo, opts marshalOptions) int { } func appendMessageInfo(b []byte, p pointer, f *coderFieldInfo, opts marshalOptions) ([]byte, error) { + calculatedSize := f.mi.sizePointer(p.Elem(), opts) b = protowire.AppendVarint(b, f.wiretag) - b = protowire.AppendVarint(b, uint64(f.mi.sizePointer(p.Elem(), opts))) - return f.mi.marshalAppendPointer(b, p.Elem(), opts) + b = protowire.AppendVarint(b, uint64(calculatedSize)) + before := len(b) + b, err := f.mi.marshalAppendPointer(b, p.Elem(), opts) + if measuredSize := len(b) - before; calculatedSize != measuredSize && err == nil { + return nil, errors.MismatchedSizeCalculation(calculatedSize, measuredSize) + } + return b, err } func consumeMessageInfo(b []byte, p pointer, wtyp protowire.Type, f *coderFieldInfo, opts unmarshalOptions) (out unmarshalOutput, err error) { @@ -262,14 +268,21 @@ func isInitMessageInfo(p pointer, f *coderFieldInfo) error { return f.mi.checkInitializedPointer(p.Elem()) } -func sizeMessage(m proto.Message, tagsize int, _ marshalOptions) int { - return protowire.SizeBytes(proto.Size(m)) + tagsize +func sizeMessage(m proto.Message, tagsize int, opts marshalOptions) int { + return protowire.SizeBytes(opts.Options().Size(m)) + tagsize } func appendMessage(b []byte, m proto.Message, wiretag uint64, opts marshalOptions) ([]byte, error) { + mopts := opts.Options() + calculatedSize := mopts.Size(m) b = protowire.AppendVarint(b, wiretag) - b = protowire.AppendVarint(b, uint64(proto.Size(m))) - return opts.Options().MarshalAppend(b, m) + b = protowire.AppendVarint(b, uint64(calculatedSize)) + before := len(b) + b, err := mopts.MarshalAppend(b, m) + if measuredSize := len(b) - before; calculatedSize != measuredSize && err == nil { + return nil, errors.MismatchedSizeCalculation(calculatedSize, measuredSize) + } + return b, err } func consumeMessage(b []byte, m proto.Message, wtyp protowire.Type, opts unmarshalOptions) (out unmarshalOutput, err error) { @@ -405,8 +418,8 @@ func consumeGroupType(b []byte, p pointer, wtyp protowire.Type, f *coderFieldInf return f.mi.unmarshalPointer(b, p.Elem(), f.num, opts) } -func sizeGroup(m proto.Message, tagsize int, _ marshalOptions) int { - return 2*tagsize + proto.Size(m) +func sizeGroup(m proto.Message, tagsize int, opts marshalOptions) int { + return 2*tagsize + opts.Options().Size(m) } func appendGroup(b []byte, m proto.Message, wiretag uint64, opts marshalOptions) ([]byte, error) { @@ -482,10 +495,14 @@ func appendMessageSliceInfo(b []byte, p pointer, f *coderFieldInfo, opts marshal b = protowire.AppendVarint(b, f.wiretag) siz := f.mi.sizePointer(v, opts) b = protowire.AppendVarint(b, uint64(siz)) + before := len(b) b, err = f.mi.marshalAppendPointer(b, v, opts) if err != nil { return b, err } + if measuredSize := len(b) - before; siz != measuredSize { + return nil, errors.MismatchedSizeCalculation(siz, measuredSize) + } } return b, nil } @@ -520,28 +537,34 @@ func isInitMessageSliceInfo(p pointer, f *coderFieldInfo) error { return nil } -func sizeMessageSlice(p pointer, goType reflect.Type, tagsize int, _ marshalOptions) int { +func sizeMessageSlice(p pointer, goType reflect.Type, tagsize int, opts marshalOptions) int { + mopts := opts.Options() s := p.PointerSlice() n := 0 for _, v := range s { m := asMessage(v.AsValueOf(goType.Elem())) - n += protowire.SizeBytes(proto.Size(m)) + tagsize + n += protowire.SizeBytes(mopts.Size(m)) + tagsize } return n } func appendMessageSlice(b []byte, p pointer, wiretag uint64, goType reflect.Type, opts marshalOptions) ([]byte, error) { + mopts := opts.Options() s := p.PointerSlice() var err error for _, v := range s { m := asMessage(v.AsValueOf(goType.Elem())) b = protowire.AppendVarint(b, wiretag) - siz := proto.Size(m) + siz := mopts.Size(m) b = protowire.AppendVarint(b, uint64(siz)) - b, err = opts.Options().MarshalAppend(b, m) + before := len(b) + b, err = mopts.MarshalAppend(b, m) if err != nil { return b, err } + if measuredSize := len(b) - before; siz != measuredSize { + return nil, errors.MismatchedSizeCalculation(siz, measuredSize) + } } return b, nil } @@ -582,11 +605,12 @@ func isInitMessageSlice(p pointer, goType reflect.Type) error { // Slices of messages func sizeMessageSliceValue(listv protoreflect.Value, tagsize int, opts marshalOptions) int { + mopts := opts.Options() list := listv.List() n := 0 for i, llen := 0, list.Len(); i < llen; i++ { m := list.Get(i).Message().Interface() - n += protowire.SizeBytes(proto.Size(m)) + tagsize + n += protowire.SizeBytes(mopts.Size(m)) + tagsize } return n } @@ -597,13 +621,17 @@ func appendMessageSliceValue(b []byte, listv protoreflect.Value, wiretag uint64, for i, llen := 0, list.Len(); i < llen; i++ { m := list.Get(i).Message().Interface() b = protowire.AppendVarint(b, wiretag) - siz := proto.Size(m) + siz := mopts.Size(m) b = protowire.AppendVarint(b, uint64(siz)) + before := len(b) var err error b, err = mopts.MarshalAppend(b, m) if err != nil { return b, err } + if measuredSize := len(b) - before; siz != measuredSize { + return nil, errors.MismatchedSizeCalculation(siz, measuredSize) + } } return b, nil } @@ -651,11 +679,12 @@ var coderMessageSliceValue = valueCoderFuncs{ } func sizeGroupSliceValue(listv protoreflect.Value, tagsize int, opts marshalOptions) int { + mopts := opts.Options() list := listv.List() n := 0 for i, llen := 0, list.Len(); i < llen; i++ { m := list.Get(i).Message().Interface() - n += 2*tagsize + proto.Size(m) + n += 2*tagsize + mopts.Size(m) } return n } @@ -738,12 +767,13 @@ func makeGroupSliceFieldCoder(fd protoreflect.FieldDescriptor, ft reflect.Type) } } -func sizeGroupSlice(p pointer, messageType reflect.Type, tagsize int, _ marshalOptions) int { +func sizeGroupSlice(p pointer, messageType reflect.Type, tagsize int, opts marshalOptions) int { + mopts := opts.Options() s := p.PointerSlice() n := 0 for _, v := range s { m := asMessage(v.AsValueOf(messageType.Elem())) - n += 2*tagsize + proto.Size(m) + n += 2*tagsize + mopts.Size(m) } return n } diff --git a/vendor/google.golang.org/protobuf/internal/impl/codec_map.go b/vendor/google.golang.org/protobuf/internal/impl/codec_map.go index 111b9d16f9..fb35f0bae9 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/codec_map.go +++ b/vendor/google.golang.org/protobuf/internal/impl/codec_map.go @@ -9,6 +9,7 @@ import ( "sort" "google.golang.org/protobuf/encoding/protowire" + "google.golang.org/protobuf/internal/errors" "google.golang.org/protobuf/internal/genid" "google.golang.org/protobuf/reflect/protoreflect" ) @@ -240,11 +241,16 @@ func appendMapItem(b []byte, keyrv, valrv reflect.Value, mapi *mapInfo, f *coder size += mapi.keyFuncs.size(key.Value(), mapKeyTagSize, opts) size += mapi.valFuncs.size(val, mapValTagSize, opts) b = protowire.AppendVarint(b, uint64(size)) + before := len(b) b, err := mapi.keyFuncs.marshal(b, key.Value(), mapi.keyWiretag, opts) if err != nil { return nil, err } - return mapi.valFuncs.marshal(b, val, mapi.valWiretag, opts) + b, err = mapi.valFuncs.marshal(b, val, mapi.valWiretag, opts) + if measuredSize := len(b) - before; size != measuredSize && err == nil { + return nil, errors.MismatchedSizeCalculation(size, measuredSize) + } + return b, err } else { key := mapi.conv.keyConv.PBValueOf(keyrv).MapKey() val := pointerOfValue(valrv) @@ -259,7 +265,12 @@ func appendMapItem(b []byte, keyrv, valrv reflect.Value, mapi *mapInfo, f *coder } b = protowire.AppendVarint(b, mapi.valWiretag) b = protowire.AppendVarint(b, uint64(valSize)) - return f.mi.marshalAppendPointer(b, val, opts) + before := len(b) + b, err = f.mi.marshalAppendPointer(b, val, opts) + if measuredSize := len(b) - before; valSize != measuredSize && err == nil { + return nil, errors.MismatchedSizeCalculation(valSize, measuredSize) + } + return b, err } } diff --git a/vendor/google.golang.org/protobuf/internal/impl/legacy_enum.go b/vendor/google.golang.org/protobuf/internal/impl/legacy_enum.go index c2a803bb2f..c1c33d0057 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/legacy_enum.go +++ b/vendor/google.golang.org/protobuf/internal/impl/legacy_enum.go @@ -167,6 +167,7 @@ func aberrantLoadEnumDesc(t reflect.Type) protoreflect.EnumDescriptor { ed := &filedesc.Enum{L2: new(filedesc.EnumL2)} ed.L0.FullName = AberrantDeriveFullName(t) // e.g., github_com.user.repo.MyEnum ed.L0.ParentFile = filedesc.SurrogateProto3 + ed.L1.EditionFeatures = ed.L0.ParentFile.L1.EditionFeatures ed.L2.Values.List = append(ed.L2.Values.List, filedesc.EnumValue{}) // TODO: Use the presence of a UnmarshalJSON method to determine proto2? diff --git a/vendor/google.golang.org/protobuf/internal/impl/legacy_extension.go b/vendor/google.golang.org/protobuf/internal/impl/legacy_extension.go index 87b30d0504..6e8677ee63 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/legacy_extension.go +++ b/vendor/google.golang.org/protobuf/internal/impl/legacy_extension.go @@ -118,7 +118,7 @@ func (xi *ExtensionInfo) initFromLegacy() { xd.L1.Number = protoreflect.FieldNumber(xi.Field) xd.L1.Cardinality = fd.L1.Cardinality xd.L1.Kind = fd.L1.Kind - xd.L2.IsPacked = fd.L1.IsPacked + xd.L1.EditionFeatures = fd.L1.EditionFeatures xd.L2.Default = fd.L1.Default xd.L1.Extendee = Export{}.MessageDescriptorOf(xi.ExtendedType) xd.L2.Enum = ed diff --git a/vendor/google.golang.org/protobuf/internal/impl/legacy_file.go b/vendor/google.golang.org/protobuf/internal/impl/legacy_file.go index 9ab091086c..b649f1124b 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/legacy_file.go +++ b/vendor/google.golang.org/protobuf/internal/impl/legacy_file.go @@ -7,7 +7,7 @@ package impl import ( "bytes" "compress/gzip" - "io/ioutil" + "io" "sync" "google.golang.org/protobuf/internal/filedesc" @@ -51,7 +51,7 @@ func legacyLoadFileDesc(b []byte) protoreflect.FileDescriptor { if err != nil { panic(err) } - b2, err := ioutil.ReadAll(zr) + b2, err := io.ReadAll(zr) if err != nil { panic(err) } diff --git a/vendor/google.golang.org/protobuf/internal/impl/legacy_message.go b/vendor/google.golang.org/protobuf/internal/impl/legacy_message.go index 2ab2c62978..950e9a1fe7 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/legacy_message.go +++ b/vendor/google.golang.org/protobuf/internal/impl/legacy_message.go @@ -204,6 +204,7 @@ func aberrantLoadMessageDescReentrant(t reflect.Type, name protoreflect.FullName } } + md.L1.EditionFeatures = md.L0.ParentFile.L1.EditionFeatures // Obtain a list of oneof wrapper types. var oneofWrappers []reflect.Type methods := make([]reflect.Method, 0, 2) @@ -250,6 +251,7 @@ func aberrantLoadMessageDescReentrant(t reflect.Type, name protoreflect.FullName od := &md.L2.Oneofs.List[n] od.L0.FullName = md.FullName().Append(protoreflect.Name(tag)) od.L0.ParentFile = md.L0.ParentFile + od.L1.EditionFeatures = md.L1.EditionFeatures od.L0.Parent = md od.L0.Index = n @@ -260,6 +262,7 @@ func aberrantLoadMessageDescReentrant(t reflect.Type, name protoreflect.FullName aberrantAppendField(md, f.Type, tag, "", "") fd := &md.L2.Fields.List[len(md.L2.Fields.List)-1] fd.L1.ContainingOneof = od + fd.L1.EditionFeatures = od.L1.EditionFeatures od.L1.Fields.List = append(od.L1.Fields.List, fd) } } @@ -307,14 +310,14 @@ func aberrantAppendField(md *filedesc.Message, goType reflect.Type, tag, tagKey, fd.L0.Parent = md fd.L0.Index = n - if fd.L1.IsWeak || fd.L1.HasPacked { + if fd.L1.IsWeak || fd.L1.EditionFeatures.IsPacked { fd.L1.Options = func() protoreflect.ProtoMessage { opts := descopts.Field.ProtoReflect().New() if fd.L1.IsWeak { opts.Set(opts.Descriptor().Fields().ByName("weak"), protoreflect.ValueOfBool(true)) } - if fd.L1.HasPacked { - opts.Set(opts.Descriptor().Fields().ByName("packed"), protoreflect.ValueOfBool(fd.L1.IsPacked)) + if fd.L1.EditionFeatures.IsPacked { + opts.Set(opts.Descriptor().Fields().ByName("packed"), protoreflect.ValueOfBool(fd.L1.EditionFeatures.IsPacked)) } return opts.Interface() } @@ -344,6 +347,7 @@ func aberrantAppendField(md *filedesc.Message, goType reflect.Type, tag, tagKey, md2.L0.ParentFile = md.L0.ParentFile md2.L0.Parent = md md2.L0.Index = n + md2.L1.EditionFeatures = md.L1.EditionFeatures md2.L1.IsMapEntry = true md2.L2.Options = func() protoreflect.ProtoMessage { diff --git a/vendor/google.golang.org/protobuf/internal/impl/message_reflect.go b/vendor/google.golang.org/protobuf/internal/impl/message_reflect.go index d9ea010bef..a6f0dbdade 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/message_reflect.go +++ b/vendor/google.golang.org/protobuf/internal/impl/message_reflect.go @@ -247,11 +247,10 @@ func (m *extensionMap) Range(f func(protoreflect.FieldDescriptor, protoreflect.V } } } -func (m *extensionMap) Has(xt protoreflect.ExtensionType) (ok bool) { +func (m *extensionMap) Has(xd protoreflect.ExtensionTypeDescriptor) (ok bool) { if m == nil { return false } - xd := xt.TypeDescriptor() x, ok := (*m)[int32(xd.Number())] if !ok { return false @@ -261,25 +260,22 @@ func (m *extensionMap) Has(xt protoreflect.ExtensionType) (ok bool) { return x.Value().List().Len() > 0 case xd.IsMap(): return x.Value().Map().Len() > 0 - case xd.Message() != nil: - return x.Value().Message().IsValid() } return true } -func (m *extensionMap) Clear(xt protoreflect.ExtensionType) { - delete(*m, int32(xt.TypeDescriptor().Number())) +func (m *extensionMap) Clear(xd protoreflect.ExtensionTypeDescriptor) { + delete(*m, int32(xd.Number())) } -func (m *extensionMap) Get(xt protoreflect.ExtensionType) protoreflect.Value { - xd := xt.TypeDescriptor() +func (m *extensionMap) Get(xd protoreflect.ExtensionTypeDescriptor) protoreflect.Value { if m != nil { if x, ok := (*m)[int32(xd.Number())]; ok { return x.Value() } } - return xt.Zero() + return xd.Type().Zero() } -func (m *extensionMap) Set(xt protoreflect.ExtensionType, v protoreflect.Value) { - xd := xt.TypeDescriptor() +func (m *extensionMap) Set(xd protoreflect.ExtensionTypeDescriptor, v protoreflect.Value) { + xt := xd.Type() isValid := true switch { case !xt.IsValidValue(v): @@ -292,7 +288,7 @@ func (m *extensionMap) Set(xt protoreflect.ExtensionType, v protoreflect.Value) isValid = v.Message().IsValid() } if !isValid { - panic(fmt.Sprintf("%v: assigning invalid value", xt.TypeDescriptor().FullName())) + panic(fmt.Sprintf("%v: assigning invalid value", xd.FullName())) } if *m == nil { @@ -302,16 +298,15 @@ func (m *extensionMap) Set(xt protoreflect.ExtensionType, v protoreflect.Value) x.Set(xt, v) (*m)[int32(xd.Number())] = x } -func (m *extensionMap) Mutable(xt protoreflect.ExtensionType) protoreflect.Value { - xd := xt.TypeDescriptor() +func (m *extensionMap) Mutable(xd protoreflect.ExtensionTypeDescriptor) protoreflect.Value { if xd.Kind() != protoreflect.MessageKind && xd.Kind() != protoreflect.GroupKind && !xd.IsList() && !xd.IsMap() { panic("invalid Mutable on field with non-composite type") } if x, ok := (*m)[int32(xd.Number())]; ok { return x.Value() } - v := xt.New() - m.Set(xt, v) + v := xd.Type().New() + m.Set(xd, v) return v } @@ -428,7 +423,7 @@ func (m *messageIfaceWrapper) protoUnwrap() interface{} { // checkField verifies that the provided field descriptor is valid. // Exactly one of the returned values is populated. -func (mi *MessageInfo) checkField(fd protoreflect.FieldDescriptor) (*fieldInfo, protoreflect.ExtensionType) { +func (mi *MessageInfo) checkField(fd protoreflect.FieldDescriptor) (*fieldInfo, protoreflect.ExtensionTypeDescriptor) { var fi *fieldInfo if n := fd.Number(); 0 < n && int(n) < len(mi.denseFields) { fi = mi.denseFields[n] @@ -457,7 +452,7 @@ func (mi *MessageInfo) checkField(fd protoreflect.FieldDescriptor) (*fieldInfo, if !ok { panic(fmt.Sprintf("extension %v does not implement protoreflect.ExtensionTypeDescriptor", fd.FullName())) } - return nil, xtd.Type() + return nil, xtd } panic(fmt.Sprintf("field %v is invalid", fd.FullName())) } diff --git a/vendor/google.golang.org/protobuf/internal/impl/message_reflect_gen.go b/vendor/google.golang.org/protobuf/internal/impl/message_reflect_gen.go index 741d6e5b6b..29ba6bd355 100644 --- a/vendor/google.golang.org/protobuf/internal/impl/message_reflect_gen.go +++ b/vendor/google.golang.org/protobuf/internal/impl/message_reflect_gen.go @@ -27,8 +27,9 @@ func (m *messageState) protoUnwrap() interface{} { return m.pointer().AsIfaceOf(m.messageInfo().GoReflectType.Elem()) } func (m *messageState) ProtoMethods() *protoiface.Methods { - m.messageInfo().init() - return &m.messageInfo().methods + mi := m.messageInfo() + mi.init() + return &mi.methods } // ProtoMessageInfo is a pseudo-internal API for allowing the v1 code @@ -41,8 +42,9 @@ func (m *messageState) ProtoMessageInfo() *MessageInfo { } func (m *messageState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - m.messageInfo().init() - for _, ri := range m.messageInfo().rangeInfos { + mi := m.messageInfo() + mi.init() + for _, ri := range mi.rangeInfos { switch ri := ri.(type) { case *fieldInfo: if ri.has(m.pointer()) { @@ -52,77 +54,86 @@ func (m *messageState) Range(f func(protoreflect.FieldDescriptor, protoreflect.V } case *oneofInfo: if n := ri.which(m.pointer()); n > 0 { - fi := m.messageInfo().fields[n] + fi := mi.fields[n] if !f(fi.fieldDesc, fi.get(m.pointer())) { return } } } } - m.messageInfo().extensionMap(m.pointer()).Range(f) + mi.extensionMap(m.pointer()).Range(f) } func (m *messageState) Has(fd protoreflect.FieldDescriptor) bool { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.has(m.pointer()) } else { - return m.messageInfo().extensionMap(m.pointer()).Has(xt) + return mi.extensionMap(m.pointer()).Has(xd) } } func (m *messageState) Clear(fd protoreflect.FieldDescriptor) { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { fi.clear(m.pointer()) } else { - m.messageInfo().extensionMap(m.pointer()).Clear(xt) + mi.extensionMap(m.pointer()).Clear(xd) } } func (m *messageState) Get(fd protoreflect.FieldDescriptor) protoreflect.Value { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.get(m.pointer()) } else { - return m.messageInfo().extensionMap(m.pointer()).Get(xt) + return mi.extensionMap(m.pointer()).Get(xd) } } func (m *messageState) Set(fd protoreflect.FieldDescriptor, v protoreflect.Value) { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { fi.set(m.pointer(), v) } else { - m.messageInfo().extensionMap(m.pointer()).Set(xt, v) + mi.extensionMap(m.pointer()).Set(xd, v) } } func (m *messageState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.mutable(m.pointer()) } else { - return m.messageInfo().extensionMap(m.pointer()).Mutable(xt) + return mi.extensionMap(m.pointer()).Mutable(xd) } } func (m *messageState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.newField() } else { - return xt.New() + return xd.Type().New() } } func (m *messageState) WhichOneof(od protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { - m.messageInfo().init() - if oi := m.messageInfo().oneofs[od.Name()]; oi != nil && oi.oneofDesc == od { + mi := m.messageInfo() + mi.init() + if oi := mi.oneofs[od.Name()]; oi != nil && oi.oneofDesc == od { return od.Fields().ByNumber(oi.which(m.pointer())) } panic("invalid oneof descriptor " + string(od.FullName()) + " for message " + string(m.Descriptor().FullName())) } func (m *messageState) GetUnknown() protoreflect.RawFields { - m.messageInfo().init() - return m.messageInfo().getUnknown(m.pointer()) + mi := m.messageInfo() + mi.init() + return mi.getUnknown(m.pointer()) } func (m *messageState) SetUnknown(b protoreflect.RawFields) { - m.messageInfo().init() - m.messageInfo().setUnknown(m.pointer(), b) + mi := m.messageInfo() + mi.init() + mi.setUnknown(m.pointer(), b) } func (m *messageState) IsValid() bool { return !m.pointer().IsNil() @@ -147,8 +158,9 @@ func (m *messageReflectWrapper) protoUnwrap() interface{} { return m.pointer().AsIfaceOf(m.messageInfo().GoReflectType.Elem()) } func (m *messageReflectWrapper) ProtoMethods() *protoiface.Methods { - m.messageInfo().init() - return &m.messageInfo().methods + mi := m.messageInfo() + mi.init() + return &mi.methods } // ProtoMessageInfo is a pseudo-internal API for allowing the v1 code @@ -161,8 +173,9 @@ func (m *messageReflectWrapper) ProtoMessageInfo() *MessageInfo { } func (m *messageReflectWrapper) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - m.messageInfo().init() - for _, ri := range m.messageInfo().rangeInfos { + mi := m.messageInfo() + mi.init() + for _, ri := range mi.rangeInfos { switch ri := ri.(type) { case *fieldInfo: if ri.has(m.pointer()) { @@ -172,77 +185,86 @@ func (m *messageReflectWrapper) Range(f func(protoreflect.FieldDescriptor, proto } case *oneofInfo: if n := ri.which(m.pointer()); n > 0 { - fi := m.messageInfo().fields[n] + fi := mi.fields[n] if !f(fi.fieldDesc, fi.get(m.pointer())) { return } } } } - m.messageInfo().extensionMap(m.pointer()).Range(f) + mi.extensionMap(m.pointer()).Range(f) } func (m *messageReflectWrapper) Has(fd protoreflect.FieldDescriptor) bool { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.has(m.pointer()) } else { - return m.messageInfo().extensionMap(m.pointer()).Has(xt) + return mi.extensionMap(m.pointer()).Has(xd) } } func (m *messageReflectWrapper) Clear(fd protoreflect.FieldDescriptor) { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { fi.clear(m.pointer()) } else { - m.messageInfo().extensionMap(m.pointer()).Clear(xt) + mi.extensionMap(m.pointer()).Clear(xd) } } func (m *messageReflectWrapper) Get(fd protoreflect.FieldDescriptor) protoreflect.Value { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.get(m.pointer()) } else { - return m.messageInfo().extensionMap(m.pointer()).Get(xt) + return mi.extensionMap(m.pointer()).Get(xd) } } func (m *messageReflectWrapper) Set(fd protoreflect.FieldDescriptor, v protoreflect.Value) { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { fi.set(m.pointer(), v) } else { - m.messageInfo().extensionMap(m.pointer()).Set(xt, v) + mi.extensionMap(m.pointer()).Set(xd, v) } } func (m *messageReflectWrapper) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.mutable(m.pointer()) } else { - return m.messageInfo().extensionMap(m.pointer()).Mutable(xt) + return mi.extensionMap(m.pointer()).Mutable(xd) } } func (m *messageReflectWrapper) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { - m.messageInfo().init() - if fi, xt := m.messageInfo().checkField(fd); fi != nil { + mi := m.messageInfo() + mi.init() + if fi, xd := mi.checkField(fd); fi != nil { return fi.newField() } else { - return xt.New() + return xd.Type().New() } } func (m *messageReflectWrapper) WhichOneof(od protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { - m.messageInfo().init() - if oi := m.messageInfo().oneofs[od.Name()]; oi != nil && oi.oneofDesc == od { + mi := m.messageInfo() + mi.init() + if oi := mi.oneofs[od.Name()]; oi != nil && oi.oneofDesc == od { return od.Fields().ByNumber(oi.which(m.pointer())) } panic("invalid oneof descriptor " + string(od.FullName()) + " for message " + string(m.Descriptor().FullName())) } func (m *messageReflectWrapper) GetUnknown() protoreflect.RawFields { - m.messageInfo().init() - return m.messageInfo().getUnknown(m.pointer()) + mi := m.messageInfo() + mi.init() + return mi.getUnknown(m.pointer()) } func (m *messageReflectWrapper) SetUnknown(b protoreflect.RawFields) { - m.messageInfo().init() - m.messageInfo().setUnknown(m.pointer(), b) + mi := m.messageInfo() + mi.init() + mi.setUnknown(m.pointer(), b) } func (m *messageReflectWrapper) IsValid() bool { return !m.pointer().IsNil() diff --git a/vendor/google.golang.org/protobuf/internal/version/version.go b/vendor/google.golang.org/protobuf/internal/version/version.go index a50fcfb49b..fc6bfc3960 100644 --- a/vendor/google.golang.org/protobuf/internal/version/version.go +++ b/vendor/google.golang.org/protobuf/internal/version/version.go @@ -51,7 +51,7 @@ import ( // 10. Send out the CL for review and submit it. const ( Major = 1 - Minor = 33 + Minor = 34 Patch = 0 PreRelease = "" ) diff --git a/vendor/google.golang.org/protobuf/proto/decode.go b/vendor/google.golang.org/protobuf/proto/decode.go index e5b03b5677..d75a6534c1 100644 --- a/vendor/google.golang.org/protobuf/proto/decode.go +++ b/vendor/google.golang.org/protobuf/proto/decode.go @@ -51,6 +51,8 @@ type UnmarshalOptions struct { // Unmarshal parses the wire-format message in b and places the result in m. // The provided message must be mutable (e.g., a non-nil pointer to a message). +// +// See the [UnmarshalOptions] type if you need more control. func Unmarshal(b []byte, m Message) error { _, err := UnmarshalOptions{RecursionLimit: protowire.DefaultRecursionLimit}.unmarshal(b, m.ProtoReflect()) return err diff --git a/vendor/google.golang.org/protobuf/proto/encode.go b/vendor/google.golang.org/protobuf/proto/encode.go index 4fed202f9f..1f847bcc35 100644 --- a/vendor/google.golang.org/protobuf/proto/encode.go +++ b/vendor/google.golang.org/protobuf/proto/encode.go @@ -5,12 +5,17 @@ package proto import ( + "errors" + "fmt" + "google.golang.org/protobuf/encoding/protowire" "google.golang.org/protobuf/internal/encoding/messageset" "google.golang.org/protobuf/internal/order" "google.golang.org/protobuf/internal/pragma" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/runtime/protoiface" + + protoerrors "google.golang.org/protobuf/internal/errors" ) // MarshalOptions configures the marshaler. @@ -70,7 +75,32 @@ type MarshalOptions struct { UseCachedSize bool } +// flags turns the specified MarshalOptions (user-facing) into +// protoiface.MarshalInputFlags (used internally by the marshaler). +// +// See impl.marshalOptions.Options for the inverse operation. +func (o MarshalOptions) flags() protoiface.MarshalInputFlags { + var flags protoiface.MarshalInputFlags + + // Note: o.AllowPartial is always forced to true by MarshalOptions.marshal, + // which is why it is not a part of MarshalInputFlags. + + if o.Deterministic { + flags |= protoiface.MarshalDeterministic + } + + if o.UseCachedSize { + flags |= protoiface.MarshalUseCachedSize + } + + return flags +} + // Marshal returns the wire-format encoding of m. +// +// This is the most common entry point for encoding a Protobuf message. +// +// See the [MarshalOptions] type if you need more control. func Marshal(m Message) ([]byte, error) { // Treat nil message interface as an empty message; nothing to output. if m == nil { @@ -116,6 +146,9 @@ func emptyBytesForMessage(m Message) []byte { // MarshalAppend appends the wire-format encoding of m to b, // returning the result. +// +// This is a less common entry point than [Marshal], which is only needed if you +// need to supply your own buffers for performance reasons. func (o MarshalOptions) MarshalAppend(b []byte, m Message) ([]byte, error) { // Treat nil message interface as an empty message; nothing to append. if m == nil { @@ -145,12 +178,7 @@ func (o MarshalOptions) marshal(b []byte, m protoreflect.Message) (out protoifac in := protoiface.MarshalInput{ Message: m, Buf: b, - } - if o.Deterministic { - in.Flags |= protoiface.MarshalDeterministic - } - if o.UseCachedSize { - in.Flags |= protoiface.MarshalUseCachedSize + Flags: o.flags(), } if methods.Size != nil { sout := methods.Size(protoiface.SizeInput{ @@ -168,6 +196,10 @@ func (o MarshalOptions) marshal(b []byte, m protoreflect.Message) (out protoifac out.Buf, err = o.marshalMessageSlow(b, m) } if err != nil { + var mismatch *protoerrors.SizeMismatchError + if errors.As(err, &mismatch) { + return out, fmt.Errorf("marshaling %s: %v", string(m.Descriptor().FullName()), err) + } return out, err } if allowPartial { diff --git a/vendor/google.golang.org/protobuf/proto/extension.go b/vendor/google.golang.org/protobuf/proto/extension.go index 17899a3a76..c9c8721a69 100644 --- a/vendor/google.golang.org/protobuf/proto/extension.go +++ b/vendor/google.golang.org/protobuf/proto/extension.go @@ -11,18 +11,21 @@ import ( // HasExtension reports whether an extension field is populated. // It returns false if m is invalid or if xt does not extend m. func HasExtension(m Message, xt protoreflect.ExtensionType) bool { - // Treat nil message interface as an empty message; no populated fields. - if m == nil { + // Treat nil message interface or descriptor as an empty message; no populated + // fields. + if m == nil || xt == nil { return false } // As a special-case, we reports invalid or mismatching descriptors // as always not being populated (since they aren't). - if xt == nil || m.ProtoReflect().Descriptor() != xt.TypeDescriptor().ContainingMessage() { + mr := m.ProtoReflect() + xd := xt.TypeDescriptor() + if mr.Descriptor() != xd.ContainingMessage() { return false } - return m.ProtoReflect().Has(xt.TypeDescriptor()) + return mr.Has(xd) } // ClearExtension clears an extension field such that subsequent diff --git a/vendor/google.golang.org/protobuf/proto/messageset.go b/vendor/google.golang.org/protobuf/proto/messageset.go index 312d5d45c6..575d14831f 100644 --- a/vendor/google.golang.org/protobuf/proto/messageset.go +++ b/vendor/google.golang.org/protobuf/proto/messageset.go @@ -47,11 +47,16 @@ func (o MarshalOptions) marshalMessageSet(b []byte, m protoreflect.Message) ([]b func (o MarshalOptions) marshalMessageSetField(b []byte, fd protoreflect.FieldDescriptor, value protoreflect.Value) ([]byte, error) { b = messageset.AppendFieldStart(b, fd.Number()) b = protowire.AppendTag(b, messageset.FieldMessage, protowire.BytesType) - b = protowire.AppendVarint(b, uint64(o.Size(value.Message().Interface()))) + calculatedSize := o.Size(value.Message().Interface()) + b = protowire.AppendVarint(b, uint64(calculatedSize)) + before := len(b) b, err := o.marshalMessage(b, value.Message()) if err != nil { return b, err } + if measuredSize := len(b) - before; calculatedSize != measuredSize { + return nil, errors.MismatchedSizeCalculation(calculatedSize, measuredSize) + } b = messageset.AppendFieldEnd(b) return b, nil } diff --git a/vendor/google.golang.org/protobuf/proto/size.go b/vendor/google.golang.org/protobuf/proto/size.go index f1692b49b6..052fb5ae31 100644 --- a/vendor/google.golang.org/protobuf/proto/size.go +++ b/vendor/google.golang.org/protobuf/proto/size.go @@ -34,6 +34,7 @@ func (o MarshalOptions) size(m protoreflect.Message) (size int) { if methods != nil && methods.Size != nil { out := methods.Size(protoiface.SizeInput{ Message: m, + Flags: o.flags(), }) return out.Size } @@ -42,6 +43,7 @@ func (o MarshalOptions) size(m protoreflect.Message) (size int) { // This case is mainly used for legacy types with a Marshal method. out, _ := methods.Marshal(protoiface.MarshalInput{ Message: m, + Flags: o.flags(), }) return len(out.Buf) } diff --git a/vendor/google.golang.org/protobuf/reflect/protodesc/desc.go b/vendor/google.golang.org/protobuf/reflect/protodesc/desc.go index baa0cc6218..8fbecb4f58 100644 --- a/vendor/google.golang.org/protobuf/reflect/protodesc/desc.go +++ b/vendor/google.golang.org/protobuf/reflect/protodesc/desc.go @@ -13,6 +13,7 @@ package protodesc import ( + "google.golang.org/protobuf/internal/editionssupport" "google.golang.org/protobuf/internal/errors" "google.golang.org/protobuf/internal/filedesc" "google.golang.org/protobuf/internal/pragma" @@ -91,15 +92,17 @@ func (o FileOptions) New(fd *descriptorpb.FileDescriptorProto, r Resolver) (prot switch fd.GetSyntax() { case "proto2", "": f.L1.Syntax = protoreflect.Proto2 + f.L1.Edition = filedesc.EditionProto2 case "proto3": f.L1.Syntax = protoreflect.Proto3 + f.L1.Edition = filedesc.EditionProto3 case "editions": f.L1.Syntax = protoreflect.Editions f.L1.Edition = fromEditionProto(fd.GetEdition()) default: return nil, errors.New("invalid syntax: %q", fd.GetSyntax()) } - if f.L1.Syntax == protoreflect.Editions && (fd.GetEdition() < SupportedEditionsMinimum || fd.GetEdition() > SupportedEditionsMaximum) { + if f.L1.Syntax == protoreflect.Editions && (fd.GetEdition() < editionssupport.Minimum || fd.GetEdition() > editionssupport.Maximum) { return nil, errors.New("use of edition %v not yet supported by the Go Protobuf runtime", fd.GetEdition()) } f.L1.Path = fd.GetName() @@ -114,9 +117,7 @@ func (o FileOptions) New(fd *descriptorpb.FileDescriptorProto, r Resolver) (prot opts = proto.Clone(opts).(*descriptorpb.FileOptions) f.L2.Options = func() protoreflect.ProtoMessage { return opts } } - if f.L1.Syntax == protoreflect.Editions { - initFileDescFromFeatureSet(f, fd.GetOptions().GetFeatures()) - } + initFileDescFromFeatureSet(f, fd.GetOptions().GetFeatures()) f.L2.Imports = make(filedesc.FileImports, len(fd.GetDependency())) for _, i := range fd.GetPublicDependency() { @@ -219,10 +220,10 @@ func (o FileOptions) New(fd *descriptorpb.FileDescriptorProto, r Resolver) (prot if err := validateEnumDeclarations(f.L1.Enums.List, fd.GetEnumType()); err != nil { return nil, err } - if err := validateMessageDeclarations(f.L1.Messages.List, fd.GetMessageType()); err != nil { + if err := validateMessageDeclarations(f, f.L1.Messages.List, fd.GetMessageType()); err != nil { return nil, err } - if err := validateExtensionDeclarations(f.L1.Extensions.List, fd.GetExtension()); err != nil { + if err := validateExtensionDeclarations(f, f.L1.Extensions.List, fd.GetExtension()); err != nil { return nil, err } diff --git a/vendor/google.golang.org/protobuf/reflect/protodesc/desc_init.go b/vendor/google.golang.org/protobuf/reflect/protodesc/desc_init.go index b3278163c5..8561755427 100644 --- a/vendor/google.golang.org/protobuf/reflect/protodesc/desc_init.go +++ b/vendor/google.golang.org/protobuf/reflect/protodesc/desc_init.go @@ -69,9 +69,7 @@ func (r descsByName) initMessagesDeclarations(mds []*descriptorpb.DescriptorProt if m.L0, err = r.makeBase(m, parent, md.GetName(), i, sb); err != nil { return nil, err } - if m.Base.L0.ParentFile.Syntax() == protoreflect.Editions { - m.L1.EditionFeatures = mergeEditionFeatures(parent, md.GetOptions().GetFeatures()) - } + m.L1.EditionFeatures = mergeEditionFeatures(parent, md.GetOptions().GetFeatures()) if opts := md.GetOptions(); opts != nil { opts = proto.Clone(opts).(*descriptorpb.MessageOptions) m.L2.Options = func() protoreflect.ProtoMessage { return opts } @@ -146,13 +144,15 @@ func (r descsByName) initFieldsFromDescriptorProto(fds []*descriptorpb.FieldDesc if f.L0, err = r.makeBase(f, parent, fd.GetName(), i, sb); err != nil { return nil, err } + f.L1.EditionFeatures = mergeEditionFeatures(parent, fd.GetOptions().GetFeatures()) f.L1.IsProto3Optional = fd.GetProto3Optional() if opts := fd.GetOptions(); opts != nil { opts = proto.Clone(opts).(*descriptorpb.FieldOptions) f.L1.Options = func() protoreflect.ProtoMessage { return opts } f.L1.IsWeak = opts.GetWeak() - f.L1.HasPacked = opts.Packed != nil - f.L1.IsPacked = opts.GetPacked() + if opts.Packed != nil { + f.L1.EditionFeatures.IsPacked = opts.GetPacked() + } } f.L1.Number = protoreflect.FieldNumber(fd.GetNumber()) f.L1.Cardinality = protoreflect.Cardinality(fd.GetLabel()) @@ -163,32 +163,12 @@ func (r descsByName) initFieldsFromDescriptorProto(fds []*descriptorpb.FieldDesc f.L1.StringName.InitJSON(fd.GetJsonName()) } - if f.Base.L0.ParentFile.Syntax() == protoreflect.Editions { - f.L1.EditionFeatures = mergeEditionFeatures(parent, fd.GetOptions().GetFeatures()) - - if f.L1.EditionFeatures.IsLegacyRequired { - f.L1.Cardinality = protoreflect.Required - } - // We reuse the existing field because the old option `[packed = - // true]` is mutually exclusive with the editions feature. - if canBePacked(fd) { - f.L1.HasPacked = true - f.L1.IsPacked = f.L1.EditionFeatures.IsPacked - } - - // We pretend this option is always explicitly set because the only - // use of HasEnforceUTF8 is to determine whether to use EnforceUTF8 - // or to return the appropriate default. - // When using editions we either parse the option or resolve the - // appropriate default here (instead of later when this option is - // requested from the descriptor). - // In proto2/proto3 syntax HasEnforceUTF8 might be false. - f.L1.HasEnforceUTF8 = true - f.L1.EnforceUTF8 = f.L1.EditionFeatures.IsUTF8Validated + if f.L1.EditionFeatures.IsLegacyRequired { + f.L1.Cardinality = protoreflect.Required + } - if f.L1.Kind == protoreflect.MessageKind && f.L1.EditionFeatures.IsDelimitedEncoded { - f.L1.Kind = protoreflect.GroupKind - } + if f.L1.Kind == protoreflect.MessageKind && f.L1.EditionFeatures.IsDelimitedEncoded { + f.L1.Kind = protoreflect.GroupKind } } return fs, nil @@ -201,12 +181,10 @@ func (r descsByName) initOneofsFromDescriptorProto(ods []*descriptorpb.OneofDesc if o.L0, err = r.makeBase(o, parent, od.GetName(), i, sb); err != nil { return nil, err } + o.L1.EditionFeatures = mergeEditionFeatures(parent, od.GetOptions().GetFeatures()) if opts := od.GetOptions(); opts != nil { opts = proto.Clone(opts).(*descriptorpb.OneofOptions) o.L1.Options = func() protoreflect.ProtoMessage { return opts } - if parent.Syntax() == protoreflect.Editions { - o.L1.EditionFeatures = mergeEditionFeatures(parent, opts.GetFeatures()) - } } } return os, nil @@ -220,10 +198,13 @@ func (r descsByName) initExtensionDeclarations(xds []*descriptorpb.FieldDescript if x.L0, err = r.makeBase(x, parent, xd.GetName(), i, sb); err != nil { return nil, err } + x.L1.EditionFeatures = mergeEditionFeatures(parent, xd.GetOptions().GetFeatures()) if opts := xd.GetOptions(); opts != nil { opts = proto.Clone(opts).(*descriptorpb.FieldOptions) x.L2.Options = func() protoreflect.ProtoMessage { return opts } - x.L2.IsPacked = opts.GetPacked() + if opts.Packed != nil { + x.L1.EditionFeatures.IsPacked = opts.GetPacked() + } } x.L1.Number = protoreflect.FieldNumber(xd.GetNumber()) x.L1.Cardinality = protoreflect.Cardinality(xd.GetLabel()) diff --git a/vendor/google.golang.org/protobuf/reflect/protodesc/desc_validate.go b/vendor/google.golang.org/protobuf/reflect/protodesc/desc_validate.go index e4dcaf876c..c629308675 100644 --- a/vendor/google.golang.org/protobuf/reflect/protodesc/desc_validate.go +++ b/vendor/google.golang.org/protobuf/reflect/protodesc/desc_validate.go @@ -45,11 +45,11 @@ func validateEnumDeclarations(es []filedesc.Enum, eds []*descriptorpb.EnumDescri if allowAlias && !foundAlias { return errors.New("enum %q allows aliases, but none were found", e.FullName()) } - if e.Syntax() == protoreflect.Proto3 { + if !e.IsClosed() { if v := e.Values().Get(0); v.Number() != 0 { - return errors.New("enum %q using proto3 semantics must have zero number for the first value", v.FullName()) + return errors.New("enum %q using open semantics must have zero number for the first value", v.FullName()) } - // Verify that value names in proto3 do not conflict if the + // Verify that value names in open enums do not conflict if the // case-insensitive prefix is removed. // See protoc v3.8.0: src/google/protobuf/descriptor.cc:4991-5055 names := map[string]protoreflect.EnumValueDescriptor{} @@ -58,7 +58,7 @@ func validateEnumDeclarations(es []filedesc.Enum, eds []*descriptorpb.EnumDescri v1 := e.Values().Get(i) s := strs.EnumValueName(strs.TrimEnumPrefix(string(v1.Name()), prefix)) if v2, ok := names[s]; ok && v1.Number() != v2.Number() { - return errors.New("enum %q using proto3 semantics has conflict: %q with %q", e.FullName(), v1.Name(), v2.Name()) + return errors.New("enum %q using open semantics has conflict: %q with %q", e.FullName(), v1.Name(), v2.Name()) } names[s] = v1 } @@ -80,7 +80,9 @@ func validateEnumDeclarations(es []filedesc.Enum, eds []*descriptorpb.EnumDescri return nil } -func validateMessageDeclarations(ms []filedesc.Message, mds []*descriptorpb.DescriptorProto) error { +func validateMessageDeclarations(file *filedesc.File, ms []filedesc.Message, mds []*descriptorpb.DescriptorProto) error { + // There are a few limited exceptions only for proto3 + isProto3 := file.L1.Edition == fromEditionProto(descriptorpb.Edition_EDITION_PROTO3) for i, md := range mds { m := &ms[i] @@ -107,10 +109,10 @@ func validateMessageDeclarations(ms []filedesc.Message, mds []*descriptorpb.Desc if isMessageSet && !flags.ProtoLegacy { return errors.New("message %q is a MessageSet, which is a legacy proto1 feature that is no longer supported", m.FullName()) } - if isMessageSet && (m.Syntax() == protoreflect.Proto3 || m.Fields().Len() > 0 || m.ExtensionRanges().Len() == 0) { + if isMessageSet && (isProto3 || m.Fields().Len() > 0 || m.ExtensionRanges().Len() == 0) { return errors.New("message %q is an invalid proto1 MessageSet", m.FullName()) } - if m.Syntax() == protoreflect.Proto3 { + if isProto3 { if m.ExtensionRanges().Len() > 0 { return errors.New("message %q using proto3 semantics cannot have extension ranges", m.FullName()) } @@ -149,7 +151,7 @@ func validateMessageDeclarations(ms []filedesc.Message, mds []*descriptorpb.Desc return errors.New("message field %q may not have extendee: %q", f.FullName(), fd.GetExtendee()) } if f.L1.IsProto3Optional { - if f.Syntax() != protoreflect.Proto3 { + if !isProto3 { return errors.New("message field %q under proto3 optional semantics must be specified in the proto3 syntax", f.FullName()) } if f.Cardinality() != protoreflect.Optional { @@ -162,26 +164,29 @@ func validateMessageDeclarations(ms []filedesc.Message, mds []*descriptorpb.Desc if f.IsWeak() && !flags.ProtoLegacy { return errors.New("message field %q is a weak field, which is a legacy proto1 feature that is no longer supported", f.FullName()) } - if f.IsWeak() && (f.Syntax() != protoreflect.Proto2 || !isOptionalMessage(f) || f.ContainingOneof() != nil) { + if f.IsWeak() && (!f.HasPresence() || !isOptionalMessage(f) || f.ContainingOneof() != nil) { return errors.New("message field %q may only be weak for an optional message", f.FullName()) } if f.IsPacked() && !isPackable(f) { return errors.New("message field %q is not packable", f.FullName()) } - if err := checkValidGroup(f); err != nil { + if err := checkValidGroup(file, f); err != nil { return errors.New("message field %q is an invalid group: %v", f.FullName(), err) } if err := checkValidMap(f); err != nil { return errors.New("message field %q is an invalid map: %v", f.FullName(), err) } - if f.Syntax() == protoreflect.Proto3 { + if isProto3 { if f.Cardinality() == protoreflect.Required { return errors.New("message field %q using proto3 semantics cannot be required", f.FullName()) } - if f.Enum() != nil && !f.Enum().IsPlaceholder() && f.Enum().Syntax() != protoreflect.Proto3 { - return errors.New("message field %q using proto3 semantics may only depend on a proto3 enum", f.FullName()) + if f.Enum() != nil && !f.Enum().IsPlaceholder() && f.Enum().IsClosed() { + return errors.New("message field %q using proto3 semantics may only depend on open enums", f.FullName()) } } + if f.Cardinality() == protoreflect.Optional && !f.HasPresence() && f.Enum() != nil && !f.Enum().IsPlaceholder() && f.Enum().IsClosed() { + return errors.New("message field %q with implicit presence may only use open enums", f.FullName()) + } } seenSynthetic := false // synthetic oneofs for proto3 optional must come after real oneofs for j := range md.GetOneofDecl() { @@ -215,17 +220,17 @@ func validateMessageDeclarations(ms []filedesc.Message, mds []*descriptorpb.Desc if err := validateEnumDeclarations(m.L1.Enums.List, md.GetEnumType()); err != nil { return err } - if err := validateMessageDeclarations(m.L1.Messages.List, md.GetNestedType()); err != nil { + if err := validateMessageDeclarations(file, m.L1.Messages.List, md.GetNestedType()); err != nil { return err } - if err := validateExtensionDeclarations(m.L1.Extensions.List, md.GetExtension()); err != nil { + if err := validateExtensionDeclarations(file, m.L1.Extensions.List, md.GetExtension()); err != nil { return err } } return nil } -func validateExtensionDeclarations(xs []filedesc.Extension, xds []*descriptorpb.FieldDescriptorProto) error { +func validateExtensionDeclarations(f *filedesc.File, xs []filedesc.Extension, xds []*descriptorpb.FieldDescriptorProto) error { for i, xd := range xds { x := &xs[i] // NOTE: Avoid using the IsValid method since extensions to MessageSet @@ -267,13 +272,13 @@ func validateExtensionDeclarations(xs []filedesc.Extension, xds []*descriptorpb. if x.IsPacked() && !isPackable(x) { return errors.New("extension field %q is not packable", x.FullName()) } - if err := checkValidGroup(x); err != nil { + if err := checkValidGroup(f, x); err != nil { return errors.New("extension field %q is an invalid group: %v", x.FullName(), err) } if md := x.Message(); md != nil && md.IsMapEntry() { return errors.New("extension field %q cannot be a map entry", x.FullName()) } - if x.Syntax() == protoreflect.Proto3 { + if f.L1.Edition == fromEditionProto(descriptorpb.Edition_EDITION_PROTO3) { switch x.ContainingMessage().FullName() { case (*descriptorpb.FileOptions)(nil).ProtoReflect().Descriptor().FullName(): case (*descriptorpb.EnumOptions)(nil).ProtoReflect().Descriptor().FullName(): @@ -309,21 +314,25 @@ func isPackable(fd protoreflect.FieldDescriptor) bool { // checkValidGroup reports whether fd is a valid group according to the same // rules that protoc imposes. -func checkValidGroup(fd protoreflect.FieldDescriptor) error { +func checkValidGroup(f *filedesc.File, fd protoreflect.FieldDescriptor) error { md := fd.Message() switch { case fd.Kind() != protoreflect.GroupKind: return nil - case fd.Syntax() == protoreflect.Proto3: + case f.L1.Edition == fromEditionProto(descriptorpb.Edition_EDITION_PROTO3): return errors.New("invalid under proto3 semantics") case md == nil || md.IsPlaceholder(): return errors.New("message must be resolvable") - case fd.FullName().Parent() != md.FullName().Parent(): - return errors.New("message and field must be declared in the same scope") - case !unicode.IsUpper(rune(md.Name()[0])): - return errors.New("message name must start with an uppercase") - case fd.Name() != protoreflect.Name(strings.ToLower(string(md.Name()))): - return errors.New("field name must be lowercased form of the message name") + } + if f.L1.Edition < fromEditionProto(descriptorpb.Edition_EDITION_2023) { + switch { + case fd.FullName().Parent() != md.FullName().Parent(): + return errors.New("message and field must be declared in the same scope") + case !unicode.IsUpper(rune(md.Name()[0])): + return errors.New("message name must start with an uppercase") + case fd.Name() != protoreflect.Name(strings.ToLower(string(md.Name()))): + return errors.New("field name must be lowercased form of the message name") + } } return nil } diff --git a/vendor/google.golang.org/protobuf/reflect/protodesc/editions.go b/vendor/google.golang.org/protobuf/reflect/protodesc/editions.go index 2a6b29d179..f6a1fec6e4 100644 --- a/vendor/google.golang.org/protobuf/reflect/protodesc/editions.go +++ b/vendor/google.golang.org/protobuf/reflect/protodesc/editions.go @@ -17,11 +17,6 @@ import ( gofeaturespb "google.golang.org/protobuf/types/gofeaturespb" ) -const ( - SupportedEditionsMinimum = descriptorpb.Edition_EDITION_PROTO2 - SupportedEditionsMaximum = descriptorpb.Edition_EDITION_2023 -) - var defaults = &descriptorpb.FeatureSetDefaults{} var defaultsCacheMu sync.Mutex var defaultsCache = make(map[filedesc.Edition]*descriptorpb.FeatureSet) diff --git a/vendor/google.golang.org/protobuf/reflect/protodesc/proto.go b/vendor/google.golang.org/protobuf/reflect/protodesc/proto.go index 9d6e05420f..a5de8d4001 100644 --- a/vendor/google.golang.org/protobuf/reflect/protodesc/proto.go +++ b/vendor/google.golang.org/protobuf/reflect/protodesc/proto.go @@ -73,6 +73,16 @@ func ToFileDescriptorProto(file protoreflect.FileDescriptor) *descriptorpb.FileD if syntax := file.Syntax(); syntax != protoreflect.Proto2 && syntax.IsValid() { p.Syntax = proto.String(file.Syntax().String()) } + if file.Syntax() == protoreflect.Editions { + desc := file + if fileImportDesc, ok := file.(protoreflect.FileImport); ok { + desc = fileImportDesc.FileDescriptor + } + + if editionsInterface, ok := desc.(interface{ Edition() int32 }); ok { + p.Edition = descriptorpb.Edition(editionsInterface.Edition()).Enum() + } + } return p } @@ -153,6 +163,18 @@ func ToFieldDescriptorProto(field protoreflect.FieldDescriptor) *descriptorpb.Fi if field.Syntax() == protoreflect.Proto3 && field.HasOptionalKeyword() { p.Proto3Optional = proto.Bool(true) } + if field.Syntax() == protoreflect.Editions { + // Editions have no group keyword, this type is only set so that downstream users continue + // treating this as delimited encoding. + if p.GetType() == descriptorpb.FieldDescriptorProto_TYPE_GROUP { + p.Type = descriptorpb.FieldDescriptorProto_TYPE_MESSAGE.Enum() + } + // Editions have no required keyword, this label is only set so that downstream users continue + // treating it as required. + if p.GetLabel() == descriptorpb.FieldDescriptorProto_LABEL_REQUIRED { + p.Label = descriptorpb.FieldDescriptorProto_LABEL_OPTIONAL.Enum() + } + } if field.HasDefault() { def, err := defval.Marshal(field.Default(), field.DefaultEnumValue(), field.Kind(), defval.Descriptor) if err != nil && field.DefaultEnumValue() != nil { diff --git a/vendor/google.golang.org/protobuf/reflect/protoreflect/proto.go b/vendor/google.golang.org/protobuf/reflect/protoreflect/proto.go index 00b01fbd8c..c85bfaa5bb 100644 --- a/vendor/google.golang.org/protobuf/reflect/protoreflect/proto.go +++ b/vendor/google.golang.org/protobuf/reflect/protoreflect/proto.go @@ -161,7 +161,7 @@ const ( // IsValid reports whether the syntax is valid. func (s Syntax) IsValid() bool { switch s { - case Proto2, Proto3: + case Proto2, Proto3, Editions: return true default: return false diff --git a/vendor/google.golang.org/protobuf/reflect/protoreflect/type.go b/vendor/google.golang.org/protobuf/reflect/protoreflect/type.go index 60ff62b4c8..5b80afe520 100644 --- a/vendor/google.golang.org/protobuf/reflect/protoreflect/type.go +++ b/vendor/google.golang.org/protobuf/reflect/protoreflect/type.go @@ -544,6 +544,12 @@ type EnumDescriptor interface { // ReservedRanges is a list of reserved ranges of enum numbers. ReservedRanges() EnumRanges + // IsClosed reports whether this enum uses closed semantics. + // See https://protobuf.dev/programming-guides/enum/#definitions. + // Note: the Go protobuf implementation is not spec compliant and treats + // all enums as open enums. + IsClosed() bool + isEnumDescriptor } type isEnumDescriptor interface{ ProtoType(EnumDescriptor) } diff --git a/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go b/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go index 25de5ae008..9f046f9790 100644 --- a/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go +++ b/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go @@ -6,9 +6,9 @@ // https://developers.google.com/open-source/licenses/bsd // Code generated by protoc-gen-go. DO NOT EDIT. -// source: reflect/protodesc/proto/go_features.proto +// source: google/protobuf/go_features.proto -package proto +package gofeaturespb import ( protoreflect "google.golang.org/protobuf/reflect/protoreflect" @@ -30,7 +30,7 @@ type GoFeatures struct { func (x *GoFeatures) Reset() { *x = GoFeatures{} if protoimpl.UnsafeEnabled { - mi := &file_reflect_protodesc_proto_go_features_proto_msgTypes[0] + mi := &file_google_protobuf_go_features_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -43,7 +43,7 @@ func (x *GoFeatures) String() string { func (*GoFeatures) ProtoMessage() {} func (x *GoFeatures) ProtoReflect() protoreflect.Message { - mi := &file_reflect_protodesc_proto_go_features_proto_msgTypes[0] + mi := &file_google_protobuf_go_features_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -56,7 +56,7 @@ func (x *GoFeatures) ProtoReflect() protoreflect.Message { // Deprecated: Use GoFeatures.ProtoReflect.Descriptor instead. func (*GoFeatures) Descriptor() ([]byte, []int) { - return file_reflect_protodesc_proto_go_features_proto_rawDescGZIP(), []int{0} + return file_google_protobuf_go_features_proto_rawDescGZIP(), []int{0} } func (x *GoFeatures) GetLegacyUnmarshalJsonEnum() bool { @@ -66,69 +66,67 @@ func (x *GoFeatures) GetLegacyUnmarshalJsonEnum() bool { return false } -var file_reflect_protodesc_proto_go_features_proto_extTypes = []protoimpl.ExtensionInfo{ +var file_google_protobuf_go_features_proto_extTypes = []protoimpl.ExtensionInfo{ { ExtendedType: (*descriptorpb.FeatureSet)(nil), ExtensionType: (*GoFeatures)(nil), Field: 1002, - Name: "google.protobuf.go", + Name: "pb.go", Tag: "bytes,1002,opt,name=go", - Filename: "reflect/protodesc/proto/go_features.proto", + Filename: "google/protobuf/go_features.proto", }, } // Extension fields to descriptorpb.FeatureSet. var ( - // optional google.protobuf.GoFeatures go = 1002; - E_Go = &file_reflect_protodesc_proto_go_features_proto_extTypes[0] + // optional pb.GoFeatures go = 1002; + E_Go = &file_google_protobuf_go_features_proto_extTypes[0] ) -var File_reflect_protodesc_proto_go_features_proto protoreflect.FileDescriptor - -var file_reflect_protodesc_proto_go_features_proto_rawDesc = []byte{ - 0x0a, 0x29, 0x72, 0x65, 0x66, 0x6c, 0x65, 0x63, 0x74, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x64, - 0x65, 0x73, 0x63, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x5f, 0x66, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x1a, 0x20, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x65, - 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6a, - 0x0a, 0x0a, 0x47, 0x6f, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x5c, 0x0a, 0x1a, - 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5f, 0x75, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, - 0x5f, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x65, 0x6e, 0x75, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, - 0x42, 0x1f, 0x88, 0x01, 0x01, 0x98, 0x01, 0x06, 0xa2, 0x01, 0x09, 0x12, 0x04, 0x74, 0x72, 0x75, - 0x65, 0x18, 0xe6, 0x07, 0xa2, 0x01, 0x0a, 0x12, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x18, 0xe7, - 0x07, 0x52, 0x17, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, - 0x61, 0x6c, 0x4a, 0x73, 0x6f, 0x6e, 0x45, 0x6e, 0x75, 0x6d, 0x3a, 0x49, 0x0a, 0x02, 0x67, 0x6f, - 0x12, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x18, 0xea, 0x07, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x47, 0x6f, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x73, 0x52, 0x02, 0x67, 0x6f, 0x42, 0x34, 0x5a, 0x32, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2f, 0x72, 0x65, 0x66, 0x6c, 0x65, 0x63, 0x74, 0x2f, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x64, 0x65, 0x73, 0x63, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, +var File_google_protobuf_go_features_proto protoreflect.FileDescriptor + +var file_google_protobuf_go_features_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, + 0x66, 0x2f, 0x67, 0x6f, 0x5f, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x02, 0x70, 0x62, 0x1a, 0x20, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, + 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6a, 0x0a, 0x0a, 0x47, 0x6f, 0x46, + 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x5c, 0x0a, 0x1a, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5f, 0x75, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, 0x5f, 0x6a, 0x73, 0x6f, 0x6e, + 0x5f, 0x65, 0x6e, 0x75, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x42, 0x1f, 0x88, 0x01, 0x01, + 0x98, 0x01, 0x06, 0xa2, 0x01, 0x09, 0x12, 0x04, 0x74, 0x72, 0x75, 0x65, 0x18, 0xe6, 0x07, 0xa2, + 0x01, 0x0a, 0x12, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x18, 0xe7, 0x07, 0x52, 0x17, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, 0x4a, 0x73, 0x6f, + 0x6e, 0x45, 0x6e, 0x75, 0x6d, 0x3a, 0x3c, 0x0a, 0x02, 0x67, 0x6f, 0x12, 0x1b, 0x2e, 0x67, 0x6f, + 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x18, 0xea, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x0e, 0x2e, 0x70, 0x62, 0x2e, 0x47, 0x6f, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x52, + 0x02, 0x67, 0x6f, 0x42, 0x2f, 0x5a, 0x2d, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, + 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, + 0x66, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x67, 0x6f, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x73, 0x70, 0x62, } var ( - file_reflect_protodesc_proto_go_features_proto_rawDescOnce sync.Once - file_reflect_protodesc_proto_go_features_proto_rawDescData = file_reflect_protodesc_proto_go_features_proto_rawDesc + file_google_protobuf_go_features_proto_rawDescOnce sync.Once + file_google_protobuf_go_features_proto_rawDescData = file_google_protobuf_go_features_proto_rawDesc ) -func file_reflect_protodesc_proto_go_features_proto_rawDescGZIP() []byte { - file_reflect_protodesc_proto_go_features_proto_rawDescOnce.Do(func() { - file_reflect_protodesc_proto_go_features_proto_rawDescData = protoimpl.X.CompressGZIP(file_reflect_protodesc_proto_go_features_proto_rawDescData) +func file_google_protobuf_go_features_proto_rawDescGZIP() []byte { + file_google_protobuf_go_features_proto_rawDescOnce.Do(func() { + file_google_protobuf_go_features_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_protobuf_go_features_proto_rawDescData) }) - return file_reflect_protodesc_proto_go_features_proto_rawDescData + return file_google_protobuf_go_features_proto_rawDescData } -var file_reflect_protodesc_proto_go_features_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_reflect_protodesc_proto_go_features_proto_goTypes = []interface{}{ - (*GoFeatures)(nil), // 0: google.protobuf.GoFeatures +var file_google_protobuf_go_features_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_google_protobuf_go_features_proto_goTypes = []interface{}{ + (*GoFeatures)(nil), // 0: pb.GoFeatures (*descriptorpb.FeatureSet)(nil), // 1: google.protobuf.FeatureSet } -var file_reflect_protodesc_proto_go_features_proto_depIdxs = []int32{ - 1, // 0: google.protobuf.go:extendee -> google.protobuf.FeatureSet - 0, // 1: google.protobuf.go:type_name -> google.protobuf.GoFeatures +var file_google_protobuf_go_features_proto_depIdxs = []int32{ + 1, // 0: pb.go:extendee -> google.protobuf.FeatureSet + 0, // 1: pb.go:type_name -> pb.GoFeatures 2, // [2:2] is the sub-list for method output_type 2, // [2:2] is the sub-list for method input_type 1, // [1:2] is the sub-list for extension type_name @@ -136,13 +134,13 @@ var file_reflect_protodesc_proto_go_features_proto_depIdxs = []int32{ 0, // [0:0] is the sub-list for field type_name } -func init() { file_reflect_protodesc_proto_go_features_proto_init() } -func file_reflect_protodesc_proto_go_features_proto_init() { - if File_reflect_protodesc_proto_go_features_proto != nil { +func init() { file_google_protobuf_go_features_proto_init() } +func file_google_protobuf_go_features_proto_init() { + if File_google_protobuf_go_features_proto != nil { return } if !protoimpl.UnsafeEnabled { - file_reflect_protodesc_proto_go_features_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_google_protobuf_go_features_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GoFeatures); i { case 0: return &v.state @@ -159,19 +157,19 @@ func file_reflect_protodesc_proto_go_features_proto_init() { out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_reflect_protodesc_proto_go_features_proto_rawDesc, + RawDescriptor: file_google_protobuf_go_features_proto_rawDesc, NumEnums: 0, NumMessages: 1, NumExtensions: 1, NumServices: 0, }, - GoTypes: file_reflect_protodesc_proto_go_features_proto_goTypes, - DependencyIndexes: file_reflect_protodesc_proto_go_features_proto_depIdxs, - MessageInfos: file_reflect_protodesc_proto_go_features_proto_msgTypes, - ExtensionInfos: file_reflect_protodesc_proto_go_features_proto_extTypes, + GoTypes: file_google_protobuf_go_features_proto_goTypes, + DependencyIndexes: file_google_protobuf_go_features_proto_depIdxs, + MessageInfos: file_google_protobuf_go_features_proto_msgTypes, + ExtensionInfos: file_google_protobuf_go_features_proto_extTypes, }.Build() - File_reflect_protodesc_proto_go_features_proto = out.File - file_reflect_protodesc_proto_go_features_proto_rawDesc = nil - file_reflect_protodesc_proto_go_features_proto_goTypes = nil - file_reflect_protodesc_proto_go_features_proto_depIdxs = nil + File_google_protobuf_go_features_proto = out.File + file_google_protobuf_go_features_proto_rawDesc = nil + file_google_protobuf_go_features_proto_goTypes = nil + file_google_protobuf_go_features_proto_depIdxs = nil } diff --git a/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.proto b/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.proto deleted file mode 100644 index d246571296..0000000000 --- a/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.proto +++ /dev/null @@ -1,28 +0,0 @@ -// Protocol Buffers - Google's data interchange format -// Copyright 2023 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 or at -// https://developers.google.com/open-source/licenses/bsd - -syntax = "proto2"; - -package google.protobuf; - -import "google/protobuf/descriptor.proto"; - -option go_package = "google.golang.org/protobuf/types/gofeaturespb"; - -extend google.protobuf.FeatureSet { - optional GoFeatures go = 1002; -} - -message GoFeatures { - // Whether or not to generate the deprecated UnmarshalJSON method for enums. - optional bool legacy_unmarshal_json_enum = 1 [ - retention = RETENTION_RUNTIME, - targets = TARGET_TYPE_ENUM, - edition_defaults = { edition: EDITION_PROTO2, value: "true" }, - edition_defaults = { edition: EDITION_PROTO3, value: "false" } - ]; -} diff --git a/vendor/modules.txt b/vendor/modules.txt index 7200b13128..979d169f40 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -1,4 +1,4 @@ -# cloud.google.com/go v0.112.1 +# cloud.google.com/go v0.112.2 ## explicit; go 1.19 cloud.google.com/go/internal cloud.google.com/go/internal/optional @@ -456,7 +456,7 @@ golang.org/x/tools/internal/versions # gomodules.xyz/jsonpatch/v2 v2.4.0 ## explicit; go 1.20 gomodules.xyz/jsonpatch/v2 -# google.golang.org/api v0.176.1 +# google.golang.org/api v0.177.0 ## explicit; go 1.19 google.golang.org/api/container/v1beta1 google.golang.org/api/googleapi @@ -485,7 +485,7 @@ google.golang.org/genproto/googleapis/type/expr google.golang.org/genproto/googleapis/api google.golang.org/genproto/googleapis/api/annotations google.golang.org/genproto/googleapis/api/httpbody -# google.golang.org/genproto/googleapis/rpc v0.0.0-20240415180920-8c6c420018be +# google.golang.org/genproto/googleapis/rpc v0.0.0-20240429193739-8cf5692501f6 ## explicit; go 1.19 google.golang.org/genproto/googleapis/rpc/code google.golang.org/genproto/googleapis/rpc/errdetails @@ -558,7 +558,7 @@ google.golang.org/grpc/serviceconfig google.golang.org/grpc/stats google.golang.org/grpc/status google.golang.org/grpc/tap -# google.golang.org/protobuf v1.33.0 +# google.golang.org/protobuf v1.34.0 ## explicit; go 1.17 google.golang.org/protobuf/encoding/protodelim google.golang.org/protobuf/encoding/protojson @@ -568,6 +568,7 @@ google.golang.org/protobuf/internal/descfmt google.golang.org/protobuf/internal/descopts google.golang.org/protobuf/internal/detrand google.golang.org/protobuf/internal/editiondefaults +google.golang.org/protobuf/internal/editionssupport google.golang.org/protobuf/internal/encoding/defval google.golang.org/protobuf/internal/encoding/json google.golang.org/protobuf/internal/encoding/messageset