1// Copyright 2021 Google LLC.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5// Code generated file. DO NOT EDIT.
6
7// Package memcache provides access to the Cloud Memorystore for Memcached API.
8//
9// For product documentation, see: https://cloud.google.com/memorystore/
10//
11// Creating a client
12//
13// Usage example:
14//
15//   import "google.golang.org/api/memcache/v1beta2"
16//   ...
17//   ctx := context.Background()
18//   memcacheService, err := memcache.NewService(ctx)
19//
20// In this example, Google Application Default Credentials are used for authentication.
21//
22// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
23//
24// Other authentication options
25//
26// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
27//
28//   memcacheService, err := memcache.NewService(ctx, option.WithAPIKey("AIza..."))
29//
30// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
31//
32//   config := &oauth2.Config{...}
33//   // ...
34//   token, err := config.Exchange(ctx, ...)
35//   memcacheService, err := memcache.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
36//
37// See https://godoc.org/google.golang.org/api/option/ for details on options.
38package memcache // import "google.golang.org/api/memcache/v1beta2"
39
40import (
41	"bytes"
42	"context"
43	"encoding/json"
44	"errors"
45	"fmt"
46	"io"
47	"net/http"
48	"net/url"
49	"strconv"
50	"strings"
51
52	googleapi "google.golang.org/api/googleapi"
53	gensupport "google.golang.org/api/internal/gensupport"
54	option "google.golang.org/api/option"
55	internaloption "google.golang.org/api/option/internaloption"
56	htransport "google.golang.org/api/transport/http"
57)
58
59// Always reference these packages, just in case the auto-generated code
60// below doesn't.
61var _ = bytes.NewBuffer
62var _ = strconv.Itoa
63var _ = fmt.Sprintf
64var _ = json.NewDecoder
65var _ = io.Copy
66var _ = url.Parse
67var _ = gensupport.MarshalJSON
68var _ = googleapi.Version
69var _ = errors.New
70var _ = strings.Replace
71var _ = context.Canceled
72var _ = internaloption.WithDefaultEndpoint
73
74const apiId = "memcache:v1beta2"
75const apiName = "memcache"
76const apiVersion = "v1beta2"
77const basePath = "https://memcache.googleapis.com/"
78const mtlsBasePath = "https://memcache.mtls.googleapis.com/"
79
80// OAuth2 scopes used by this API.
81const (
82	// See, edit, configure, and delete your Google Cloud data and see the
83	// email address for your Google Account.
84	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
85)
86
87// NewService creates a new Service.
88func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
89	scopesOption := option.WithScopes(
90		"https://www.googleapis.com/auth/cloud-platform",
91	)
92	// NOTE: prepend, so we don't override user-specified scopes.
93	opts = append([]option.ClientOption{scopesOption}, opts...)
94	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
95	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
96	client, endpoint, err := htransport.NewClient(ctx, opts...)
97	if err != nil {
98		return nil, err
99	}
100	s, err := New(client)
101	if err != nil {
102		return nil, err
103	}
104	if endpoint != "" {
105		s.BasePath = endpoint
106	}
107	return s, nil
108}
109
110// New creates a new Service. It uses the provided http.Client for requests.
111//
112// Deprecated: please use NewService instead.
113// To provide a custom HTTP client, use option.WithHTTPClient.
114// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
115func New(client *http.Client) (*Service, error) {
116	if client == nil {
117		return nil, errors.New("client is nil")
118	}
119	s := &Service{client: client, BasePath: basePath}
120	s.Projects = NewProjectsService(s)
121	return s, nil
122}
123
124type Service struct {
125	client    *http.Client
126	BasePath  string // API endpoint base URL
127	UserAgent string // optional additional User-Agent fragment
128
129	Projects *ProjectsService
130}
131
132func (s *Service) userAgent() string {
133	if s.UserAgent == "" {
134		return googleapi.UserAgent
135	}
136	return googleapi.UserAgent + " " + s.UserAgent
137}
138
139func NewProjectsService(s *Service) *ProjectsService {
140	rs := &ProjectsService{s: s}
141	rs.Locations = NewProjectsLocationsService(s)
142	return rs
143}
144
145type ProjectsService struct {
146	s *Service
147
148	Locations *ProjectsLocationsService
149}
150
151func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
152	rs := &ProjectsLocationsService{s: s}
153	rs.Instances = NewProjectsLocationsInstancesService(s)
154	rs.Operations = NewProjectsLocationsOperationsService(s)
155	return rs
156}
157
158type ProjectsLocationsService struct {
159	s *Service
160
161	Instances *ProjectsLocationsInstancesService
162
163	Operations *ProjectsLocationsOperationsService
164}
165
166func NewProjectsLocationsInstancesService(s *Service) *ProjectsLocationsInstancesService {
167	rs := &ProjectsLocationsInstancesService{s: s}
168	return rs
169}
170
171type ProjectsLocationsInstancesService struct {
172	s *Service
173}
174
175func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
176	rs := &ProjectsLocationsOperationsService{s: s}
177	return rs
178}
179
180type ProjectsLocationsOperationsService struct {
181	s *Service
182}
183
184// ApplyParametersRequest: Request for ApplyParameters.
185type ApplyParametersRequest struct {
186	// ApplyAll: Whether to apply instance-level parameter group to all
187	// nodes. If set to true, users are restricted from specifying
188	// individual nodes, and `ApplyParameters` updates all nodes within the
189	// instance.
190	ApplyAll bool `json:"applyAll,omitempty"`
191
192	// NodeIds: Nodes to which the instance-level parameter group is
193	// applied.
194	NodeIds []string `json:"nodeIds,omitempty"`
195
196	// ForceSendFields is a list of field names (e.g. "ApplyAll") to
197	// unconditionally include in API requests. By default, fields with
198	// empty or default values are omitted from API requests. However, any
199	// non-pointer, non-interface field appearing in ForceSendFields will be
200	// sent to the server regardless of whether the field is empty or not.
201	// This may be used to include empty fields in Patch requests.
202	ForceSendFields []string `json:"-"`
203
204	// NullFields is a list of field names (e.g. "ApplyAll") to include in
205	// API requests with the JSON null value. By default, fields with empty
206	// values are omitted from API requests. However, any field with an
207	// empty value appearing in NullFields will be sent to the server as
208	// null. It is an error if a field in this list has a non-empty value.
209	// This may be used to include null fields in Patch requests.
210	NullFields []string `json:"-"`
211}
212
213func (s *ApplyParametersRequest) MarshalJSON() ([]byte, error) {
214	type NoMethod ApplyParametersRequest
215	raw := NoMethod(*s)
216	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
217}
218
219// ApplySoftwareUpdateRequest: Request for ApplySoftwareUpdate.
220type ApplySoftwareUpdateRequest struct {
221	// ApplyAll: Whether to apply the update to all nodes. If set to true,
222	// will explicitly restrict users from specifying any nodes, and apply
223	// software update to all nodes (where applicable) within the instance.
224	ApplyAll bool `json:"applyAll,omitempty"`
225
226	// NodeIds: Nodes to which we should apply the update to. Note all the
227	// selected nodes are updated in parallel.
228	NodeIds []string `json:"nodeIds,omitempty"`
229
230	// ForceSendFields is a list of field names (e.g. "ApplyAll") to
231	// unconditionally include in API requests. By default, fields with
232	// empty or default values are omitted from API requests. However, any
233	// non-pointer, non-interface field appearing in ForceSendFields will be
234	// sent to the server regardless of whether the field is empty or not.
235	// This may be used to include empty fields in Patch requests.
236	ForceSendFields []string `json:"-"`
237
238	// NullFields is a list of field names (e.g. "ApplyAll") to include in
239	// API requests with the JSON null value. By default, fields with empty
240	// values are omitted from API requests. However, any field with an
241	// empty value appearing in NullFields will be sent to the server as
242	// null. It is an error if a field in this list has a non-empty value.
243	// This may be used to include null fields in Patch requests.
244	NullFields []string `json:"-"`
245}
246
247func (s *ApplySoftwareUpdateRequest) MarshalJSON() ([]byte, error) {
248	type NoMethod ApplySoftwareUpdateRequest
249	raw := NoMethod(*s)
250	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
251}
252
253// CancelOperationRequest: The request message for
254// Operations.CancelOperation.
255type CancelOperationRequest struct {
256}
257
258// DailyCycle: Time window specified for daily operations.
259type DailyCycle struct {
260	// Duration: Output only. Duration of the time window, set by service
261	// producer.
262	Duration string `json:"duration,omitempty"`
263
264	// StartTime: Time within the day to start the operations.
265	StartTime *TimeOfDay `json:"startTime,omitempty"`
266
267	// ForceSendFields is a list of field names (e.g. "Duration") to
268	// unconditionally include in API requests. By default, fields with
269	// empty or default values are omitted from API requests. However, any
270	// non-pointer, non-interface field appearing in ForceSendFields will be
271	// sent to the server regardless of whether the field is empty or not.
272	// This may be used to include empty fields in Patch requests.
273	ForceSendFields []string `json:"-"`
274
275	// NullFields is a list of field names (e.g. "Duration") to include in
276	// API requests with the JSON null value. By default, fields with empty
277	// values are omitted from API requests. However, any field with an
278	// empty value appearing in NullFields will be sent to the server as
279	// null. It is an error if a field in this list has a non-empty value.
280	// This may be used to include null fields in Patch requests.
281	NullFields []string `json:"-"`
282}
283
284func (s *DailyCycle) MarshalJSON() ([]byte, error) {
285	type NoMethod DailyCycle
286	raw := NoMethod(*s)
287	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
288}
289
290// Date: Represents a whole or partial calendar date, such as a
291// birthday. The time of day and time zone are either specified
292// elsewhere or are insignificant. The date is relative to the Gregorian
293// Calendar. This can represent one of the following: * A full date,
294// with non-zero year, month, and day values * A month and day value,
295// with a zero year, such as an anniversary * A year on its own, with
296// zero month and day values * A year and month value, with a zero day,
297// such as a credit card expiration date Related types are
298// google.type.TimeOfDay and `google.protobuf.Timestamp`.
299type Date struct {
300	// Day: Day of a month. Must be from 1 to 31 and valid for the year and
301	// month, or 0 to specify a year by itself or a year and month where the
302	// day isn't significant.
303	Day int64 `json:"day,omitempty"`
304
305	// Month: Month of a year. Must be from 1 to 12, or 0 to specify a year
306	// without a month and day.
307	Month int64 `json:"month,omitempty"`
308
309	// Year: Year of the date. Must be from 1 to 9999, or 0 to specify a
310	// date without a year.
311	Year int64 `json:"year,omitempty"`
312
313	// ForceSendFields is a list of field names (e.g. "Day") to
314	// unconditionally include in API requests. By default, fields with
315	// empty or default values are omitted from API requests. However, any
316	// non-pointer, non-interface field appearing in ForceSendFields will be
317	// sent to the server regardless of whether the field is empty or not.
318	// This may be used to include empty fields in Patch requests.
319	ForceSendFields []string `json:"-"`
320
321	// NullFields is a list of field names (e.g. "Day") to include in API
322	// requests with the JSON null value. By default, fields with empty
323	// values are omitted from API requests. However, any field with an
324	// empty value appearing in NullFields will be sent to the server as
325	// null. It is an error if a field in this list has a non-empty value.
326	// This may be used to include null fields in Patch requests.
327	NullFields []string `json:"-"`
328}
329
330func (s *Date) MarshalJSON() ([]byte, error) {
331	type NoMethod Date
332	raw := NoMethod(*s)
333	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
334}
335
336// DenyMaintenancePeriod: DenyMaintenancePeriod definition. Maintenance
337// is forbidden within the deny period. The start_date must be less than
338// the end_date.
339type DenyMaintenancePeriod struct {
340	// EndDate: Deny period end date. This can be: * A full date, with
341	// non-zero year, month and day values. * A month and day value, with a
342	// zero year. Allows recurring deny periods each year. Date matching
343	// this period will have to be before the end.
344	EndDate *Date `json:"endDate,omitempty"`
345
346	// StartDate: Deny period start date. This can be: * A full date, with
347	// non-zero year, month and day values. * A month and day value, with a
348	// zero year. Allows recurring deny periods each year. Date matching
349	// this period will have to be the same or after the start.
350	StartDate *Date `json:"startDate,omitempty"`
351
352	// Time: Time in UTC when the Blackout period starts on start_date and
353	// ends on end_date. This can be: * Full time. * All zeros for 00:00:00
354	// UTC
355	Time *TimeOfDay `json:"time,omitempty"`
356
357	// ForceSendFields is a list of field names (e.g. "EndDate") to
358	// unconditionally include in API requests. By default, fields with
359	// empty or default values are omitted from API requests. However, any
360	// non-pointer, non-interface field appearing in ForceSendFields will be
361	// sent to the server regardless of whether the field is empty or not.
362	// This may be used to include empty fields in Patch requests.
363	ForceSendFields []string `json:"-"`
364
365	// NullFields is a list of field names (e.g. "EndDate") to include in
366	// API requests with the JSON null value. By default, fields with empty
367	// values are omitted from API requests. However, any field with an
368	// empty value appearing in NullFields will be sent to the server as
369	// null. It is an error if a field in this list has a non-empty value.
370	// This may be used to include null fields in Patch requests.
371	NullFields []string `json:"-"`
372}
373
374func (s *DenyMaintenancePeriod) MarshalJSON() ([]byte, error) {
375	type NoMethod DenyMaintenancePeriod
376	raw := NoMethod(*s)
377	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
378}
379
380// Empty: A generic empty message that you can re-use to avoid defining
381// duplicated empty messages in your APIs. A typical example is to use
382// it as the request or the response type of an API method. For
383// instance: service Foo { rpc Bar(google.protobuf.Empty) returns
384// (google.protobuf.Empty); } The JSON representation for `Empty` is
385// empty JSON object `{}`.
386type Empty struct {
387	// ServerResponse contains the HTTP response code and headers from the
388	// server.
389	googleapi.ServerResponse `json:"-"`
390}
391
392// GoogleCloudMemcacheV1beta2LocationMetadata: Metadata for the given
393// google.cloud.location.Location.
394type GoogleCloudMemcacheV1beta2LocationMetadata struct {
395	// AvailableZones: Output only. The set of available zones in the
396	// location. The map is keyed by the lowercase ID of each zone, as
397	// defined by GCE. These keys can be specified in the `zones` field when
398	// creating a Memcached instance.
399	AvailableZones map[string]GoogleCloudMemcacheV1beta2ZoneMetadata `json:"availableZones,omitempty"`
400
401	// ForceSendFields is a list of field names (e.g. "AvailableZones") to
402	// unconditionally include in API requests. By default, fields with
403	// empty or default values are omitted from API requests. However, any
404	// non-pointer, non-interface field appearing in ForceSendFields will be
405	// sent to the server regardless of whether the field is empty or not.
406	// This may be used to include empty fields in Patch requests.
407	ForceSendFields []string `json:"-"`
408
409	// NullFields is a list of field names (e.g. "AvailableZones") to
410	// include in API requests with the JSON null value. By default, fields
411	// with empty values are omitted from API requests. However, any field
412	// with an empty value appearing in NullFields will be sent to the
413	// server as null. It is an error if a field in this list has a
414	// non-empty value. This may be used to include null fields in Patch
415	// requests.
416	NullFields []string `json:"-"`
417}
418
419func (s *GoogleCloudMemcacheV1beta2LocationMetadata) MarshalJSON() ([]byte, error) {
420	type NoMethod GoogleCloudMemcacheV1beta2LocationMetadata
421	raw := NoMethod(*s)
422	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
423}
424
425// GoogleCloudMemcacheV1beta2OperationMetadata: Represents the metadata
426// of a long-running operation.
427type GoogleCloudMemcacheV1beta2OperationMetadata struct {
428	// ApiVersion: Output only. API version used to start the operation.
429	ApiVersion string `json:"apiVersion,omitempty"`
430
431	// CancelRequested: Output only. Identifies whether the user has
432	// requested cancellation of the operation. Operations that have
433	// successfully been cancelled have Operation.error value with a
434	// google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.
435	CancelRequested bool `json:"cancelRequested,omitempty"`
436
437	// CreateTime: Output only. Time when the operation was created.
438	CreateTime string `json:"createTime,omitempty"`
439
440	// EndTime: Output only. Time when the operation finished running.
441	EndTime string `json:"endTime,omitempty"`
442
443	// StatusDetail: Output only. Human-readable status of the operation, if
444	// any.
445	StatusDetail string `json:"statusDetail,omitempty"`
446
447	// Target: Output only. Server-defined resource path for the target of
448	// the operation.
449	Target string `json:"target,omitempty"`
450
451	// Verb: Output only. Name of the verb executed by the operation.
452	Verb string `json:"verb,omitempty"`
453
454	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
455	// unconditionally include in API requests. By default, fields with
456	// empty or default values are omitted from API requests. However, any
457	// non-pointer, non-interface field appearing in ForceSendFields will be
458	// sent to the server regardless of whether the field is empty or not.
459	// This may be used to include empty fields in Patch requests.
460	ForceSendFields []string `json:"-"`
461
462	// NullFields is a list of field names (e.g. "ApiVersion") to include in
463	// API requests with the JSON null value. By default, fields with empty
464	// values are omitted from API requests. However, any field with an
465	// empty value appearing in NullFields will be sent to the server as
466	// null. It is an error if a field in this list has a non-empty value.
467	// This may be used to include null fields in Patch requests.
468	NullFields []string `json:"-"`
469}
470
471func (s *GoogleCloudMemcacheV1beta2OperationMetadata) MarshalJSON() ([]byte, error) {
472	type NoMethod GoogleCloudMemcacheV1beta2OperationMetadata
473	raw := NoMethod(*s)
474	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
475}
476
477type GoogleCloudMemcacheV1beta2ZoneMetadata struct {
478}
479
480type GoogleCloudSaasacceleratorManagementProvidersV1Instance struct {
481	// ConsumerDefinedName: consumer_defined_name is the name that is set by
482	// the consumer. On the other hand Name field represents system-assigned
483	// id of an instance so consumers are not necessarily aware of it.
484	// consumer_defined_name is used for notification/UI purposes for
485	// consumer to recognize their instances.
486	ConsumerDefinedName string `json:"consumerDefinedName,omitempty"`
487
488	// CreateTime: Output only. Timestamp when the resource was created.
489	CreateTime string `json:"createTime,omitempty"`
490
491	// Labels: Optional. Resource labels to represent user provided
492	// metadata. Each label is a key-value pair, where both the key and the
493	// value are arbitrary strings provided by the user.
494	Labels map[string]string `json:"labels,omitempty"`
495
496	// MaintenancePolicyNames: Deprecated. The MaintenancePolicies that have
497	// been attached to the instance. The key must be of the type name of
498	// the oneof policy name defined in MaintenancePolicy, and the
499	// referenced policy must define the same policy type. For complete
500	// details of MaintenancePolicy, please refer to go/cloud-saas-mw-ug.
501	MaintenancePolicyNames map[string]string `json:"maintenancePolicyNames,omitempty"`
502
503	// MaintenanceSchedules: The MaintenanceSchedule contains the scheduling
504	// information of published maintenance schedule with same key as
505	// software_versions.
506	MaintenanceSchedules map[string]GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSchedule `json:"maintenanceSchedules,omitempty"`
507
508	// MaintenanceSettings: Optional. The MaintenanceSettings associated
509	// with instance.
510	MaintenanceSettings *GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSettings `json:"maintenanceSettings,omitempty"`
511
512	// Name: Unique name of the resource. It uses the form:
513	// `projects/{project_id|project_number}/locations/{location_id}/instance
514	// s/{instance_id}` Note: Either project_id or project_number can be
515	// used, but keep it consistent with other APIs (e.g. RescheduleUpdate)
516	Name string `json:"name,omitempty"`
517
518	// ProducerMetadata: Output only. Custom string attributes used
519	// primarily to expose producer-specific information in monitoring
520	// dashboards. See go/get-instance-metadata.
521	ProducerMetadata map[string]string `json:"producerMetadata,omitempty"`
522
523	// ProvisionedResources: Output only. The list of data plane resources
524	// provisioned for this instance, e.g. compute VMs. See
525	// go/get-instance-metadata.
526	ProvisionedResources []*GoogleCloudSaasacceleratorManagementProvidersV1ProvisionedResource `json:"provisionedResources,omitempty"`
527
528	// SlmInstanceTemplate: Link to the SLM instance template. Only
529	// populated when updating SLM instances via SSA's Actuation service
530	// adaptor. Service producers with custom control plane (e.g. Cloud SQL)
531	// doesn't need to populate this field. Instead they should use
532	// software_versions.
533	SlmInstanceTemplate string `json:"slmInstanceTemplate,omitempty"`
534
535	// SloMetadata: Output only. SLO metadata for instance classification in
536	// the Standardized dataplane SLO platform. See
537	// go/cloud-ssa-standard-slo for feature description.
538	SloMetadata *GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata `json:"sloMetadata,omitempty"`
539
540	// SoftwareVersions: Software versions that are used to deploy this
541	// instance. This can be mutated by rollout services.
542	SoftwareVersions map[string]string `json:"softwareVersions,omitempty"`
543
544	// State: Output only. Current lifecycle state of the resource (e.g. if
545	// it's being created or ready to use).
546	//
547	// Possible values:
548	//   "STATE_UNSPECIFIED" - Unspecified state.
549	//   "CREATING" - Instance is being created.
550	//   "READY" - Instance has been created and is ready to use.
551	//   "UPDATING" - Instance is being updated.
552	//   "REPAIRING" - Instance is unheathy and under repair.
553	//   "DELETING" - Instance is being deleted.
554	//   "ERROR" - Instance encountered an error and is in indeterministic
555	// state.
556	State string `json:"state,omitempty"`
557
558	// TenantProjectId: Output only. ID of the associated GCP tenant
559	// project. See go/get-instance-metadata.
560	TenantProjectId string `json:"tenantProjectId,omitempty"`
561
562	// UpdateTime: Output only. Timestamp when the resource was last
563	// modified.
564	UpdateTime string `json:"updateTime,omitempty"`
565
566	// ForceSendFields is a list of field names (e.g. "ConsumerDefinedName")
567	// to unconditionally include in API requests. By default, fields with
568	// empty or default values are omitted from API requests. However, any
569	// non-pointer, non-interface field appearing in ForceSendFields will be
570	// sent to the server regardless of whether the field is empty or not.
571	// This may be used to include empty fields in Patch requests.
572	ForceSendFields []string `json:"-"`
573
574	// NullFields is a list of field names (e.g. "ConsumerDefinedName") to
575	// include in API requests with the JSON null value. By default, fields
576	// with empty values are omitted from API requests. However, any field
577	// with an empty value appearing in NullFields will be sent to the
578	// server as null. It is an error if a field in this list has a
579	// non-empty value. This may be used to include null fields in Patch
580	// requests.
581	NullFields []string `json:"-"`
582}
583
584func (s *GoogleCloudSaasacceleratorManagementProvidersV1Instance) MarshalJSON() ([]byte, error) {
585	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1Instance
586	raw := NoMethod(*s)
587	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
588}
589
590// GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSchedule:
591// Maintenance schedule which is exposed to customer and potentially end
592// user, indicating published upcoming future maintenance schedule
593type GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSchedule struct {
594	// CanReschedule: This field is deprecated, and will be always set to
595	// true since reschedule can happen multiple times now. This field
596	// should not be removed until all service producers remove this for
597	// their customers.
598	CanReschedule bool `json:"canReschedule,omitempty"`
599
600	// EndTime: The scheduled end time for the maintenance.
601	EndTime string `json:"endTime,omitempty"`
602
603	// RolloutManagementPolicy: The rollout management policy this
604	// maintenance schedule is associated with. When doing reschedule update
605	// request, the reschedule should be against this given policy.
606	RolloutManagementPolicy string `json:"rolloutManagementPolicy,omitempty"`
607
608	// ScheduleDeadlineTime: schedule_deadline_time is the time deadline any
609	// schedule start time cannot go beyond, including reschedule. It's
610	// normally the initial schedule start time plus maintenance window
611	// length (1 day or 1 week). Maintenance cannot be scheduled to start
612	// beyond this deadline.
613	ScheduleDeadlineTime string `json:"scheduleDeadlineTime,omitempty"`
614
615	// StartTime: The scheduled start time for the maintenance.
616	StartTime string `json:"startTime,omitempty"`
617
618	// ForceSendFields is a list of field names (e.g. "CanReschedule") to
619	// unconditionally include in API requests. By default, fields with
620	// empty or default values are omitted from API requests. However, any
621	// non-pointer, non-interface field appearing in ForceSendFields will be
622	// sent to the server regardless of whether the field is empty or not.
623	// This may be used to include empty fields in Patch requests.
624	ForceSendFields []string `json:"-"`
625
626	// NullFields is a list of field names (e.g. "CanReschedule") to include
627	// in API requests with the JSON null value. By default, fields with
628	// empty values are omitted from API requests. However, any field with
629	// an empty value appearing in NullFields will be sent to the server as
630	// null. It is an error if a field in this list has a non-empty value.
631	// This may be used to include null fields in Patch requests.
632	NullFields []string `json:"-"`
633}
634
635func (s *GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSchedule) MarshalJSON() ([]byte, error) {
636	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSchedule
637	raw := NoMethod(*s)
638	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
639}
640
641// GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSettings:
642// Maintenance settings associated with instance. Allows service
643// producers and end users to assign settings that controls maintenance
644// on this instance.
645type GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSettings struct {
646	// Exclude: Optional. Exclude instance from maintenance. When true,
647	// rollout service will not attempt maintenance on the instance. Rollout
648	// service will include the instance in reported rollout progress as not
649	// attempted.
650	Exclude bool `json:"exclude,omitempty"`
651
652	// IsRollback: Optional. If the update call is triggered from rollback,
653	// set the value as true.
654	IsRollback bool `json:"isRollback,omitempty"`
655
656	// MaintenancePolicies: Optional. The MaintenancePolicies that have been
657	// attached to the instance. The key must be of the type name of the
658	// oneof policy name defined in MaintenancePolicy, and the embedded
659	// policy must define the same policy type. For complete details of
660	// MaintenancePolicy, please refer to go/cloud-saas-mw-ug. If only the
661	// name is needed (like in the deprecated
662	// Instance.maintenance_policy_names field) then only populate
663	// MaintenancePolicy.name.
664	MaintenancePolicies map[string]MaintenancePolicy `json:"maintenancePolicies,omitempty"`
665
666	// ForceSendFields is a list of field names (e.g. "Exclude") to
667	// unconditionally include in API requests. By default, fields with
668	// empty or default values are omitted from API requests. However, any
669	// non-pointer, non-interface field appearing in ForceSendFields will be
670	// sent to the server regardless of whether the field is empty or not.
671	// This may be used to include empty fields in Patch requests.
672	ForceSendFields []string `json:"-"`
673
674	// NullFields is a list of field names (e.g. "Exclude") to include in
675	// API requests with the JSON null value. By default, fields with empty
676	// values are omitted from API requests. However, any field with an
677	// empty value appearing in NullFields will be sent to the server as
678	// null. It is an error if a field in this list has a non-empty value.
679	// This may be used to include null fields in Patch requests.
680	NullFields []string `json:"-"`
681}
682
683func (s *GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSettings) MarshalJSON() ([]byte, error) {
684	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1MaintenanceSettings
685	raw := NoMethod(*s)
686	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
687}
688
689// GoogleCloudSaasacceleratorManagementProvidersV1NodeSloMetadata: Node
690// information for custom per-node SLO implementations. SSA does not
691// support per-node SLO, but producers can populate per-node information
692// in SloMetadata for custom precomputations. SSA Eligibility Exporter
693// will emit per-node metric based on this information.
694type GoogleCloudSaasacceleratorManagementProvidersV1NodeSloMetadata struct {
695	// Location: The location of the node, if different from instance
696	// location.
697	Location string `json:"location,omitempty"`
698
699	// NodeId: The id of the node. This should be equal to
700	// SaasInstanceNode.node_id.
701	NodeId string `json:"nodeId,omitempty"`
702
703	// PerSliEligibility: If present, this will override eligibility for the
704	// node coming from instance or exclusions for specified SLIs.
705	PerSliEligibility *GoogleCloudSaasacceleratorManagementProvidersV1PerSliSloEligibility `json:"perSliEligibility,omitempty"`
706
707	// ForceSendFields is a list of field names (e.g. "Location") to
708	// unconditionally include in API requests. By default, fields with
709	// empty or default values are omitted from API requests. However, any
710	// non-pointer, non-interface field appearing in ForceSendFields will be
711	// sent to the server regardless of whether the field is empty or not.
712	// This may be used to include empty fields in Patch requests.
713	ForceSendFields []string `json:"-"`
714
715	// NullFields is a list of field names (e.g. "Location") to include in
716	// API requests with the JSON null value. By default, fields with empty
717	// values are omitted from API requests. However, any field with an
718	// empty value appearing in NullFields will be sent to the server as
719	// null. It is an error if a field in this list has a non-empty value.
720	// This may be used to include null fields in Patch requests.
721	NullFields []string `json:"-"`
722}
723
724func (s *GoogleCloudSaasacceleratorManagementProvidersV1NodeSloMetadata) MarshalJSON() ([]byte, error) {
725	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1NodeSloMetadata
726	raw := NoMethod(*s)
727	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
728}
729
730// GoogleCloudSaasacceleratorManagementProvidersV1PerSliSloEligibility:
731// PerSliSloEligibility is a mapping from an SLI name to eligibility.
732type GoogleCloudSaasacceleratorManagementProvidersV1PerSliSloEligibility struct {
733	// Eligibilities: An entry in the eligibilities map specifies an
734	// eligibility for a particular SLI for the given instance. The SLI key
735	// in the name must be a valid SLI name specified in the Eligibility
736	// Exporter binary flags otherwise an error will be emitted by
737	// Eligibility Exporter and the oncaller will be alerted. If an SLI has
738	// been defined in the binary flags but the eligibilities map does not
739	// contain it, the corresponding SLI time series will not be emitted by
740	// the Eligibility Exporter. This ensures a smooth rollout and
741	// compatibility between the data produced by different versions of the
742	// Eligibility Exporters. If eligibilities map contains a key for an SLI
743	// which has not been declared in the binary flags, there will be an
744	// error message emitted in the Eligibility Exporter log and the metric
745	// for the SLI in question will not be emitted.
746	Eligibilities map[string]GoogleCloudSaasacceleratorManagementProvidersV1SloEligibility `json:"eligibilities,omitempty"`
747
748	// ForceSendFields is a list of field names (e.g. "Eligibilities") to
749	// unconditionally include in API requests. By default, fields with
750	// empty or default values are omitted from API requests. However, any
751	// non-pointer, non-interface field appearing in ForceSendFields will be
752	// sent to the server regardless of whether the field is empty or not.
753	// This may be used to include empty fields in Patch requests.
754	ForceSendFields []string `json:"-"`
755
756	// NullFields is a list of field names (e.g. "Eligibilities") to include
757	// in API requests with the JSON null value. By default, fields with
758	// empty values are omitted from API requests. However, any field with
759	// an empty value appearing in NullFields will be sent to the server as
760	// null. It is an error if a field in this list has a non-empty value.
761	// This may be used to include null fields in Patch requests.
762	NullFields []string `json:"-"`
763}
764
765func (s *GoogleCloudSaasacceleratorManagementProvidersV1PerSliSloEligibility) MarshalJSON() ([]byte, error) {
766	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1PerSliSloEligibility
767	raw := NoMethod(*s)
768	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
769}
770
771// GoogleCloudSaasacceleratorManagementProvidersV1ProvisionedResource:
772// Describes provisioned dataplane resources.
773type GoogleCloudSaasacceleratorManagementProvidersV1ProvisionedResource struct {
774	// ResourceType: Type of the resource. This can be either a GCP resource
775	// or a custom one (e.g. another cloud provider's VM). For GCP compute
776	// resources use singular form of the names listed in GCP compute API
777	// documentation
778	// (https://cloud.google.com/compute/docs/reference/rest/v1/), prefixed
779	// with 'compute-', for example: 'compute-instance', 'compute-disk',
780	// 'compute-autoscaler'.
781	ResourceType string `json:"resourceType,omitempty"`
782
783	// ResourceUrl: URL identifying the resource, e.g.
784	// "https://www.googleapis.com/compute/v1/projects/...)".
785	ResourceUrl string `json:"resourceUrl,omitempty"`
786
787	// ForceSendFields is a list of field names (e.g. "ResourceType") to
788	// unconditionally include in API requests. By default, fields with
789	// empty or default values are omitted from API requests. However, any
790	// non-pointer, non-interface field appearing in ForceSendFields will be
791	// sent to the server regardless of whether the field is empty or not.
792	// This may be used to include empty fields in Patch requests.
793	ForceSendFields []string `json:"-"`
794
795	// NullFields is a list of field names (e.g. "ResourceType") to include
796	// in API requests with the JSON null value. By default, fields with
797	// empty values are omitted from API requests. However, any field with
798	// an empty value appearing in NullFields will be sent to the server as
799	// null. It is an error if a field in this list has a non-empty value.
800	// This may be used to include null fields in Patch requests.
801	NullFields []string `json:"-"`
802}
803
804func (s *GoogleCloudSaasacceleratorManagementProvidersV1ProvisionedResource) MarshalJSON() ([]byte, error) {
805	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1ProvisionedResource
806	raw := NoMethod(*s)
807	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
808}
809
810// GoogleCloudSaasacceleratorManagementProvidersV1SloEligibility:
811// SloEligibility is a tuple containing eligibility value: true if an
812// instance is eligible for SLO calculation or false if it should be
813// excluded from all SLO-related calculations along with a user-defined
814// reason.
815type GoogleCloudSaasacceleratorManagementProvidersV1SloEligibility struct {
816	// Eligible: Whether an instance is eligible or ineligible.
817	Eligible bool `json:"eligible,omitempty"`
818
819	// Reason: User-defined reason for the current value of instance
820	// eligibility. Usually, this can be directly mapped to the internal
821	// state. An empty reason is allowed.
822	Reason string `json:"reason,omitempty"`
823
824	// ForceSendFields is a list of field names (e.g. "Eligible") to
825	// unconditionally include in API requests. By default, fields with
826	// empty or default values are omitted from API requests. However, any
827	// non-pointer, non-interface field appearing in ForceSendFields will be
828	// sent to the server regardless of whether the field is empty or not.
829	// This may be used to include empty fields in Patch requests.
830	ForceSendFields []string `json:"-"`
831
832	// NullFields is a list of field names (e.g. "Eligible") to include in
833	// API requests with the JSON null value. By default, fields with empty
834	// values are omitted from API requests. However, any field with an
835	// empty value appearing in NullFields will be sent to the server as
836	// null. It is an error if a field in this list has a non-empty value.
837	// This may be used to include null fields in Patch requests.
838	NullFields []string `json:"-"`
839}
840
841func (s *GoogleCloudSaasacceleratorManagementProvidersV1SloEligibility) MarshalJSON() ([]byte, error) {
842	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1SloEligibility
843	raw := NoMethod(*s)
844	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
845}
846
847// GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata:
848// SloMetadata contains resources required for proper SLO classification
849// of the instance.
850type GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata struct {
851	// Nodes: Optional. List of nodes. Some producers need to use per-node
852	// metadata to calculate SLO. This field allows such producers to
853	// publish per-node SLO meta data, which will be consumed by SSA
854	// Eligibility Exporter and published in the form of per node metric to
855	// Monarch.
856	Nodes []*GoogleCloudSaasacceleratorManagementProvidersV1NodeSloMetadata `json:"nodes,omitempty"`
857
858	// PerSliEligibility: Optional. Multiple per-instance SLI eligibilities
859	// which apply for individual SLIs.
860	PerSliEligibility *GoogleCloudSaasacceleratorManagementProvidersV1PerSliSloEligibility `json:"perSliEligibility,omitempty"`
861
862	// Tier: Name of the SLO tier the Instance belongs to. This name will be
863	// expected to match the tiers specified in the service SLO
864	// configuration. Field is mandatory and must not be empty.
865	Tier string `json:"tier,omitempty"`
866
867	// ForceSendFields is a list of field names (e.g. "Nodes") to
868	// unconditionally include in API requests. By default, fields with
869	// empty or default values are omitted from API requests. However, any
870	// non-pointer, non-interface field appearing in ForceSendFields will be
871	// sent to the server regardless of whether the field is empty or not.
872	// This may be used to include empty fields in Patch requests.
873	ForceSendFields []string `json:"-"`
874
875	// NullFields is a list of field names (e.g. "Nodes") to include in API
876	// requests with the JSON null value. By default, fields with empty
877	// values are omitted from API requests. However, any field with an
878	// empty value appearing in NullFields will be sent to the server as
879	// null. It is an error if a field in this list has a non-empty value.
880	// This may be used to include null fields in Patch requests.
881	NullFields []string `json:"-"`
882}
883
884func (s *GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata) MarshalJSON() ([]byte, error) {
885	type NoMethod GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata
886	raw := NoMethod(*s)
887	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
888}
889
890// Instance: A Memorystore for Memcached instance
891type Instance struct {
892	// AuthorizedNetwork: The full name of the Google Compute Engine network
893	// (https://cloud.google.com/vpc/docs/vpc) to which the instance is
894	// connected. If left unspecified, the `default` network will be used.
895	AuthorizedNetwork string `json:"authorizedNetwork,omitempty"`
896
897	// CreateTime: Output only. The time the instance was created.
898	CreateTime string `json:"createTime,omitempty"`
899
900	// DiscoveryEndpoint: Output only. Endpoint for the Discovery API.
901	DiscoveryEndpoint string `json:"discoveryEndpoint,omitempty"`
902
903	// DisplayName: User provided name for the instance, which is only used
904	// for display purposes. Cannot be more than 80 characters.
905	DisplayName string `json:"displayName,omitempty"`
906
907	// InstanceMessages: List of messages that describe the current state of
908	// the Memcached instance.
909	InstanceMessages []*InstanceMessage `json:"instanceMessages,omitempty"`
910
911	// Labels: Resource labels to represent user-provided metadata. Refer to
912	// cloud documentation on labels for more details.
913	// https://cloud.google.com/compute/docs/labeling-resources
914	Labels map[string]string `json:"labels,omitempty"`
915
916	// MemcacheFullVersion: Output only. The full version of memcached
917	// server running on this instance. System automatically determines the
918	// full memcached version for an instance based on the input
919	// MemcacheVersion. The full version format will be "memcached-1.5.16".
920	MemcacheFullVersion string `json:"memcacheFullVersion,omitempty"`
921
922	// MemcacheNodes: Output only. List of Memcached nodes. Refer to Node
923	// message for more details.
924	MemcacheNodes []*Node `json:"memcacheNodes,omitempty"`
925
926	// MemcacheVersion: The major version of Memcached software. If not
927	// provided, latest supported version will be used. Currently the latest
928	// supported major version is `MEMCACHE_1_5`. The minor version will be
929	// automatically determined by our system based on the latest supported
930	// minor version.
931	//
932	// Possible values:
933	//   "MEMCACHE_VERSION_UNSPECIFIED"
934	//   "MEMCACHE_1_5" - Memcached 1.5 version.
935	MemcacheVersion string `json:"memcacheVersion,omitempty"`
936
937	// Name: Required. Unique name of the resource in this scope including
938	// project and location using the form:
939	// `projects/{project_id}/locations/{location_id}/instances/{instance_id}
940	// ` Note: Memcached instances are managed and addressed at the regional
941	// level so `location_id` here refers to a Google Cloud region; however,
942	// users may choose which zones Memcached nodes should be provisioned in
943	// within an instance. Refer to zones field for more details.
944	Name string `json:"name,omitempty"`
945
946	// NodeConfig: Required. Configuration for Memcached nodes.
947	NodeConfig *NodeConfig `json:"nodeConfig,omitempty"`
948
949	// NodeCount: Required. Number of nodes in the Memcached instance.
950	NodeCount int64 `json:"nodeCount,omitempty"`
951
952	// Parameters: Optional: User defined parameters to apply to the
953	// memcached process on each node.
954	Parameters *MemcacheParameters `json:"parameters,omitempty"`
955
956	// State: Output only. The state of this Memcached instance.
957	//
958	// Possible values:
959	//   "STATE_UNSPECIFIED" - State not set.
960	//   "CREATING" - Memcached instance is being created.
961	//   "READY" - Memcached instance has been created and ready to be used.
962	//   "UPDATING" - Memcached instance is updating configuration such as
963	// maintenance policy and schedule.
964	//   "DELETING" - Memcached instance is being deleted.
965	//   "PERFORMING_MAINTENANCE" - Memcached instance is going through
966	// maintenance, e.g. data plane rollout.
967	State string `json:"state,omitempty"`
968
969	// UpdateAvailable: Output only. Returns true if there is an update
970	// waiting to be applied
971	UpdateAvailable bool `json:"updateAvailable,omitempty"`
972
973	// UpdateTime: Output only. The time the instance was updated.
974	UpdateTime string `json:"updateTime,omitempty"`
975
976	// Zones: Zones in which Memcached nodes should be provisioned.
977	// Memcached nodes will be equally distributed across these zones. If
978	// not provided, the service will by default create nodes in all zones
979	// in the region for the instance.
980	Zones []string `json:"zones,omitempty"`
981
982	// ServerResponse contains the HTTP response code and headers from the
983	// server.
984	googleapi.ServerResponse `json:"-"`
985
986	// ForceSendFields is a list of field names (e.g. "AuthorizedNetwork")
987	// to unconditionally include in API requests. By default, fields with
988	// empty or default values are omitted from API requests. However, any
989	// non-pointer, non-interface field appearing in ForceSendFields will be
990	// sent to the server regardless of whether the field is empty or not.
991	// This may be used to include empty fields in Patch requests.
992	ForceSendFields []string `json:"-"`
993
994	// NullFields is a list of field names (e.g. "AuthorizedNetwork") to
995	// include in API requests with the JSON null value. By default, fields
996	// with empty values are omitted from API requests. However, any field
997	// with an empty value appearing in NullFields will be sent to the
998	// server as null. It is an error if a field in this list has a
999	// non-empty value. This may be used to include null fields in Patch
1000	// requests.
1001	NullFields []string `json:"-"`
1002}
1003
1004func (s *Instance) MarshalJSON() ([]byte, error) {
1005	type NoMethod Instance
1006	raw := NoMethod(*s)
1007	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1008}
1009
1010type InstanceMessage struct {
1011	// Code: A code that correspond to one type of user-facing message.
1012	//
1013	// Possible values:
1014	//   "CODE_UNSPECIFIED" - Message Code not set.
1015	//   "ZONE_DISTRIBUTION_UNBALANCED" - Memcached nodes are distributed
1016	// unevenly.
1017	Code string `json:"code,omitempty"`
1018
1019	// Message: Message on memcached instance which will be exposed to
1020	// users.
1021	Message string `json:"message,omitempty"`
1022
1023	// ForceSendFields is a list of field names (e.g. "Code") to
1024	// unconditionally include in API requests. By default, fields with
1025	// empty or default values are omitted from API requests. However, any
1026	// non-pointer, non-interface field appearing in ForceSendFields will be
1027	// sent to the server regardless of whether the field is empty or not.
1028	// This may be used to include empty fields in Patch requests.
1029	ForceSendFields []string `json:"-"`
1030
1031	// NullFields is a list of field names (e.g. "Code") to include in API
1032	// requests with the JSON null value. By default, fields with empty
1033	// values are omitted from API requests. However, any field with an
1034	// empty value appearing in NullFields will be sent to the server as
1035	// null. It is an error if a field in this list has a non-empty value.
1036	// This may be used to include null fields in Patch requests.
1037	NullFields []string `json:"-"`
1038}
1039
1040func (s *InstanceMessage) MarshalJSON() ([]byte, error) {
1041	type NoMethod InstanceMessage
1042	raw := NoMethod(*s)
1043	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1044}
1045
1046// ListInstancesResponse: Response for ListInstances.
1047type ListInstancesResponse struct {
1048	// NextPageToken: Token to retrieve the next page of results, or empty
1049	// if there are no more results in the list.
1050	NextPageToken string `json:"nextPageToken,omitempty"`
1051
1052	// Resources: A list of Memcached instances in the project in the
1053	// specified location, or across all locations. If the `location_id` in
1054	// the parent field of the request is "-", all regions available to the
1055	// project are queried, and the results aggregated.
1056	Resources []*Instance `json:"resources,omitempty"`
1057
1058	// Unreachable: Locations that could not be reached.
1059	Unreachable []string `json:"unreachable,omitempty"`
1060
1061	// ServerResponse contains the HTTP response code and headers from the
1062	// server.
1063	googleapi.ServerResponse `json:"-"`
1064
1065	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
1066	// unconditionally include in API requests. By default, fields with
1067	// empty or default values are omitted from API requests. However, any
1068	// non-pointer, non-interface field appearing in ForceSendFields will be
1069	// sent to the server regardless of whether the field is empty or not.
1070	// This may be used to include empty fields in Patch requests.
1071	ForceSendFields []string `json:"-"`
1072
1073	// NullFields is a list of field names (e.g. "NextPageToken") to include
1074	// in API requests with the JSON null value. By default, fields with
1075	// empty values are omitted from API requests. However, any field with
1076	// an empty value appearing in NullFields will be sent to the server as
1077	// null. It is an error if a field in this list has a non-empty value.
1078	// This may be used to include null fields in Patch requests.
1079	NullFields []string `json:"-"`
1080}
1081
1082func (s *ListInstancesResponse) MarshalJSON() ([]byte, error) {
1083	type NoMethod ListInstancesResponse
1084	raw := NoMethod(*s)
1085	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1086}
1087
1088// ListLocationsResponse: The response message for
1089// Locations.ListLocations.
1090type ListLocationsResponse struct {
1091	// Locations: A list of locations that matches the specified filter in
1092	// the request.
1093	Locations []*Location `json:"locations,omitempty"`
1094
1095	// NextPageToken: The standard List next-page token.
1096	NextPageToken string `json:"nextPageToken,omitempty"`
1097
1098	// ServerResponse contains the HTTP response code and headers from the
1099	// server.
1100	googleapi.ServerResponse `json:"-"`
1101
1102	// ForceSendFields is a list of field names (e.g. "Locations") to
1103	// unconditionally include in API requests. By default, fields with
1104	// empty or default values are omitted from API requests. However, any
1105	// non-pointer, non-interface field appearing in ForceSendFields will be
1106	// sent to the server regardless of whether the field is empty or not.
1107	// This may be used to include empty fields in Patch requests.
1108	ForceSendFields []string `json:"-"`
1109
1110	// NullFields is a list of field names (e.g. "Locations") to include in
1111	// API requests with the JSON null value. By default, fields with empty
1112	// values are omitted from API requests. However, any field with an
1113	// empty value appearing in NullFields will be sent to the server as
1114	// null. It is an error if a field in this list has a non-empty value.
1115	// This may be used to include null fields in Patch requests.
1116	NullFields []string `json:"-"`
1117}
1118
1119func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) {
1120	type NoMethod ListLocationsResponse
1121	raw := NoMethod(*s)
1122	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1123}
1124
1125// ListOperationsResponse: The response message for
1126// Operations.ListOperations.
1127type ListOperationsResponse struct {
1128	// NextPageToken: The standard List next-page token.
1129	NextPageToken string `json:"nextPageToken,omitempty"`
1130
1131	// Operations: A list of operations that matches the specified filter in
1132	// the request.
1133	Operations []*Operation `json:"operations,omitempty"`
1134
1135	// ServerResponse contains the HTTP response code and headers from the
1136	// server.
1137	googleapi.ServerResponse `json:"-"`
1138
1139	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
1140	// unconditionally include in API requests. By default, fields with
1141	// empty or default values are omitted from API requests. However, any
1142	// non-pointer, non-interface field appearing in ForceSendFields will be
1143	// sent to the server regardless of whether the field is empty or not.
1144	// This may be used to include empty fields in Patch requests.
1145	ForceSendFields []string `json:"-"`
1146
1147	// NullFields is a list of field names (e.g. "NextPageToken") to include
1148	// in API requests with the JSON null value. By default, fields with
1149	// empty values are omitted from API requests. However, any field with
1150	// an empty value appearing in NullFields will be sent to the server as
1151	// null. It is an error if a field in this list has a non-empty value.
1152	// This may be used to include null fields in Patch requests.
1153	NullFields []string `json:"-"`
1154}
1155
1156func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
1157	type NoMethod ListOperationsResponse
1158	raw := NoMethod(*s)
1159	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1160}
1161
1162// Location: A resource that represents Google Cloud Platform location.
1163type Location struct {
1164	// DisplayName: The friendly name for this location, typically a nearby
1165	// city name. For example, "Tokyo".
1166	DisplayName string `json:"displayName,omitempty"`
1167
1168	// Labels: Cross-service attributes for the location. For example
1169	// {"cloud.googleapis.com/region": "us-east1"}
1170	Labels map[string]string `json:"labels,omitempty"`
1171
1172	// LocationId: The canonical id for this location. For example:
1173	// "us-east1".
1174	LocationId string `json:"locationId,omitempty"`
1175
1176	// Metadata: Service-specific metadata. For example the available
1177	// capacity at the given location.
1178	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
1179
1180	// Name: Resource name for the location, which may vary between
1181	// implementations. For example:
1182	// "projects/example-project/locations/us-east1"
1183	Name string `json:"name,omitempty"`
1184
1185	// ServerResponse contains the HTTP response code and headers from the
1186	// server.
1187	googleapi.ServerResponse `json:"-"`
1188
1189	// ForceSendFields is a list of field names (e.g. "DisplayName") to
1190	// unconditionally include in API requests. By default, fields with
1191	// empty or default values are omitted from API requests. However, any
1192	// non-pointer, non-interface field appearing in ForceSendFields will be
1193	// sent to the server regardless of whether the field is empty or not.
1194	// This may be used to include empty fields in Patch requests.
1195	ForceSendFields []string `json:"-"`
1196
1197	// NullFields is a list of field names (e.g. "DisplayName") to include
1198	// in API requests with the JSON null value. By default, fields with
1199	// empty values are omitted from API requests. However, any field with
1200	// an empty value appearing in NullFields will be sent to the server as
1201	// null. It is an error if a field in this list has a non-empty value.
1202	// This may be used to include null fields in Patch requests.
1203	NullFields []string `json:"-"`
1204}
1205
1206func (s *Location) MarshalJSON() ([]byte, error) {
1207	type NoMethod Location
1208	raw := NoMethod(*s)
1209	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1210}
1211
1212// LocationMetadata: Metadata for the given
1213// google.cloud.location.Location.
1214type LocationMetadata struct {
1215	// AvailableZones: Output only. The set of available zones in the
1216	// location. The map is keyed by the lowercase ID of each zone, as
1217	// defined by GCE. These keys can be specified in the `zones` field when
1218	// creating a Memcached instance.
1219	AvailableZones map[string]ZoneMetadata `json:"availableZones,omitempty"`
1220
1221	// ForceSendFields is a list of field names (e.g. "AvailableZones") to
1222	// unconditionally include in API requests. By default, fields with
1223	// empty or default values are omitted from API requests. However, any
1224	// non-pointer, non-interface field appearing in ForceSendFields will be
1225	// sent to the server regardless of whether the field is empty or not.
1226	// This may be used to include empty fields in Patch requests.
1227	ForceSendFields []string `json:"-"`
1228
1229	// NullFields is a list of field names (e.g. "AvailableZones") to
1230	// include in API requests with the JSON null value. By default, fields
1231	// with empty values are omitted from API requests. However, any field
1232	// with an empty value appearing in NullFields will be sent to the
1233	// server as null. It is an error if a field in this list has a
1234	// non-empty value. This may be used to include null fields in Patch
1235	// requests.
1236	NullFields []string `json:"-"`
1237}
1238
1239func (s *LocationMetadata) MarshalJSON() ([]byte, error) {
1240	type NoMethod LocationMetadata
1241	raw := NoMethod(*s)
1242	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1243}
1244
1245// MaintenancePolicy: Defines policies to service maintenance events.
1246type MaintenancePolicy struct {
1247	// CreateTime: Output only. The time when the resource was created.
1248	CreateTime string `json:"createTime,omitempty"`
1249
1250	// Description: Optional. Description of what this policy is for.
1251	// Create/Update methods return INVALID_ARGUMENT if the length is
1252	// greater than 512.
1253	Description string `json:"description,omitempty"`
1254
1255	// Labels: Optional. Resource labels to represent user provided
1256	// metadata. Each label is a key-value pair, where both the key and the
1257	// value are arbitrary strings provided by the user.
1258	Labels map[string]string `json:"labels,omitempty"`
1259
1260	// Name: Required. MaintenancePolicy name using the form:
1261	// `projects/{project_id}/locations/{location_id}/maintenancePolicies/{ma
1262	// intenance_policy_id}` where {project_id} refers to a GCP consumer
1263	// project ID, {location_id} refers to a GCP region/zone,
1264	// {maintenance_policy_id} must be 1-63 characters long and match the
1265	// regular expression `[a-z0-9]([-a-z0-9]*[a-z0-9])?`.
1266	Name string `json:"name,omitempty"`
1267
1268	// State: Optional. The state of the policy.
1269	//
1270	// Possible values:
1271	//   "STATE_UNSPECIFIED" - Unspecified state.
1272	//   "READY" - Resource is ready to be used.
1273	//   "DELETING" - Resource is being deleted. It can no longer be
1274	// attached to instances.
1275	State string `json:"state,omitempty"`
1276
1277	// UpdatePolicy: Maintenance policy applicable to instance update.
1278	UpdatePolicy *UpdatePolicy `json:"updatePolicy,omitempty"`
1279
1280	// UpdateTime: Output only. The time when the resource was updated.
1281	UpdateTime string `json:"updateTime,omitempty"`
1282
1283	// ForceSendFields is a list of field names (e.g. "CreateTime") to
1284	// unconditionally include in API requests. By default, fields with
1285	// empty or default values are omitted from API requests. However, any
1286	// non-pointer, non-interface field appearing in ForceSendFields will be
1287	// sent to the server regardless of whether the field is empty or not.
1288	// This may be used to include empty fields in Patch requests.
1289	ForceSendFields []string `json:"-"`
1290
1291	// NullFields is a list of field names (e.g. "CreateTime") to include in
1292	// API requests with the JSON null value. By default, fields with empty
1293	// values are omitted from API requests. However, any field with an
1294	// empty value appearing in NullFields will be sent to the server as
1295	// null. It is an error if a field in this list has a non-empty value.
1296	// This may be used to include null fields in Patch requests.
1297	NullFields []string `json:"-"`
1298}
1299
1300func (s *MaintenancePolicy) MarshalJSON() ([]byte, error) {
1301	type NoMethod MaintenancePolicy
1302	raw := NoMethod(*s)
1303	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1304}
1305
1306// MaintenanceWindow: MaintenanceWindow definition.
1307type MaintenanceWindow struct {
1308	// DailyCycle: Daily cycle.
1309	DailyCycle *DailyCycle `json:"dailyCycle,omitempty"`
1310
1311	// WeeklyCycle: Weekly cycle.
1312	WeeklyCycle *WeeklyCycle `json:"weeklyCycle,omitempty"`
1313
1314	// ForceSendFields is a list of field names (e.g. "DailyCycle") to
1315	// unconditionally include in API requests. By default, fields with
1316	// empty or default values are omitted from API requests. However, any
1317	// non-pointer, non-interface field appearing in ForceSendFields will be
1318	// sent to the server regardless of whether the field is empty or not.
1319	// This may be used to include empty fields in Patch requests.
1320	ForceSendFields []string `json:"-"`
1321
1322	// NullFields is a list of field names (e.g. "DailyCycle") to include in
1323	// API requests with the JSON null value. By default, fields with empty
1324	// values are omitted from API requests. However, any field with an
1325	// empty value appearing in NullFields will be sent to the server as
1326	// null. It is an error if a field in this list has a non-empty value.
1327	// This may be used to include null fields in Patch requests.
1328	NullFields []string `json:"-"`
1329}
1330
1331func (s *MaintenanceWindow) MarshalJSON() ([]byte, error) {
1332	type NoMethod MaintenanceWindow
1333	raw := NoMethod(*s)
1334	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1335}
1336
1337// MemcacheParameters: The unique ID associated with this set of
1338// parameters. Users can use this id to determine if the parameters
1339// associated with the instance differ from the parameters associated
1340// with the nodes. A discrepancy between parameter ids can inform users
1341// that they may need to take action to apply parameters on nodes.
1342type MemcacheParameters struct {
1343	// Id: Output only.
1344	Id string `json:"id,omitempty"`
1345
1346	// Params: User defined set of parameters to use in the memcached
1347	// process.
1348	Params map[string]string `json:"params,omitempty"`
1349
1350	// ForceSendFields is a list of field names (e.g. "Id") to
1351	// unconditionally include in API requests. By default, fields with
1352	// empty or default values are omitted from API requests. However, any
1353	// non-pointer, non-interface field appearing in ForceSendFields will be
1354	// sent to the server regardless of whether the field is empty or not.
1355	// This may be used to include empty fields in Patch requests.
1356	ForceSendFields []string `json:"-"`
1357
1358	// NullFields is a list of field names (e.g. "Id") to include in API
1359	// requests with the JSON null value. By default, fields with empty
1360	// values are omitted from API requests. However, any field with an
1361	// empty value appearing in NullFields will be sent to the server as
1362	// null. It is an error if a field in this list has a non-empty value.
1363	// This may be used to include null fields in Patch requests.
1364	NullFields []string `json:"-"`
1365}
1366
1367func (s *MemcacheParameters) MarshalJSON() ([]byte, error) {
1368	type NoMethod MemcacheParameters
1369	raw := NoMethod(*s)
1370	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1371}
1372
1373type Node struct {
1374	// Host: Output only. Hostname or IP address of the Memcached node used
1375	// by the clients to connect to the Memcached server on this node.
1376	Host string `json:"host,omitempty"`
1377
1378	// NodeId: Output only. Identifier of the Memcached node. The node id
1379	// does not include project or location like the Memcached instance
1380	// name.
1381	NodeId string `json:"nodeId,omitempty"`
1382
1383	// Parameters: User defined parameters currently applied to the node.
1384	Parameters *MemcacheParameters `json:"parameters,omitempty"`
1385
1386	// Port: Output only. The port number of the Memcached server on this
1387	// node.
1388	Port int64 `json:"port,omitempty"`
1389
1390	// State: Output only. Current state of the Memcached node.
1391	//
1392	// Possible values:
1393	//   "STATE_UNSPECIFIED" - Node state is not set.
1394	//   "CREATING" - Node is being created.
1395	//   "READY" - Node has been created and ready to be used.
1396	//   "DELETING" - Node is being deleted.
1397	//   "UPDATING" - Node is being updated.
1398	State string `json:"state,omitempty"`
1399
1400	// UpdateAvailable: Output only. Returns true if there is an update
1401	// waiting to be applied
1402	UpdateAvailable bool `json:"updateAvailable,omitempty"`
1403
1404	// Zone: Output only. Location (GCP Zone) for the Memcached node.
1405	Zone string `json:"zone,omitempty"`
1406
1407	// ForceSendFields is a list of field names (e.g. "Host") to
1408	// unconditionally include in API requests. By default, fields with
1409	// empty or default values are omitted from API requests. However, any
1410	// non-pointer, non-interface field appearing in ForceSendFields will be
1411	// sent to the server regardless of whether the field is empty or not.
1412	// This may be used to include empty fields in Patch requests.
1413	ForceSendFields []string `json:"-"`
1414
1415	// NullFields is a list of field names (e.g. "Host") to include in API
1416	// requests with the JSON null value. By default, fields with empty
1417	// values are omitted from API requests. However, any field with an
1418	// empty value appearing in NullFields will be sent to the server as
1419	// null. It is an error if a field in this list has a non-empty value.
1420	// This may be used to include null fields in Patch requests.
1421	NullFields []string `json:"-"`
1422}
1423
1424func (s *Node) MarshalJSON() ([]byte, error) {
1425	type NoMethod Node
1426	raw := NoMethod(*s)
1427	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1428}
1429
1430// NodeConfig: Configuration for a Memcached Node.
1431type NodeConfig struct {
1432	// CpuCount: Required. Number of cpus per Memcached node.
1433	CpuCount int64 `json:"cpuCount,omitempty"`
1434
1435	// MemorySizeMb: Required. Memory size in MiB for each Memcached node.
1436	MemorySizeMb int64 `json:"memorySizeMb,omitempty"`
1437
1438	// ForceSendFields is a list of field names (e.g. "CpuCount") to
1439	// unconditionally include in API requests. By default, fields with
1440	// empty or default values are omitted from API requests. However, any
1441	// non-pointer, non-interface field appearing in ForceSendFields will be
1442	// sent to the server regardless of whether the field is empty or not.
1443	// This may be used to include empty fields in Patch requests.
1444	ForceSendFields []string `json:"-"`
1445
1446	// NullFields is a list of field names (e.g. "CpuCount") to include in
1447	// API requests with the JSON null value. By default, fields with empty
1448	// values are omitted from API requests. However, any field with an
1449	// empty value appearing in NullFields will be sent to the server as
1450	// null. It is an error if a field in this list has a non-empty value.
1451	// This may be used to include null fields in Patch requests.
1452	NullFields []string `json:"-"`
1453}
1454
1455func (s *NodeConfig) MarshalJSON() ([]byte, error) {
1456	type NoMethod NodeConfig
1457	raw := NoMethod(*s)
1458	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1459}
1460
1461// Operation: This resource represents a long-running operation that is
1462// the result of a network API call.
1463type Operation struct {
1464	// Done: If the value is `false`, it means the operation is still in
1465	// progress. If `true`, the operation is completed, and either `error`
1466	// or `response` is available.
1467	Done bool `json:"done,omitempty"`
1468
1469	// Error: The error result of the operation in case of failure or
1470	// cancellation.
1471	Error *Status `json:"error,omitempty"`
1472
1473	// Metadata: Service-specific metadata associated with the operation. It
1474	// typically contains progress information and common metadata such as
1475	// create time. Some services might not provide such metadata. Any
1476	// method that returns a long-running operation should document the
1477	// metadata type, if any.
1478	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
1479
1480	// Name: The server-assigned name, which is only unique within the same
1481	// service that originally returns it. If you use the default HTTP
1482	// mapping, the `name` should be a resource name ending with
1483	// `operations/{unique_id}`.
1484	Name string `json:"name,omitempty"`
1485
1486	// Response: The normal response of the operation in case of success. If
1487	// the original method returns no data on success, such as `Delete`, the
1488	// response is `google.protobuf.Empty`. If the original method is
1489	// standard `Get`/`Create`/`Update`, the response should be the
1490	// resource. For other methods, the response should have the type
1491	// `XxxResponse`, where `Xxx` is the original method name. For example,
1492	// if the original method name is `TakeSnapshot()`, the inferred
1493	// response type is `TakeSnapshotResponse`.
1494	Response googleapi.RawMessage `json:"response,omitempty"`
1495
1496	// ServerResponse contains the HTTP response code and headers from the
1497	// server.
1498	googleapi.ServerResponse `json:"-"`
1499
1500	// ForceSendFields is a list of field names (e.g. "Done") to
1501	// unconditionally include in API requests. By default, fields with
1502	// empty or default values are omitted from API requests. However, any
1503	// non-pointer, non-interface field appearing in ForceSendFields will be
1504	// sent to the server regardless of whether the field is empty or not.
1505	// This may be used to include empty fields in Patch requests.
1506	ForceSendFields []string `json:"-"`
1507
1508	// NullFields is a list of field names (e.g. "Done") to include in API
1509	// requests with the JSON null value. By default, fields with empty
1510	// values are omitted from API requests. However, any field with an
1511	// empty value appearing in NullFields will be sent to the server as
1512	// null. It is an error if a field in this list has a non-empty value.
1513	// This may be used to include null fields in Patch requests.
1514	NullFields []string `json:"-"`
1515}
1516
1517func (s *Operation) MarshalJSON() ([]byte, error) {
1518	type NoMethod Operation
1519	raw := NoMethod(*s)
1520	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1521}
1522
1523// OperationMetadata: Represents the metadata of a long-running
1524// operation.
1525type OperationMetadata struct {
1526	// ApiVersion: Output only. API version used to start the operation.
1527	ApiVersion string `json:"apiVersion,omitempty"`
1528
1529	// CancelRequested: Output only. Identifies whether the user has
1530	// requested cancellation of the operation. Operations that have
1531	// successfully been cancelled have Operation.error value with a
1532	// google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.
1533	CancelRequested bool `json:"cancelRequested,omitempty"`
1534
1535	// CreateTime: Output only. Time when the operation was created.
1536	CreateTime string `json:"createTime,omitempty"`
1537
1538	// EndTime: Output only. Time when the operation finished running.
1539	EndTime string `json:"endTime,omitempty"`
1540
1541	// StatusDetail: Output only. Human-readable status of the operation, if
1542	// any.
1543	StatusDetail string `json:"statusDetail,omitempty"`
1544
1545	// Target: Output only. Server-defined resource path for the target of
1546	// the operation.
1547	Target string `json:"target,omitempty"`
1548
1549	// Verb: Output only. Name of the verb executed by the operation.
1550	Verb string `json:"verb,omitempty"`
1551
1552	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
1553	// unconditionally include in API requests. By default, fields with
1554	// empty or default values are omitted from API requests. However, any
1555	// non-pointer, non-interface field appearing in ForceSendFields will be
1556	// sent to the server regardless of whether the field is empty or not.
1557	// This may be used to include empty fields in Patch requests.
1558	ForceSendFields []string `json:"-"`
1559
1560	// NullFields is a list of field names (e.g. "ApiVersion") to include in
1561	// API requests with the JSON null value. By default, fields with empty
1562	// values are omitted from API requests. However, any field with an
1563	// empty value appearing in NullFields will be sent to the server as
1564	// null. It is an error if a field in this list has a non-empty value.
1565	// This may be used to include null fields in Patch requests.
1566	NullFields []string `json:"-"`
1567}
1568
1569func (s *OperationMetadata) MarshalJSON() ([]byte, error) {
1570	type NoMethod OperationMetadata
1571	raw := NoMethod(*s)
1572	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1573}
1574
1575// Schedule: Configure the schedule.
1576type Schedule struct {
1577	// Day: Allows to define schedule that runs specified day of the week.
1578	//
1579	// Possible values:
1580	//   "DAY_OF_WEEK_UNSPECIFIED" - The day of the week is unspecified.
1581	//   "MONDAY" - Monday
1582	//   "TUESDAY" - Tuesday
1583	//   "WEDNESDAY" - Wednesday
1584	//   "THURSDAY" - Thursday
1585	//   "FRIDAY" - Friday
1586	//   "SATURDAY" - Saturday
1587	//   "SUNDAY" - Sunday
1588	Day string `json:"day,omitempty"`
1589
1590	// Duration: Output only. Duration of the time window, set by service
1591	// producer.
1592	Duration string `json:"duration,omitempty"`
1593
1594	// StartTime: Time within the window to start the operations.
1595	StartTime *TimeOfDay `json:"startTime,omitempty"`
1596
1597	// ForceSendFields is a list of field names (e.g. "Day") to
1598	// unconditionally include in API requests. By default, fields with
1599	// empty or default values are omitted from API requests. However, any
1600	// non-pointer, non-interface field appearing in ForceSendFields will be
1601	// sent to the server regardless of whether the field is empty or not.
1602	// This may be used to include empty fields in Patch requests.
1603	ForceSendFields []string `json:"-"`
1604
1605	// NullFields is a list of field names (e.g. "Day") to include in API
1606	// requests with the JSON null value. By default, fields with empty
1607	// values are omitted from API requests. However, any field with an
1608	// empty value appearing in NullFields will be sent to the server as
1609	// null. It is an error if a field in this list has a non-empty value.
1610	// This may be used to include null fields in Patch requests.
1611	NullFields []string `json:"-"`
1612}
1613
1614func (s *Schedule) MarshalJSON() ([]byte, error) {
1615	type NoMethod Schedule
1616	raw := NoMethod(*s)
1617	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1618}
1619
1620// Status: The `Status` type defines a logical error model that is
1621// suitable for different programming environments, including REST APIs
1622// and RPC APIs. It is used by gRPC (https://github.com/grpc). Each
1623// `Status` message contains three pieces of data: error code, error
1624// message, and error details. You can find out more about this error
1625// model and how to work with it in the API Design Guide
1626// (https://cloud.google.com/apis/design/errors).
1627type Status struct {
1628	// Code: The status code, which should be an enum value of
1629	// google.rpc.Code.
1630	Code int64 `json:"code,omitempty"`
1631
1632	// Details: A list of messages that carry the error details. There is a
1633	// common set of message types for APIs to use.
1634	Details []googleapi.RawMessage `json:"details,omitempty"`
1635
1636	// Message: A developer-facing error message, which should be in
1637	// English. Any user-facing error message should be localized and sent
1638	// in the google.rpc.Status.details field, or localized by the client.
1639	Message string `json:"message,omitempty"`
1640
1641	// ForceSendFields is a list of field names (e.g. "Code") to
1642	// unconditionally include in API requests. By default, fields with
1643	// empty or default values are omitted from API requests. However, any
1644	// non-pointer, non-interface field appearing in ForceSendFields will be
1645	// sent to the server regardless of whether the field is empty or not.
1646	// This may be used to include empty fields in Patch requests.
1647	ForceSendFields []string `json:"-"`
1648
1649	// NullFields is a list of field names (e.g. "Code") to include in API
1650	// requests with the JSON null value. By default, fields with empty
1651	// values are omitted from API requests. However, any field with an
1652	// empty value appearing in NullFields will be sent to the server as
1653	// null. It is an error if a field in this list has a non-empty value.
1654	// This may be used to include null fields in Patch requests.
1655	NullFields []string `json:"-"`
1656}
1657
1658func (s *Status) MarshalJSON() ([]byte, error) {
1659	type NoMethod Status
1660	raw := NoMethod(*s)
1661	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1662}
1663
1664// TimeOfDay: Represents a time of day. The date and time zone are
1665// either not significant or are specified elsewhere. An API may choose
1666// to allow leap seconds. Related types are google.type.Date and
1667// `google.protobuf.Timestamp`.
1668type TimeOfDay struct {
1669	// Hours: Hours of day in 24 hour format. Should be from 0 to 23. An API
1670	// may choose to allow the value "24:00:00" for scenarios like business
1671	// closing time.
1672	Hours int64 `json:"hours,omitempty"`
1673
1674	// Minutes: Minutes of hour of day. Must be from 0 to 59.
1675	Minutes int64 `json:"minutes,omitempty"`
1676
1677	// Nanos: Fractions of seconds in nanoseconds. Must be from 0 to
1678	// 999,999,999.
1679	Nanos int64 `json:"nanos,omitempty"`
1680
1681	// Seconds: Seconds of minutes of the time. Must normally be from 0 to
1682	// 59. An API may allow the value 60 if it allows leap-seconds.
1683	Seconds int64 `json:"seconds,omitempty"`
1684
1685	// ForceSendFields is a list of field names (e.g. "Hours") to
1686	// unconditionally include in API requests. By default, fields with
1687	// empty or default values are omitted from API requests. However, any
1688	// non-pointer, non-interface field appearing in ForceSendFields will be
1689	// sent to the server regardless of whether the field is empty or not.
1690	// This may be used to include empty fields in Patch requests.
1691	ForceSendFields []string `json:"-"`
1692
1693	// NullFields is a list of field names (e.g. "Hours") to include in API
1694	// requests with the JSON null value. By default, fields with empty
1695	// values are omitted from API requests. However, any field with an
1696	// empty value appearing in NullFields will be sent to the server as
1697	// null. It is an error if a field in this list has a non-empty value.
1698	// This may be used to include null fields in Patch requests.
1699	NullFields []string `json:"-"`
1700}
1701
1702func (s *TimeOfDay) MarshalJSON() ([]byte, error) {
1703	type NoMethod TimeOfDay
1704	raw := NoMethod(*s)
1705	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1706}
1707
1708// UpdateParametersRequest: Request for UpdateParameters.
1709type UpdateParametersRequest struct {
1710	// Parameters: The parameters to apply to the instance.
1711	Parameters *MemcacheParameters `json:"parameters,omitempty"`
1712
1713	// UpdateMask: Required. Mask of fields to update.
1714	UpdateMask string `json:"updateMask,omitempty"`
1715
1716	// ForceSendFields is a list of field names (e.g. "Parameters") to
1717	// unconditionally include in API requests. By default, fields with
1718	// empty or default values are omitted from API requests. However, any
1719	// non-pointer, non-interface field appearing in ForceSendFields will be
1720	// sent to the server regardless of whether the field is empty or not.
1721	// This may be used to include empty fields in Patch requests.
1722	ForceSendFields []string `json:"-"`
1723
1724	// NullFields is a list of field names (e.g. "Parameters") to include in
1725	// API requests with the JSON null value. By default, fields with empty
1726	// values are omitted from API requests. However, any field with an
1727	// empty value appearing in NullFields will be sent to the server as
1728	// null. It is an error if a field in this list has a non-empty value.
1729	// This may be used to include null fields in Patch requests.
1730	NullFields []string `json:"-"`
1731}
1732
1733func (s *UpdateParametersRequest) MarshalJSON() ([]byte, error) {
1734	type NoMethod UpdateParametersRequest
1735	raw := NoMethod(*s)
1736	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1737}
1738
1739// UpdatePolicy: Maintenance policy applicable to instance updates.
1740type UpdatePolicy struct {
1741	// Channel: Optional. Relative scheduling channel applied to resource.
1742	//
1743	// Possible values:
1744	//   "UPDATE_CHANNEL_UNSPECIFIED" - Unspecified channel.
1745	//   "EARLIER" - Early channel within a customer project.
1746	//   "LATER" - Later channel within a customer project.
1747	Channel string `json:"channel,omitempty"`
1748
1749	// DenyMaintenancePeriods: Deny Maintenance Period that is applied to
1750	// resource to indicate when maintenance is forbidden. User can specify
1751	// zero or more non-overlapping deny periods. Maximum number of
1752	// deny_maintenance_periods expected is one.
1753	DenyMaintenancePeriods []*DenyMaintenancePeriod `json:"denyMaintenancePeriods,omitempty"`
1754
1755	// Window: Optional. Maintenance window that is applied to resources
1756	// covered by this policy.
1757	Window *MaintenanceWindow `json:"window,omitempty"`
1758
1759	// ForceSendFields is a list of field names (e.g. "Channel") to
1760	// unconditionally include in API requests. By default, fields with
1761	// empty or default values are omitted from API requests. However, any
1762	// non-pointer, non-interface field appearing in ForceSendFields will be
1763	// sent to the server regardless of whether the field is empty or not.
1764	// This may be used to include empty fields in Patch requests.
1765	ForceSendFields []string `json:"-"`
1766
1767	// NullFields is a list of field names (e.g. "Channel") to include in
1768	// API requests with the JSON null value. By default, fields with empty
1769	// values are omitted from API requests. However, any field with an
1770	// empty value appearing in NullFields will be sent to the server as
1771	// null. It is an error if a field in this list has a non-empty value.
1772	// This may be used to include null fields in Patch requests.
1773	NullFields []string `json:"-"`
1774}
1775
1776func (s *UpdatePolicy) MarshalJSON() ([]byte, error) {
1777	type NoMethod UpdatePolicy
1778	raw := NoMethod(*s)
1779	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1780}
1781
1782// WeeklyCycle: Time window specified for weekly operations.
1783type WeeklyCycle struct {
1784	// Schedule: User can specify multiple windows in a week. Minimum of 1
1785	// window.
1786	Schedule []*Schedule `json:"schedule,omitempty"`
1787
1788	// ForceSendFields is a list of field names (e.g. "Schedule") to
1789	// unconditionally include in API requests. By default, fields with
1790	// empty or default values are omitted from API requests. However, any
1791	// non-pointer, non-interface field appearing in ForceSendFields will be
1792	// sent to the server regardless of whether the field is empty or not.
1793	// This may be used to include empty fields in Patch requests.
1794	ForceSendFields []string `json:"-"`
1795
1796	// NullFields is a list of field names (e.g. "Schedule") to include in
1797	// API requests with the JSON null value. By default, fields with empty
1798	// values are omitted from API requests. However, any field with an
1799	// empty value appearing in NullFields will be sent to the server as
1800	// null. It is an error if a field in this list has a non-empty value.
1801	// This may be used to include null fields in Patch requests.
1802	NullFields []string `json:"-"`
1803}
1804
1805func (s *WeeklyCycle) MarshalJSON() ([]byte, error) {
1806	type NoMethod WeeklyCycle
1807	raw := NoMethod(*s)
1808	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1809}
1810
1811type ZoneMetadata struct {
1812}
1813
1814// method id "memcache.projects.locations.get":
1815
1816type ProjectsLocationsGetCall struct {
1817	s            *Service
1818	name         string
1819	urlParams_   gensupport.URLParams
1820	ifNoneMatch_ string
1821	ctx_         context.Context
1822	header_      http.Header
1823}
1824
1825// Get: Gets information about a location.
1826//
1827// - name: Resource name for the location.
1828func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall {
1829	c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
1830	c.name = name
1831	return c
1832}
1833
1834// Fields allows partial responses to be retrieved. See
1835// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
1836// for more information.
1837func (c *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall {
1838	c.urlParams_.Set("fields", googleapi.CombineFields(s))
1839	return c
1840}
1841
1842// IfNoneMatch sets the optional parameter which makes the operation
1843// fail if the object's ETag matches the given value. This is useful for
1844// getting updates only after the object has changed since the last
1845// request. Use googleapi.IsNotModified to check whether the response
1846// error from Do is the result of In-None-Match.
1847func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall {
1848	c.ifNoneMatch_ = entityTag
1849	return c
1850}
1851
1852// Context sets the context to be used in this call's Do method. Any
1853// pending HTTP request will be aborted if the provided context is
1854// canceled.
1855func (c *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall {
1856	c.ctx_ = ctx
1857	return c
1858}
1859
1860// Header returns an http.Header that can be modified by the caller to
1861// add HTTP headers to the request.
1862func (c *ProjectsLocationsGetCall) Header() http.Header {
1863	if c.header_ == nil {
1864		c.header_ = make(http.Header)
1865	}
1866	return c.header_
1867}
1868
1869func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) {
1870	reqHeaders := make(http.Header)
1871	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
1872	for k, v := range c.header_ {
1873		reqHeaders[k] = v
1874	}
1875	reqHeaders.Set("User-Agent", c.s.userAgent())
1876	if c.ifNoneMatch_ != "" {
1877		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
1878	}
1879	var body io.Reader = nil
1880	c.urlParams_.Set("alt", alt)
1881	c.urlParams_.Set("prettyPrint", "false")
1882	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}")
1883	urls += "?" + c.urlParams_.Encode()
1884	req, err := http.NewRequest("GET", urls, body)
1885	if err != nil {
1886		return nil, err
1887	}
1888	req.Header = reqHeaders
1889	googleapi.Expand(req.URL, map[string]string{
1890		"name": c.name,
1891	})
1892	return gensupport.SendRequest(c.ctx_, c.s.client, req)
1893}
1894
1895// Do executes the "memcache.projects.locations.get" call.
1896// Exactly one of *Location or error will be non-nil. Any non-2xx status
1897// code is an error. Response headers are in either
1898// *Location.ServerResponse.Header or (if a response was returned at
1899// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
1900// to check whether the returned error was because
1901// http.StatusNotModified was returned.
1902func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) {
1903	gensupport.SetOptions(c.urlParams_, opts...)
1904	res, err := c.doRequest("json")
1905	if res != nil && res.StatusCode == http.StatusNotModified {
1906		if res.Body != nil {
1907			res.Body.Close()
1908		}
1909		return nil, &googleapi.Error{
1910			Code:   res.StatusCode,
1911			Header: res.Header,
1912		}
1913	}
1914	if err != nil {
1915		return nil, err
1916	}
1917	defer googleapi.CloseBody(res)
1918	if err := googleapi.CheckResponse(res); err != nil {
1919		return nil, err
1920	}
1921	ret := &Location{
1922		ServerResponse: googleapi.ServerResponse{
1923			Header:         res.Header,
1924			HTTPStatusCode: res.StatusCode,
1925		},
1926	}
1927	target := &ret
1928	if err := gensupport.DecodeResponse(target, res); err != nil {
1929		return nil, err
1930	}
1931	return ret, nil
1932	// {
1933	//   "description": "Gets information about a location.",
1934	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}",
1935	//   "httpMethod": "GET",
1936	//   "id": "memcache.projects.locations.get",
1937	//   "parameterOrder": [
1938	//     "name"
1939	//   ],
1940	//   "parameters": {
1941	//     "name": {
1942	//       "description": "Resource name for the location.",
1943	//       "location": "path",
1944	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
1945	//       "required": true,
1946	//       "type": "string"
1947	//     }
1948	//   },
1949	//   "path": "v1beta2/{+name}",
1950	//   "response": {
1951	//     "$ref": "Location"
1952	//   },
1953	//   "scopes": [
1954	//     "https://www.googleapis.com/auth/cloud-platform"
1955	//   ]
1956	// }
1957
1958}
1959
1960// method id "memcache.projects.locations.list":
1961
1962type ProjectsLocationsListCall struct {
1963	s            *Service
1964	name         string
1965	urlParams_   gensupport.URLParams
1966	ifNoneMatch_ string
1967	ctx_         context.Context
1968	header_      http.Header
1969}
1970
1971// List: Lists information about the supported locations for this
1972// service.
1973//
1974// - name: The resource that owns the locations collection, if
1975//   applicable.
1976func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall {
1977	c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
1978	c.name = name
1979	return c
1980}
1981
1982// Filter sets the optional parameter "filter": A filter to narrow down
1983// results to a preferred subset. The filtering language accepts strings
1984// like "displayName=tokyo", and is documented in more detail in AIP-160
1985// (https://google.aip.dev/160).
1986func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall {
1987	c.urlParams_.Set("filter", filter)
1988	return c
1989}
1990
1991// PageSize sets the optional parameter "pageSize": The maximum number
1992// of results to return. If not set, the service selects a default.
1993func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall {
1994	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
1995	return c
1996}
1997
1998// PageToken sets the optional parameter "pageToken": A page token
1999// received from the `next_page_token` field in the response. Send that
2000// page token to receive the subsequent page.
2001func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall {
2002	c.urlParams_.Set("pageToken", pageToken)
2003	return c
2004}
2005
2006// Fields allows partial responses to be retrieved. See
2007// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2008// for more information.
2009func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall {
2010	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2011	return c
2012}
2013
2014// IfNoneMatch sets the optional parameter which makes the operation
2015// fail if the object's ETag matches the given value. This is useful for
2016// getting updates only after the object has changed since the last
2017// request. Use googleapi.IsNotModified to check whether the response
2018// error from Do is the result of In-None-Match.
2019func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall {
2020	c.ifNoneMatch_ = entityTag
2021	return c
2022}
2023
2024// Context sets the context to be used in this call's Do method. Any
2025// pending HTTP request will be aborted if the provided context is
2026// canceled.
2027func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall {
2028	c.ctx_ = ctx
2029	return c
2030}
2031
2032// Header returns an http.Header that can be modified by the caller to
2033// add HTTP headers to the request.
2034func (c *ProjectsLocationsListCall) Header() http.Header {
2035	if c.header_ == nil {
2036		c.header_ = make(http.Header)
2037	}
2038	return c.header_
2039}
2040
2041func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) {
2042	reqHeaders := make(http.Header)
2043	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2044	for k, v := range c.header_ {
2045		reqHeaders[k] = v
2046	}
2047	reqHeaders.Set("User-Agent", c.s.userAgent())
2048	if c.ifNoneMatch_ != "" {
2049		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
2050	}
2051	var body io.Reader = nil
2052	c.urlParams_.Set("alt", alt)
2053	c.urlParams_.Set("prettyPrint", "false")
2054	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}/locations")
2055	urls += "?" + c.urlParams_.Encode()
2056	req, err := http.NewRequest("GET", urls, body)
2057	if err != nil {
2058		return nil, err
2059	}
2060	req.Header = reqHeaders
2061	googleapi.Expand(req.URL, map[string]string{
2062		"name": c.name,
2063	})
2064	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2065}
2066
2067// Do executes the "memcache.projects.locations.list" call.
2068// Exactly one of *ListLocationsResponse or error will be non-nil. Any
2069// non-2xx status code is an error. Response headers are in either
2070// *ListLocationsResponse.ServerResponse.Header or (if a response was
2071// returned at all) in error.(*googleapi.Error).Header. Use
2072// googleapi.IsNotModified to check whether the returned error was
2073// because http.StatusNotModified was returned.
2074func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) {
2075	gensupport.SetOptions(c.urlParams_, opts...)
2076	res, err := c.doRequest("json")
2077	if res != nil && res.StatusCode == http.StatusNotModified {
2078		if res.Body != nil {
2079			res.Body.Close()
2080		}
2081		return nil, &googleapi.Error{
2082			Code:   res.StatusCode,
2083			Header: res.Header,
2084		}
2085	}
2086	if err != nil {
2087		return nil, err
2088	}
2089	defer googleapi.CloseBody(res)
2090	if err := googleapi.CheckResponse(res); err != nil {
2091		return nil, err
2092	}
2093	ret := &ListLocationsResponse{
2094		ServerResponse: googleapi.ServerResponse{
2095			Header:         res.Header,
2096			HTTPStatusCode: res.StatusCode,
2097		},
2098	}
2099	target := &ret
2100	if err := gensupport.DecodeResponse(target, res); err != nil {
2101		return nil, err
2102	}
2103	return ret, nil
2104	// {
2105	//   "description": "Lists information about the supported locations for this service.",
2106	//   "flatPath": "v1beta2/projects/{projectsId}/locations",
2107	//   "httpMethod": "GET",
2108	//   "id": "memcache.projects.locations.list",
2109	//   "parameterOrder": [
2110	//     "name"
2111	//   ],
2112	//   "parameters": {
2113	//     "filter": {
2114	//       "description": "A filter to narrow down results to a preferred subset. The filtering language accepts strings like \"displayName=tokyo\", and is documented in more detail in [AIP-160](https://google.aip.dev/160).",
2115	//       "location": "query",
2116	//       "type": "string"
2117	//     },
2118	//     "name": {
2119	//       "description": "The resource that owns the locations collection, if applicable.",
2120	//       "location": "path",
2121	//       "pattern": "^projects/[^/]+$",
2122	//       "required": true,
2123	//       "type": "string"
2124	//     },
2125	//     "pageSize": {
2126	//       "description": "The maximum number of results to return. If not set, the service selects a default.",
2127	//       "format": "int32",
2128	//       "location": "query",
2129	//       "type": "integer"
2130	//     },
2131	//     "pageToken": {
2132	//       "description": "A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.",
2133	//       "location": "query",
2134	//       "type": "string"
2135	//     }
2136	//   },
2137	//   "path": "v1beta2/{+name}/locations",
2138	//   "response": {
2139	//     "$ref": "ListLocationsResponse"
2140	//   },
2141	//   "scopes": [
2142	//     "https://www.googleapis.com/auth/cloud-platform"
2143	//   ]
2144	// }
2145
2146}
2147
2148// Pages invokes f for each page of results.
2149// A non-nil error returned from f will halt the iteration.
2150// The provided context supersedes any context provided to the Context method.
2151func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) error) error {
2152	c.ctx_ = ctx
2153	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
2154	for {
2155		x, err := c.Do()
2156		if err != nil {
2157			return err
2158		}
2159		if err := f(x); err != nil {
2160			return err
2161		}
2162		if x.NextPageToken == "" {
2163			return nil
2164		}
2165		c.PageToken(x.NextPageToken)
2166	}
2167}
2168
2169// method id "memcache.projects.locations.instances.applyParameters":
2170
2171type ProjectsLocationsInstancesApplyParametersCall struct {
2172	s                      *Service
2173	name                   string
2174	applyparametersrequest *ApplyParametersRequest
2175	urlParams_             gensupport.URLParams
2176	ctx_                   context.Context
2177	header_                http.Header
2178}
2179
2180// ApplyParameters: `ApplyParameters` restarts the set of specified
2181// nodes in order to update them to the current set of parameters for
2182// the Memcached Instance.
2183//
2184// - name: Resource name of the Memcached instance for which parameter
2185//   group updates should be applied.
2186func (r *ProjectsLocationsInstancesService) ApplyParameters(name string, applyparametersrequest *ApplyParametersRequest) *ProjectsLocationsInstancesApplyParametersCall {
2187	c := &ProjectsLocationsInstancesApplyParametersCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2188	c.name = name
2189	c.applyparametersrequest = applyparametersrequest
2190	return c
2191}
2192
2193// Fields allows partial responses to be retrieved. See
2194// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2195// for more information.
2196func (c *ProjectsLocationsInstancesApplyParametersCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesApplyParametersCall {
2197	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2198	return c
2199}
2200
2201// Context sets the context to be used in this call's Do method. Any
2202// pending HTTP request will be aborted if the provided context is
2203// canceled.
2204func (c *ProjectsLocationsInstancesApplyParametersCall) Context(ctx context.Context) *ProjectsLocationsInstancesApplyParametersCall {
2205	c.ctx_ = ctx
2206	return c
2207}
2208
2209// Header returns an http.Header that can be modified by the caller to
2210// add HTTP headers to the request.
2211func (c *ProjectsLocationsInstancesApplyParametersCall) Header() http.Header {
2212	if c.header_ == nil {
2213		c.header_ = make(http.Header)
2214	}
2215	return c.header_
2216}
2217
2218func (c *ProjectsLocationsInstancesApplyParametersCall) doRequest(alt string) (*http.Response, error) {
2219	reqHeaders := make(http.Header)
2220	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2221	for k, v := range c.header_ {
2222		reqHeaders[k] = v
2223	}
2224	reqHeaders.Set("User-Agent", c.s.userAgent())
2225	var body io.Reader = nil
2226	body, err := googleapi.WithoutDataWrapper.JSONReader(c.applyparametersrequest)
2227	if err != nil {
2228		return nil, err
2229	}
2230	reqHeaders.Set("Content-Type", "application/json")
2231	c.urlParams_.Set("alt", alt)
2232	c.urlParams_.Set("prettyPrint", "false")
2233	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}:applyParameters")
2234	urls += "?" + c.urlParams_.Encode()
2235	req, err := http.NewRequest("POST", urls, body)
2236	if err != nil {
2237		return nil, err
2238	}
2239	req.Header = reqHeaders
2240	googleapi.Expand(req.URL, map[string]string{
2241		"name": c.name,
2242	})
2243	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2244}
2245
2246// Do executes the "memcache.projects.locations.instances.applyParameters" call.
2247// Exactly one of *Operation or error will be non-nil. Any non-2xx
2248// status code is an error. Response headers are in either
2249// *Operation.ServerResponse.Header or (if a response was returned at
2250// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2251// to check whether the returned error was because
2252// http.StatusNotModified was returned.
2253func (c *ProjectsLocationsInstancesApplyParametersCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
2254	gensupport.SetOptions(c.urlParams_, opts...)
2255	res, err := c.doRequest("json")
2256	if res != nil && res.StatusCode == http.StatusNotModified {
2257		if res.Body != nil {
2258			res.Body.Close()
2259		}
2260		return nil, &googleapi.Error{
2261			Code:   res.StatusCode,
2262			Header: res.Header,
2263		}
2264	}
2265	if err != nil {
2266		return nil, err
2267	}
2268	defer googleapi.CloseBody(res)
2269	if err := googleapi.CheckResponse(res); err != nil {
2270		return nil, err
2271	}
2272	ret := &Operation{
2273		ServerResponse: googleapi.ServerResponse{
2274			Header:         res.Header,
2275			HTTPStatusCode: res.StatusCode,
2276		},
2277	}
2278	target := &ret
2279	if err := gensupport.DecodeResponse(target, res); err != nil {
2280		return nil, err
2281	}
2282	return ret, nil
2283	// {
2284	//   "description": "`ApplyParameters` restarts the set of specified nodes in order to update them to the current set of parameters for the Memcached Instance.",
2285	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:applyParameters",
2286	//   "httpMethod": "POST",
2287	//   "id": "memcache.projects.locations.instances.applyParameters",
2288	//   "parameterOrder": [
2289	//     "name"
2290	//   ],
2291	//   "parameters": {
2292	//     "name": {
2293	//       "description": "Required. Resource name of the Memcached instance for which parameter group updates should be applied.",
2294	//       "location": "path",
2295	//       "pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
2296	//       "required": true,
2297	//       "type": "string"
2298	//     }
2299	//   },
2300	//   "path": "v1beta2/{+name}:applyParameters",
2301	//   "request": {
2302	//     "$ref": "ApplyParametersRequest"
2303	//   },
2304	//   "response": {
2305	//     "$ref": "Operation"
2306	//   },
2307	//   "scopes": [
2308	//     "https://www.googleapis.com/auth/cloud-platform"
2309	//   ]
2310	// }
2311
2312}
2313
2314// method id "memcache.projects.locations.instances.applySoftwareUpdate":
2315
2316type ProjectsLocationsInstancesApplySoftwareUpdateCall struct {
2317	s                          *Service
2318	instance                   string
2319	applysoftwareupdaterequest *ApplySoftwareUpdateRequest
2320	urlParams_                 gensupport.URLParams
2321	ctx_                       context.Context
2322	header_                    http.Header
2323}
2324
2325// ApplySoftwareUpdate: Updates software on the selected nodes of the
2326// Instance.
2327//
2328// - instance: Resource name of the Memcached instance for which
2329//   software update should be applied.
2330func (r *ProjectsLocationsInstancesService) ApplySoftwareUpdate(instance string, applysoftwareupdaterequest *ApplySoftwareUpdateRequest) *ProjectsLocationsInstancesApplySoftwareUpdateCall {
2331	c := &ProjectsLocationsInstancesApplySoftwareUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2332	c.instance = instance
2333	c.applysoftwareupdaterequest = applysoftwareupdaterequest
2334	return c
2335}
2336
2337// Fields allows partial responses to be retrieved. See
2338// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2339// for more information.
2340func (c *ProjectsLocationsInstancesApplySoftwareUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesApplySoftwareUpdateCall {
2341	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2342	return c
2343}
2344
2345// Context sets the context to be used in this call's Do method. Any
2346// pending HTTP request will be aborted if the provided context is
2347// canceled.
2348func (c *ProjectsLocationsInstancesApplySoftwareUpdateCall) Context(ctx context.Context) *ProjectsLocationsInstancesApplySoftwareUpdateCall {
2349	c.ctx_ = ctx
2350	return c
2351}
2352
2353// Header returns an http.Header that can be modified by the caller to
2354// add HTTP headers to the request.
2355func (c *ProjectsLocationsInstancesApplySoftwareUpdateCall) Header() http.Header {
2356	if c.header_ == nil {
2357		c.header_ = make(http.Header)
2358	}
2359	return c.header_
2360}
2361
2362func (c *ProjectsLocationsInstancesApplySoftwareUpdateCall) doRequest(alt string) (*http.Response, error) {
2363	reqHeaders := make(http.Header)
2364	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2365	for k, v := range c.header_ {
2366		reqHeaders[k] = v
2367	}
2368	reqHeaders.Set("User-Agent", c.s.userAgent())
2369	var body io.Reader = nil
2370	body, err := googleapi.WithoutDataWrapper.JSONReader(c.applysoftwareupdaterequest)
2371	if err != nil {
2372		return nil, err
2373	}
2374	reqHeaders.Set("Content-Type", "application/json")
2375	c.urlParams_.Set("alt", alt)
2376	c.urlParams_.Set("prettyPrint", "false")
2377	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+instance}:applySoftwareUpdate")
2378	urls += "?" + c.urlParams_.Encode()
2379	req, err := http.NewRequest("POST", urls, body)
2380	if err != nil {
2381		return nil, err
2382	}
2383	req.Header = reqHeaders
2384	googleapi.Expand(req.URL, map[string]string{
2385		"instance": c.instance,
2386	})
2387	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2388}
2389
2390// Do executes the "memcache.projects.locations.instances.applySoftwareUpdate" call.
2391// Exactly one of *Operation or error will be non-nil. Any non-2xx
2392// status code is an error. Response headers are in either
2393// *Operation.ServerResponse.Header or (if a response was returned at
2394// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2395// to check whether the returned error was because
2396// http.StatusNotModified was returned.
2397func (c *ProjectsLocationsInstancesApplySoftwareUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
2398	gensupport.SetOptions(c.urlParams_, opts...)
2399	res, err := c.doRequest("json")
2400	if res != nil && res.StatusCode == http.StatusNotModified {
2401		if res.Body != nil {
2402			res.Body.Close()
2403		}
2404		return nil, &googleapi.Error{
2405			Code:   res.StatusCode,
2406			Header: res.Header,
2407		}
2408	}
2409	if err != nil {
2410		return nil, err
2411	}
2412	defer googleapi.CloseBody(res)
2413	if err := googleapi.CheckResponse(res); err != nil {
2414		return nil, err
2415	}
2416	ret := &Operation{
2417		ServerResponse: googleapi.ServerResponse{
2418			Header:         res.Header,
2419			HTTPStatusCode: res.StatusCode,
2420		},
2421	}
2422	target := &ret
2423	if err := gensupport.DecodeResponse(target, res); err != nil {
2424		return nil, err
2425	}
2426	return ret, nil
2427	// {
2428	//   "description": "Updates software on the selected nodes of the Instance.",
2429	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:applySoftwareUpdate",
2430	//   "httpMethod": "POST",
2431	//   "id": "memcache.projects.locations.instances.applySoftwareUpdate",
2432	//   "parameterOrder": [
2433	//     "instance"
2434	//   ],
2435	//   "parameters": {
2436	//     "instance": {
2437	//       "description": "Required. Resource name of the Memcached instance for which software update should be applied.",
2438	//       "location": "path",
2439	//       "pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
2440	//       "required": true,
2441	//       "type": "string"
2442	//     }
2443	//   },
2444	//   "path": "v1beta2/{+instance}:applySoftwareUpdate",
2445	//   "request": {
2446	//     "$ref": "ApplySoftwareUpdateRequest"
2447	//   },
2448	//   "response": {
2449	//     "$ref": "Operation"
2450	//   },
2451	//   "scopes": [
2452	//     "https://www.googleapis.com/auth/cloud-platform"
2453	//   ]
2454	// }
2455
2456}
2457
2458// method id "memcache.projects.locations.instances.create":
2459
2460type ProjectsLocationsInstancesCreateCall struct {
2461	s          *Service
2462	parent     string
2463	instance   *Instance
2464	urlParams_ gensupport.URLParams
2465	ctx_       context.Context
2466	header_    http.Header
2467}
2468
2469// Create: Creates a new Instance in a given location.
2470//
2471// - parent: The resource name of the instance location using the form:
2472//   `projects/{project_id}/locations/{location_id}` where `location_id`
2473//   refers to a GCP region.
2474func (r *ProjectsLocationsInstancesService) Create(parent string, instance *Instance) *ProjectsLocationsInstancesCreateCall {
2475	c := &ProjectsLocationsInstancesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2476	c.parent = parent
2477	c.instance = instance
2478	return c
2479}
2480
2481// InstanceId sets the optional parameter "instanceId": Required. The
2482// logical name of the Memcached instance in the user project with the
2483// following restrictions: * Must contain only lowercase letters,
2484// numbers, and hyphens. * Must start with a letter. * Must be between
2485// 1-40 characters. * Must end with a number or a letter. * Must be
2486// unique within the user project / location. If any of the above are
2487// not met, the API raises an invalid argument error.
2488func (c *ProjectsLocationsInstancesCreateCall) InstanceId(instanceId string) *ProjectsLocationsInstancesCreateCall {
2489	c.urlParams_.Set("instanceId", instanceId)
2490	return c
2491}
2492
2493// Fields allows partial responses to be retrieved. See
2494// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2495// for more information.
2496func (c *ProjectsLocationsInstancesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesCreateCall {
2497	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2498	return c
2499}
2500
2501// Context sets the context to be used in this call's Do method. Any
2502// pending HTTP request will be aborted if the provided context is
2503// canceled.
2504func (c *ProjectsLocationsInstancesCreateCall) Context(ctx context.Context) *ProjectsLocationsInstancesCreateCall {
2505	c.ctx_ = ctx
2506	return c
2507}
2508
2509// Header returns an http.Header that can be modified by the caller to
2510// add HTTP headers to the request.
2511func (c *ProjectsLocationsInstancesCreateCall) Header() http.Header {
2512	if c.header_ == nil {
2513		c.header_ = make(http.Header)
2514	}
2515	return c.header_
2516}
2517
2518func (c *ProjectsLocationsInstancesCreateCall) doRequest(alt string) (*http.Response, error) {
2519	reqHeaders := make(http.Header)
2520	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2521	for k, v := range c.header_ {
2522		reqHeaders[k] = v
2523	}
2524	reqHeaders.Set("User-Agent", c.s.userAgent())
2525	var body io.Reader = nil
2526	body, err := googleapi.WithoutDataWrapper.JSONReader(c.instance)
2527	if err != nil {
2528		return nil, err
2529	}
2530	reqHeaders.Set("Content-Type", "application/json")
2531	c.urlParams_.Set("alt", alt)
2532	c.urlParams_.Set("prettyPrint", "false")
2533	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+parent}/instances")
2534	urls += "?" + c.urlParams_.Encode()
2535	req, err := http.NewRequest("POST", urls, body)
2536	if err != nil {
2537		return nil, err
2538	}
2539	req.Header = reqHeaders
2540	googleapi.Expand(req.URL, map[string]string{
2541		"parent": c.parent,
2542	})
2543	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2544}
2545
2546// Do executes the "memcache.projects.locations.instances.create" call.
2547// Exactly one of *Operation or error will be non-nil. Any non-2xx
2548// status code is an error. Response headers are in either
2549// *Operation.ServerResponse.Header or (if a response was returned at
2550// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2551// to check whether the returned error was because
2552// http.StatusNotModified was returned.
2553func (c *ProjectsLocationsInstancesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
2554	gensupport.SetOptions(c.urlParams_, opts...)
2555	res, err := c.doRequest("json")
2556	if res != nil && res.StatusCode == http.StatusNotModified {
2557		if res.Body != nil {
2558			res.Body.Close()
2559		}
2560		return nil, &googleapi.Error{
2561			Code:   res.StatusCode,
2562			Header: res.Header,
2563		}
2564	}
2565	if err != nil {
2566		return nil, err
2567	}
2568	defer googleapi.CloseBody(res)
2569	if err := googleapi.CheckResponse(res); err != nil {
2570		return nil, err
2571	}
2572	ret := &Operation{
2573		ServerResponse: googleapi.ServerResponse{
2574			Header:         res.Header,
2575			HTTPStatusCode: res.StatusCode,
2576		},
2577	}
2578	target := &ret
2579	if err := gensupport.DecodeResponse(target, res); err != nil {
2580		return nil, err
2581	}
2582	return ret, nil
2583	// {
2584	//   "description": "Creates a new Instance in a given location.",
2585	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances",
2586	//   "httpMethod": "POST",
2587	//   "id": "memcache.projects.locations.instances.create",
2588	//   "parameterOrder": [
2589	//     "parent"
2590	//   ],
2591	//   "parameters": {
2592	//     "instanceId": {
2593	//       "description": "Required. The logical name of the Memcached instance in the user project with the following restrictions: * Must contain only lowercase letters, numbers, and hyphens. * Must start with a letter. * Must be between 1-40 characters. * Must end with a number or a letter. * Must be unique within the user project / location. If any of the above are not met, the API raises an invalid argument error.",
2594	//       "location": "query",
2595	//       "type": "string"
2596	//     },
2597	//     "parent": {
2598	//       "description": "Required. The resource name of the instance location using the form: `projects/{project_id}/locations/{location_id}` where `location_id` refers to a GCP region",
2599	//       "location": "path",
2600	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
2601	//       "required": true,
2602	//       "type": "string"
2603	//     }
2604	//   },
2605	//   "path": "v1beta2/{+parent}/instances",
2606	//   "request": {
2607	//     "$ref": "Instance"
2608	//   },
2609	//   "response": {
2610	//     "$ref": "Operation"
2611	//   },
2612	//   "scopes": [
2613	//     "https://www.googleapis.com/auth/cloud-platform"
2614	//   ]
2615	// }
2616
2617}
2618
2619// method id "memcache.projects.locations.instances.delete":
2620
2621type ProjectsLocationsInstancesDeleteCall struct {
2622	s          *Service
2623	name       string
2624	urlParams_ gensupport.URLParams
2625	ctx_       context.Context
2626	header_    http.Header
2627}
2628
2629// Delete: Deletes a single Instance.
2630//
2631// - name: Memcached instance resource name in the format:
2632//   `projects/{project_id}/locations/{location_id}/instances/{instance_i
2633//   d}` where `location_id` refers to a GCP region.
2634func (r *ProjectsLocationsInstancesService) Delete(name string) *ProjectsLocationsInstancesDeleteCall {
2635	c := &ProjectsLocationsInstancesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2636	c.name = name
2637	return c
2638}
2639
2640// Fields allows partial responses to be retrieved. See
2641// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2642// for more information.
2643func (c *ProjectsLocationsInstancesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDeleteCall {
2644	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2645	return c
2646}
2647
2648// Context sets the context to be used in this call's Do method. Any
2649// pending HTTP request will be aborted if the provided context is
2650// canceled.
2651func (c *ProjectsLocationsInstancesDeleteCall) Context(ctx context.Context) *ProjectsLocationsInstancesDeleteCall {
2652	c.ctx_ = ctx
2653	return c
2654}
2655
2656// Header returns an http.Header that can be modified by the caller to
2657// add HTTP headers to the request.
2658func (c *ProjectsLocationsInstancesDeleteCall) Header() http.Header {
2659	if c.header_ == nil {
2660		c.header_ = make(http.Header)
2661	}
2662	return c.header_
2663}
2664
2665func (c *ProjectsLocationsInstancesDeleteCall) doRequest(alt string) (*http.Response, error) {
2666	reqHeaders := make(http.Header)
2667	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2668	for k, v := range c.header_ {
2669		reqHeaders[k] = v
2670	}
2671	reqHeaders.Set("User-Agent", c.s.userAgent())
2672	var body io.Reader = nil
2673	c.urlParams_.Set("alt", alt)
2674	c.urlParams_.Set("prettyPrint", "false")
2675	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}")
2676	urls += "?" + c.urlParams_.Encode()
2677	req, err := http.NewRequest("DELETE", urls, body)
2678	if err != nil {
2679		return nil, err
2680	}
2681	req.Header = reqHeaders
2682	googleapi.Expand(req.URL, map[string]string{
2683		"name": c.name,
2684	})
2685	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2686}
2687
2688// Do executes the "memcache.projects.locations.instances.delete" call.
2689// Exactly one of *Operation or error will be non-nil. Any non-2xx
2690// status code is an error. Response headers are in either
2691// *Operation.ServerResponse.Header or (if a response was returned at
2692// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2693// to check whether the returned error was because
2694// http.StatusNotModified was returned.
2695func (c *ProjectsLocationsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
2696	gensupport.SetOptions(c.urlParams_, opts...)
2697	res, err := c.doRequest("json")
2698	if res != nil && res.StatusCode == http.StatusNotModified {
2699		if res.Body != nil {
2700			res.Body.Close()
2701		}
2702		return nil, &googleapi.Error{
2703			Code:   res.StatusCode,
2704			Header: res.Header,
2705		}
2706	}
2707	if err != nil {
2708		return nil, err
2709	}
2710	defer googleapi.CloseBody(res)
2711	if err := googleapi.CheckResponse(res); err != nil {
2712		return nil, err
2713	}
2714	ret := &Operation{
2715		ServerResponse: googleapi.ServerResponse{
2716			Header:         res.Header,
2717			HTTPStatusCode: res.StatusCode,
2718		},
2719	}
2720	target := &ret
2721	if err := gensupport.DecodeResponse(target, res); err != nil {
2722		return nil, err
2723	}
2724	return ret, nil
2725	// {
2726	//   "description": "Deletes a single Instance.",
2727	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}",
2728	//   "httpMethod": "DELETE",
2729	//   "id": "memcache.projects.locations.instances.delete",
2730	//   "parameterOrder": [
2731	//     "name"
2732	//   ],
2733	//   "parameters": {
2734	//     "name": {
2735	//       "description": "Required. Memcached instance resource name in the format: `projects/{project_id}/locations/{location_id}/instances/{instance_id}` where `location_id` refers to a GCP region",
2736	//       "location": "path",
2737	//       "pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
2738	//       "required": true,
2739	//       "type": "string"
2740	//     }
2741	//   },
2742	//   "path": "v1beta2/{+name}",
2743	//   "response": {
2744	//     "$ref": "Operation"
2745	//   },
2746	//   "scopes": [
2747	//     "https://www.googleapis.com/auth/cloud-platform"
2748	//   ]
2749	// }
2750
2751}
2752
2753// method id "memcache.projects.locations.instances.get":
2754
2755type ProjectsLocationsInstancesGetCall struct {
2756	s            *Service
2757	name         string
2758	urlParams_   gensupport.URLParams
2759	ifNoneMatch_ string
2760	ctx_         context.Context
2761	header_      http.Header
2762}
2763
2764// Get: Gets details of a single Instance.
2765//
2766// - name: Memcached instance resource name in the format:
2767//   `projects/{project_id}/locations/{location_id}/instances/{instance_i
2768//   d}` where `location_id` refers to a GCP region.
2769func (r *ProjectsLocationsInstancesService) Get(name string) *ProjectsLocationsInstancesGetCall {
2770	c := &ProjectsLocationsInstancesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2771	c.name = name
2772	return c
2773}
2774
2775// Fields allows partial responses to be retrieved. See
2776// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2777// for more information.
2778func (c *ProjectsLocationsInstancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetCall {
2779	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2780	return c
2781}
2782
2783// IfNoneMatch sets the optional parameter which makes the operation
2784// fail if the object's ETag matches the given value. This is useful for
2785// getting updates only after the object has changed since the last
2786// request. Use googleapi.IsNotModified to check whether the response
2787// error from Do is the result of In-None-Match.
2788func (c *ProjectsLocationsInstancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetCall {
2789	c.ifNoneMatch_ = entityTag
2790	return c
2791}
2792
2793// Context sets the context to be used in this call's Do method. Any
2794// pending HTTP request will be aborted if the provided context is
2795// canceled.
2796func (c *ProjectsLocationsInstancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetCall {
2797	c.ctx_ = ctx
2798	return c
2799}
2800
2801// Header returns an http.Header that can be modified by the caller to
2802// add HTTP headers to the request.
2803func (c *ProjectsLocationsInstancesGetCall) Header() http.Header {
2804	if c.header_ == nil {
2805		c.header_ = make(http.Header)
2806	}
2807	return c.header_
2808}
2809
2810func (c *ProjectsLocationsInstancesGetCall) doRequest(alt string) (*http.Response, error) {
2811	reqHeaders := make(http.Header)
2812	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2813	for k, v := range c.header_ {
2814		reqHeaders[k] = v
2815	}
2816	reqHeaders.Set("User-Agent", c.s.userAgent())
2817	if c.ifNoneMatch_ != "" {
2818		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
2819	}
2820	var body io.Reader = nil
2821	c.urlParams_.Set("alt", alt)
2822	c.urlParams_.Set("prettyPrint", "false")
2823	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}")
2824	urls += "?" + c.urlParams_.Encode()
2825	req, err := http.NewRequest("GET", urls, body)
2826	if err != nil {
2827		return nil, err
2828	}
2829	req.Header = reqHeaders
2830	googleapi.Expand(req.URL, map[string]string{
2831		"name": c.name,
2832	})
2833	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2834}
2835
2836// Do executes the "memcache.projects.locations.instances.get" call.
2837// Exactly one of *Instance or error will be non-nil. Any non-2xx status
2838// code is an error. Response headers are in either
2839// *Instance.ServerResponse.Header or (if a response was returned at
2840// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2841// to check whether the returned error was because
2842// http.StatusNotModified was returned.
2843func (c *ProjectsLocationsInstancesGetCall) Do(opts ...googleapi.CallOption) (*Instance, error) {
2844	gensupport.SetOptions(c.urlParams_, opts...)
2845	res, err := c.doRequest("json")
2846	if res != nil && res.StatusCode == http.StatusNotModified {
2847		if res.Body != nil {
2848			res.Body.Close()
2849		}
2850		return nil, &googleapi.Error{
2851			Code:   res.StatusCode,
2852			Header: res.Header,
2853		}
2854	}
2855	if err != nil {
2856		return nil, err
2857	}
2858	defer googleapi.CloseBody(res)
2859	if err := googleapi.CheckResponse(res); err != nil {
2860		return nil, err
2861	}
2862	ret := &Instance{
2863		ServerResponse: googleapi.ServerResponse{
2864			Header:         res.Header,
2865			HTTPStatusCode: res.StatusCode,
2866		},
2867	}
2868	target := &ret
2869	if err := gensupport.DecodeResponse(target, res); err != nil {
2870		return nil, err
2871	}
2872	return ret, nil
2873	// {
2874	//   "description": "Gets details of a single Instance.",
2875	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}",
2876	//   "httpMethod": "GET",
2877	//   "id": "memcache.projects.locations.instances.get",
2878	//   "parameterOrder": [
2879	//     "name"
2880	//   ],
2881	//   "parameters": {
2882	//     "name": {
2883	//       "description": "Required. Memcached instance resource name in the format: `projects/{project_id}/locations/{location_id}/instances/{instance_id}` where `location_id` refers to a GCP region",
2884	//       "location": "path",
2885	//       "pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
2886	//       "required": true,
2887	//       "type": "string"
2888	//     }
2889	//   },
2890	//   "path": "v1beta2/{+name}",
2891	//   "response": {
2892	//     "$ref": "Instance"
2893	//   },
2894	//   "scopes": [
2895	//     "https://www.googleapis.com/auth/cloud-platform"
2896	//   ]
2897	// }
2898
2899}
2900
2901// method id "memcache.projects.locations.instances.list":
2902
2903type ProjectsLocationsInstancesListCall struct {
2904	s            *Service
2905	parent       string
2906	urlParams_   gensupport.URLParams
2907	ifNoneMatch_ string
2908	ctx_         context.Context
2909	header_      http.Header
2910}
2911
2912// List: Lists Instances in a given location.
2913//
2914// - parent: The resource name of the instance location using the form:
2915//   `projects/{project_id}/locations/{location_id}` where `location_id`
2916//   refers to a GCP region.
2917func (r *ProjectsLocationsInstancesService) List(parent string) *ProjectsLocationsInstancesListCall {
2918	c := &ProjectsLocationsInstancesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2919	c.parent = parent
2920	return c
2921}
2922
2923// Filter sets the optional parameter "filter": List filter. For
2924// example, exclude all Memcached instances with name as my-instance by
2925// specifying "name != my-instance".
2926func (c *ProjectsLocationsInstancesListCall) Filter(filter string) *ProjectsLocationsInstancesListCall {
2927	c.urlParams_.Set("filter", filter)
2928	return c
2929}
2930
2931// OrderBy sets the optional parameter "orderBy": Sort results.
2932// Supported values are "name", "name desc" or "" (unsorted).
2933func (c *ProjectsLocationsInstancesListCall) OrderBy(orderBy string) *ProjectsLocationsInstancesListCall {
2934	c.urlParams_.Set("orderBy", orderBy)
2935	return c
2936}
2937
2938// PageSize sets the optional parameter "pageSize": The maximum number
2939// of items to return. If not specified, a default value of 1000 will be
2940// used by the service. Regardless of the `page_size` value, the
2941// response may include a partial list and a caller should only rely on
2942// response's `next_page_token` to determine if there are more instances
2943// left to be queried.
2944func (c *ProjectsLocationsInstancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesListCall {
2945	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
2946	return c
2947}
2948
2949// PageToken sets the optional parameter "pageToken": The
2950// `next_page_token` value returned from a previous List request, if
2951// any.
2952func (c *ProjectsLocationsInstancesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesListCall {
2953	c.urlParams_.Set("pageToken", pageToken)
2954	return c
2955}
2956
2957// Fields allows partial responses to be retrieved. See
2958// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2959// for more information.
2960func (c *ProjectsLocationsInstancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesListCall {
2961	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2962	return c
2963}
2964
2965// IfNoneMatch sets the optional parameter which makes the operation
2966// fail if the object's ETag matches the given value. This is useful for
2967// getting updates only after the object has changed since the last
2968// request. Use googleapi.IsNotModified to check whether the response
2969// error from Do is the result of In-None-Match.
2970func (c *ProjectsLocationsInstancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesListCall {
2971	c.ifNoneMatch_ = entityTag
2972	return c
2973}
2974
2975// Context sets the context to be used in this call's Do method. Any
2976// pending HTTP request will be aborted if the provided context is
2977// canceled.
2978func (c *ProjectsLocationsInstancesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesListCall {
2979	c.ctx_ = ctx
2980	return c
2981}
2982
2983// Header returns an http.Header that can be modified by the caller to
2984// add HTTP headers to the request.
2985func (c *ProjectsLocationsInstancesListCall) Header() http.Header {
2986	if c.header_ == nil {
2987		c.header_ = make(http.Header)
2988	}
2989	return c.header_
2990}
2991
2992func (c *ProjectsLocationsInstancesListCall) doRequest(alt string) (*http.Response, error) {
2993	reqHeaders := make(http.Header)
2994	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
2995	for k, v := range c.header_ {
2996		reqHeaders[k] = v
2997	}
2998	reqHeaders.Set("User-Agent", c.s.userAgent())
2999	if c.ifNoneMatch_ != "" {
3000		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
3001	}
3002	var body io.Reader = nil
3003	c.urlParams_.Set("alt", alt)
3004	c.urlParams_.Set("prettyPrint", "false")
3005	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+parent}/instances")
3006	urls += "?" + c.urlParams_.Encode()
3007	req, err := http.NewRequest("GET", urls, body)
3008	if err != nil {
3009		return nil, err
3010	}
3011	req.Header = reqHeaders
3012	googleapi.Expand(req.URL, map[string]string{
3013		"parent": c.parent,
3014	})
3015	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3016}
3017
3018// Do executes the "memcache.projects.locations.instances.list" call.
3019// Exactly one of *ListInstancesResponse or error will be non-nil. Any
3020// non-2xx status code is an error. Response headers are in either
3021// *ListInstancesResponse.ServerResponse.Header or (if a response was
3022// returned at all) in error.(*googleapi.Error).Header. Use
3023// googleapi.IsNotModified to check whether the returned error was
3024// because http.StatusNotModified was returned.
3025func (c *ProjectsLocationsInstancesListCall) Do(opts ...googleapi.CallOption) (*ListInstancesResponse, error) {
3026	gensupport.SetOptions(c.urlParams_, opts...)
3027	res, err := c.doRequest("json")
3028	if res != nil && res.StatusCode == http.StatusNotModified {
3029		if res.Body != nil {
3030			res.Body.Close()
3031		}
3032		return nil, &googleapi.Error{
3033			Code:   res.StatusCode,
3034			Header: res.Header,
3035		}
3036	}
3037	if err != nil {
3038		return nil, err
3039	}
3040	defer googleapi.CloseBody(res)
3041	if err := googleapi.CheckResponse(res); err != nil {
3042		return nil, err
3043	}
3044	ret := &ListInstancesResponse{
3045		ServerResponse: googleapi.ServerResponse{
3046			Header:         res.Header,
3047			HTTPStatusCode: res.StatusCode,
3048		},
3049	}
3050	target := &ret
3051	if err := gensupport.DecodeResponse(target, res); err != nil {
3052		return nil, err
3053	}
3054	return ret, nil
3055	// {
3056	//   "description": "Lists Instances in a given location.",
3057	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances",
3058	//   "httpMethod": "GET",
3059	//   "id": "memcache.projects.locations.instances.list",
3060	//   "parameterOrder": [
3061	//     "parent"
3062	//   ],
3063	//   "parameters": {
3064	//     "filter": {
3065	//       "description": "List filter. For example, exclude all Memcached instances with name as my-instance by specifying `\"name != my-instance\"`.",
3066	//       "location": "query",
3067	//       "type": "string"
3068	//     },
3069	//     "orderBy": {
3070	//       "description": "Sort results. Supported values are \"name\", \"name desc\" or \"\" (unsorted).",
3071	//       "location": "query",
3072	//       "type": "string"
3073	//     },
3074	//     "pageSize": {
3075	//       "description": "The maximum number of items to return. If not specified, a default value of 1000 will be used by the service. Regardless of the `page_size` value, the response may include a partial list and a caller should only rely on response's `next_page_token` to determine if there are more instances left to be queried.",
3076	//       "format": "int32",
3077	//       "location": "query",
3078	//       "type": "integer"
3079	//     },
3080	//     "pageToken": {
3081	//       "description": "The `next_page_token` value returned from a previous List request, if any.",
3082	//       "location": "query",
3083	//       "type": "string"
3084	//     },
3085	//     "parent": {
3086	//       "description": "Required. The resource name of the instance location using the form: `projects/{project_id}/locations/{location_id}` where `location_id` refers to a GCP region",
3087	//       "location": "path",
3088	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
3089	//       "required": true,
3090	//       "type": "string"
3091	//     }
3092	//   },
3093	//   "path": "v1beta2/{+parent}/instances",
3094	//   "response": {
3095	//     "$ref": "ListInstancesResponse"
3096	//   },
3097	//   "scopes": [
3098	//     "https://www.googleapis.com/auth/cloud-platform"
3099	//   ]
3100	// }
3101
3102}
3103
3104// Pages invokes f for each page of results.
3105// A non-nil error returned from f will halt the iteration.
3106// The provided context supersedes any context provided to the Context method.
3107func (c *ProjectsLocationsInstancesListCall) Pages(ctx context.Context, f func(*ListInstancesResponse) error) error {
3108	c.ctx_ = ctx
3109	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
3110	for {
3111		x, err := c.Do()
3112		if err != nil {
3113			return err
3114		}
3115		if err := f(x); err != nil {
3116			return err
3117		}
3118		if x.NextPageToken == "" {
3119			return nil
3120		}
3121		c.PageToken(x.NextPageToken)
3122	}
3123}
3124
3125// method id "memcache.projects.locations.instances.patch":
3126
3127type ProjectsLocationsInstancesPatchCall struct {
3128	s          *Service
3129	name       string
3130	instance   *Instance
3131	urlParams_ gensupport.URLParams
3132	ctx_       context.Context
3133	header_    http.Header
3134}
3135
3136// Patch: Updates an existing Instance in a given project and location.
3137//
3138// - name: Unique name of the resource in this scope including project
3139//   and location using the form:
3140//   `projects/{project_id}/locations/{location_id}/instances/{instance_i
3141//   d}` Note: Memcached instances are managed and addressed at the
3142//   regional level so `location_id` here refers to a Google Cloud
3143//   region; however, users may choose which zones Memcached nodes
3144//   should be provisioned in within an instance. Refer to zones field
3145//   for more details.
3146func (r *ProjectsLocationsInstancesService) Patch(name string, instance *Instance) *ProjectsLocationsInstancesPatchCall {
3147	c := &ProjectsLocationsInstancesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3148	c.name = name
3149	c.instance = instance
3150	return c
3151}
3152
3153// UpdateMask sets the optional parameter "updateMask": Required. Mask
3154// of fields to update. * `displayName`
3155func (c *ProjectsLocationsInstancesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsInstancesPatchCall {
3156	c.urlParams_.Set("updateMask", updateMask)
3157	return c
3158}
3159
3160// Fields allows partial responses to be retrieved. See
3161// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3162// for more information.
3163func (c *ProjectsLocationsInstancesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesPatchCall {
3164	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3165	return c
3166}
3167
3168// Context sets the context to be used in this call's Do method. Any
3169// pending HTTP request will be aborted if the provided context is
3170// canceled.
3171func (c *ProjectsLocationsInstancesPatchCall) Context(ctx context.Context) *ProjectsLocationsInstancesPatchCall {
3172	c.ctx_ = ctx
3173	return c
3174}
3175
3176// Header returns an http.Header that can be modified by the caller to
3177// add HTTP headers to the request.
3178func (c *ProjectsLocationsInstancesPatchCall) Header() http.Header {
3179	if c.header_ == nil {
3180		c.header_ = make(http.Header)
3181	}
3182	return c.header_
3183}
3184
3185func (c *ProjectsLocationsInstancesPatchCall) doRequest(alt string) (*http.Response, error) {
3186	reqHeaders := make(http.Header)
3187	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
3188	for k, v := range c.header_ {
3189		reqHeaders[k] = v
3190	}
3191	reqHeaders.Set("User-Agent", c.s.userAgent())
3192	var body io.Reader = nil
3193	body, err := googleapi.WithoutDataWrapper.JSONReader(c.instance)
3194	if err != nil {
3195		return nil, err
3196	}
3197	reqHeaders.Set("Content-Type", "application/json")
3198	c.urlParams_.Set("alt", alt)
3199	c.urlParams_.Set("prettyPrint", "false")
3200	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}")
3201	urls += "?" + c.urlParams_.Encode()
3202	req, err := http.NewRequest("PATCH", urls, body)
3203	if err != nil {
3204		return nil, err
3205	}
3206	req.Header = reqHeaders
3207	googleapi.Expand(req.URL, map[string]string{
3208		"name": c.name,
3209	})
3210	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3211}
3212
3213// Do executes the "memcache.projects.locations.instances.patch" call.
3214// Exactly one of *Operation or error will be non-nil. Any non-2xx
3215// status code is an error. Response headers are in either
3216// *Operation.ServerResponse.Header or (if a response was returned at
3217// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
3218// to check whether the returned error was because
3219// http.StatusNotModified was returned.
3220func (c *ProjectsLocationsInstancesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
3221	gensupport.SetOptions(c.urlParams_, opts...)
3222	res, err := c.doRequest("json")
3223	if res != nil && res.StatusCode == http.StatusNotModified {
3224		if res.Body != nil {
3225			res.Body.Close()
3226		}
3227		return nil, &googleapi.Error{
3228			Code:   res.StatusCode,
3229			Header: res.Header,
3230		}
3231	}
3232	if err != nil {
3233		return nil, err
3234	}
3235	defer googleapi.CloseBody(res)
3236	if err := googleapi.CheckResponse(res); err != nil {
3237		return nil, err
3238	}
3239	ret := &Operation{
3240		ServerResponse: googleapi.ServerResponse{
3241			Header:         res.Header,
3242			HTTPStatusCode: res.StatusCode,
3243		},
3244	}
3245	target := &ret
3246	if err := gensupport.DecodeResponse(target, res); err != nil {
3247		return nil, err
3248	}
3249	return ret, nil
3250	// {
3251	//   "description": "Updates an existing Instance in a given project and location.",
3252	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}",
3253	//   "httpMethod": "PATCH",
3254	//   "id": "memcache.projects.locations.instances.patch",
3255	//   "parameterOrder": [
3256	//     "name"
3257	//   ],
3258	//   "parameters": {
3259	//     "name": {
3260	//       "description": "Required. Unique name of the resource in this scope including project and location using the form: `projects/{project_id}/locations/{location_id}/instances/{instance_id}` Note: Memcached instances are managed and addressed at the regional level so `location_id` here refers to a Google Cloud region; however, users may choose which zones Memcached nodes should be provisioned in within an instance. Refer to zones field for more details.",
3261	//       "location": "path",
3262	//       "pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
3263	//       "required": true,
3264	//       "type": "string"
3265	//     },
3266	//     "updateMask": {
3267	//       "description": "Required. Mask of fields to update. * `displayName`",
3268	//       "format": "google-fieldmask",
3269	//       "location": "query",
3270	//       "type": "string"
3271	//     }
3272	//   },
3273	//   "path": "v1beta2/{+name}",
3274	//   "request": {
3275	//     "$ref": "Instance"
3276	//   },
3277	//   "response": {
3278	//     "$ref": "Operation"
3279	//   },
3280	//   "scopes": [
3281	//     "https://www.googleapis.com/auth/cloud-platform"
3282	//   ]
3283	// }
3284
3285}
3286
3287// method id "memcache.projects.locations.instances.updateParameters":
3288
3289type ProjectsLocationsInstancesUpdateParametersCall struct {
3290	s                       *Service
3291	name                    string
3292	updateparametersrequest *UpdateParametersRequest
3293	urlParams_              gensupport.URLParams
3294	ctx_                    context.Context
3295	header_                 http.Header
3296}
3297
3298// UpdateParameters: Updates the defined Memcached parameters for an
3299// existing instance. This method only stages the parameters, it must be
3300// followed by `ApplyParameters` to apply the parameters to nodes of the
3301// Memcached instance.
3302//
3303// - name: Resource name of the Memcached instance for which the
3304//   parameters should be updated.
3305func (r *ProjectsLocationsInstancesService) UpdateParameters(name string, updateparametersrequest *UpdateParametersRequest) *ProjectsLocationsInstancesUpdateParametersCall {
3306	c := &ProjectsLocationsInstancesUpdateParametersCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3307	c.name = name
3308	c.updateparametersrequest = updateparametersrequest
3309	return c
3310}
3311
3312// Fields allows partial responses to be retrieved. See
3313// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3314// for more information.
3315func (c *ProjectsLocationsInstancesUpdateParametersCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesUpdateParametersCall {
3316	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3317	return c
3318}
3319
3320// Context sets the context to be used in this call's Do method. Any
3321// pending HTTP request will be aborted if the provided context is
3322// canceled.
3323func (c *ProjectsLocationsInstancesUpdateParametersCall) Context(ctx context.Context) *ProjectsLocationsInstancesUpdateParametersCall {
3324	c.ctx_ = ctx
3325	return c
3326}
3327
3328// Header returns an http.Header that can be modified by the caller to
3329// add HTTP headers to the request.
3330func (c *ProjectsLocationsInstancesUpdateParametersCall) Header() http.Header {
3331	if c.header_ == nil {
3332		c.header_ = make(http.Header)
3333	}
3334	return c.header_
3335}
3336
3337func (c *ProjectsLocationsInstancesUpdateParametersCall) doRequest(alt string) (*http.Response, error) {
3338	reqHeaders := make(http.Header)
3339	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
3340	for k, v := range c.header_ {
3341		reqHeaders[k] = v
3342	}
3343	reqHeaders.Set("User-Agent", c.s.userAgent())
3344	var body io.Reader = nil
3345	body, err := googleapi.WithoutDataWrapper.JSONReader(c.updateparametersrequest)
3346	if err != nil {
3347		return nil, err
3348	}
3349	reqHeaders.Set("Content-Type", "application/json")
3350	c.urlParams_.Set("alt", alt)
3351	c.urlParams_.Set("prettyPrint", "false")
3352	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}:updateParameters")
3353	urls += "?" + c.urlParams_.Encode()
3354	req, err := http.NewRequest("PATCH", urls, body)
3355	if err != nil {
3356		return nil, err
3357	}
3358	req.Header = reqHeaders
3359	googleapi.Expand(req.URL, map[string]string{
3360		"name": c.name,
3361	})
3362	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3363}
3364
3365// Do executes the "memcache.projects.locations.instances.updateParameters" call.
3366// Exactly one of *Operation or error will be non-nil. Any non-2xx
3367// status code is an error. Response headers are in either
3368// *Operation.ServerResponse.Header or (if a response was returned at
3369// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
3370// to check whether the returned error was because
3371// http.StatusNotModified was returned.
3372func (c *ProjectsLocationsInstancesUpdateParametersCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
3373	gensupport.SetOptions(c.urlParams_, opts...)
3374	res, err := c.doRequest("json")
3375	if res != nil && res.StatusCode == http.StatusNotModified {
3376		if res.Body != nil {
3377			res.Body.Close()
3378		}
3379		return nil, &googleapi.Error{
3380			Code:   res.StatusCode,
3381			Header: res.Header,
3382		}
3383	}
3384	if err != nil {
3385		return nil, err
3386	}
3387	defer googleapi.CloseBody(res)
3388	if err := googleapi.CheckResponse(res); err != nil {
3389		return nil, err
3390	}
3391	ret := &Operation{
3392		ServerResponse: googleapi.ServerResponse{
3393			Header:         res.Header,
3394			HTTPStatusCode: res.StatusCode,
3395		},
3396	}
3397	target := &ret
3398	if err := gensupport.DecodeResponse(target, res); err != nil {
3399		return nil, err
3400	}
3401	return ret, nil
3402	// {
3403	//   "description": "Updates the defined Memcached parameters for an existing instance. This method only stages the parameters, it must be followed by `ApplyParameters` to apply the parameters to nodes of the Memcached instance.",
3404	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:updateParameters",
3405	//   "httpMethod": "PATCH",
3406	//   "id": "memcache.projects.locations.instances.updateParameters",
3407	//   "parameterOrder": [
3408	//     "name"
3409	//   ],
3410	//   "parameters": {
3411	//     "name": {
3412	//       "description": "Required. Resource name of the Memcached instance for which the parameters should be updated.",
3413	//       "location": "path",
3414	//       "pattern": "^projects/[^/]+/locations/[^/]+/instances/[^/]+$",
3415	//       "required": true,
3416	//       "type": "string"
3417	//     }
3418	//   },
3419	//   "path": "v1beta2/{+name}:updateParameters",
3420	//   "request": {
3421	//     "$ref": "UpdateParametersRequest"
3422	//   },
3423	//   "response": {
3424	//     "$ref": "Operation"
3425	//   },
3426	//   "scopes": [
3427	//     "https://www.googleapis.com/auth/cloud-platform"
3428	//   ]
3429	// }
3430
3431}
3432
3433// method id "memcache.projects.locations.operations.cancel":
3434
3435type ProjectsLocationsOperationsCancelCall struct {
3436	s                      *Service
3437	name                   string
3438	canceloperationrequest *CancelOperationRequest
3439	urlParams_             gensupport.URLParams
3440	ctx_                   context.Context
3441	header_                http.Header
3442}
3443
3444// Cancel: Starts asynchronous cancellation on a long-running operation.
3445// The server makes a best effort to cancel the operation, but success
3446// is not guaranteed. If the server doesn't support this method, it
3447// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use
3448// Operations.GetOperation or other methods to check whether the
3449// cancellation succeeded or whether the operation completed despite
3450// cancellation. On successful cancellation, the operation is not
3451// deleted; instead, it becomes an operation with an Operation.error
3452// value with a google.rpc.Status.code of 1, corresponding to
3453// `Code.CANCELLED`.
3454//
3455// - name: The name of the operation resource to be cancelled.
3456func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall {
3457	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3458	c.name = name
3459	c.canceloperationrequest = canceloperationrequest
3460	return c
3461}
3462
3463// Fields allows partial responses to be retrieved. See
3464// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3465// for more information.
3466func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
3467	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3468	return c
3469}
3470
3471// Context sets the context to be used in this call's Do method. Any
3472// pending HTTP request will be aborted if the provided context is
3473// canceled.
3474func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
3475	c.ctx_ = ctx
3476	return c
3477}
3478
3479// Header returns an http.Header that can be modified by the caller to
3480// add HTTP headers to the request.
3481func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
3482	if c.header_ == nil {
3483		c.header_ = make(http.Header)
3484	}
3485	return c.header_
3486}
3487
3488func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
3489	reqHeaders := make(http.Header)
3490	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
3491	for k, v := range c.header_ {
3492		reqHeaders[k] = v
3493	}
3494	reqHeaders.Set("User-Agent", c.s.userAgent())
3495	var body io.Reader = nil
3496	body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest)
3497	if err != nil {
3498		return nil, err
3499	}
3500	reqHeaders.Set("Content-Type", "application/json")
3501	c.urlParams_.Set("alt", alt)
3502	c.urlParams_.Set("prettyPrint", "false")
3503	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}:cancel")
3504	urls += "?" + c.urlParams_.Encode()
3505	req, err := http.NewRequest("POST", urls, body)
3506	if err != nil {
3507		return nil, err
3508	}
3509	req.Header = reqHeaders
3510	googleapi.Expand(req.URL, map[string]string{
3511		"name": c.name,
3512	})
3513	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3514}
3515
3516// Do executes the "memcache.projects.locations.operations.cancel" call.
3517// Exactly one of *Empty or error will be non-nil. Any non-2xx status
3518// code is an error. Response headers are in either
3519// *Empty.ServerResponse.Header or (if a response was returned at all)
3520// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
3521// check whether the returned error was because http.StatusNotModified
3522// was returned.
3523func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
3524	gensupport.SetOptions(c.urlParams_, opts...)
3525	res, err := c.doRequest("json")
3526	if res != nil && res.StatusCode == http.StatusNotModified {
3527		if res.Body != nil {
3528			res.Body.Close()
3529		}
3530		return nil, &googleapi.Error{
3531			Code:   res.StatusCode,
3532			Header: res.Header,
3533		}
3534	}
3535	if err != nil {
3536		return nil, err
3537	}
3538	defer googleapi.CloseBody(res)
3539	if err := googleapi.CheckResponse(res); err != nil {
3540		return nil, err
3541	}
3542	ret := &Empty{
3543		ServerResponse: googleapi.ServerResponse{
3544			Header:         res.Header,
3545			HTTPStatusCode: res.StatusCode,
3546		},
3547	}
3548	target := &ret
3549	if err := gensupport.DecodeResponse(target, res); err != nil {
3550		return nil, err
3551	}
3552	return ret, nil
3553	// {
3554	//   "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.",
3555	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
3556	//   "httpMethod": "POST",
3557	//   "id": "memcache.projects.locations.operations.cancel",
3558	//   "parameterOrder": [
3559	//     "name"
3560	//   ],
3561	//   "parameters": {
3562	//     "name": {
3563	//       "description": "The name of the operation resource to be cancelled.",
3564	//       "location": "path",
3565	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
3566	//       "required": true,
3567	//       "type": "string"
3568	//     }
3569	//   },
3570	//   "path": "v1beta2/{+name}:cancel",
3571	//   "request": {
3572	//     "$ref": "CancelOperationRequest"
3573	//   },
3574	//   "response": {
3575	//     "$ref": "Empty"
3576	//   },
3577	//   "scopes": [
3578	//     "https://www.googleapis.com/auth/cloud-platform"
3579	//   ]
3580	// }
3581
3582}
3583
3584// method id "memcache.projects.locations.operations.delete":
3585
3586type ProjectsLocationsOperationsDeleteCall struct {
3587	s          *Service
3588	name       string
3589	urlParams_ gensupport.URLParams
3590	ctx_       context.Context
3591	header_    http.Header
3592}
3593
3594// Delete: Deletes a long-running operation. This method indicates that
3595// the client is no longer interested in the operation result. It does
3596// not cancel the operation. If the server doesn't support this method,
3597// it returns `google.rpc.Code.UNIMPLEMENTED`.
3598//
3599// - name: The name of the operation resource to be deleted.
3600func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall {
3601	c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3602	c.name = name
3603	return c
3604}
3605
3606// Fields allows partial responses to be retrieved. See
3607// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3608// for more information.
3609func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall {
3610	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3611	return c
3612}
3613
3614// Context sets the context to be used in this call's Do method. Any
3615// pending HTTP request will be aborted if the provided context is
3616// canceled.
3617func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall {
3618	c.ctx_ = ctx
3619	return c
3620}
3621
3622// Header returns an http.Header that can be modified by the caller to
3623// add HTTP headers to the request.
3624func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header {
3625	if c.header_ == nil {
3626		c.header_ = make(http.Header)
3627	}
3628	return c.header_
3629}
3630
3631func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) {
3632	reqHeaders := make(http.Header)
3633	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
3634	for k, v := range c.header_ {
3635		reqHeaders[k] = v
3636	}
3637	reqHeaders.Set("User-Agent", c.s.userAgent())
3638	var body io.Reader = nil
3639	c.urlParams_.Set("alt", alt)
3640	c.urlParams_.Set("prettyPrint", "false")
3641	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}")
3642	urls += "?" + c.urlParams_.Encode()
3643	req, err := http.NewRequest("DELETE", urls, body)
3644	if err != nil {
3645		return nil, err
3646	}
3647	req.Header = reqHeaders
3648	googleapi.Expand(req.URL, map[string]string{
3649		"name": c.name,
3650	})
3651	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3652}
3653
3654// Do executes the "memcache.projects.locations.operations.delete" call.
3655// Exactly one of *Empty or error will be non-nil. Any non-2xx status
3656// code is an error. Response headers are in either
3657// *Empty.ServerResponse.Header or (if a response was returned at all)
3658// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
3659// check whether the returned error was because http.StatusNotModified
3660// was returned.
3661func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
3662	gensupport.SetOptions(c.urlParams_, opts...)
3663	res, err := c.doRequest("json")
3664	if res != nil && res.StatusCode == http.StatusNotModified {
3665		if res.Body != nil {
3666			res.Body.Close()
3667		}
3668		return nil, &googleapi.Error{
3669			Code:   res.StatusCode,
3670			Header: res.Header,
3671		}
3672	}
3673	if err != nil {
3674		return nil, err
3675	}
3676	defer googleapi.CloseBody(res)
3677	if err := googleapi.CheckResponse(res); err != nil {
3678		return nil, err
3679	}
3680	ret := &Empty{
3681		ServerResponse: googleapi.ServerResponse{
3682			Header:         res.Header,
3683			HTTPStatusCode: res.StatusCode,
3684		},
3685	}
3686	target := &ret
3687	if err := gensupport.DecodeResponse(target, res); err != nil {
3688		return nil, err
3689	}
3690	return ret, nil
3691	// {
3692	//   "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.",
3693	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
3694	//   "httpMethod": "DELETE",
3695	//   "id": "memcache.projects.locations.operations.delete",
3696	//   "parameterOrder": [
3697	//     "name"
3698	//   ],
3699	//   "parameters": {
3700	//     "name": {
3701	//       "description": "The name of the operation resource to be deleted.",
3702	//       "location": "path",
3703	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
3704	//       "required": true,
3705	//       "type": "string"
3706	//     }
3707	//   },
3708	//   "path": "v1beta2/{+name}",
3709	//   "response": {
3710	//     "$ref": "Empty"
3711	//   },
3712	//   "scopes": [
3713	//     "https://www.googleapis.com/auth/cloud-platform"
3714	//   ]
3715	// }
3716
3717}
3718
3719// method id "memcache.projects.locations.operations.get":
3720
3721type ProjectsLocationsOperationsGetCall struct {
3722	s            *Service
3723	name         string
3724	urlParams_   gensupport.URLParams
3725	ifNoneMatch_ string
3726	ctx_         context.Context
3727	header_      http.Header
3728}
3729
3730// Get: Gets the latest state of a long-running operation. Clients can
3731// use this method to poll the operation result at intervals as
3732// recommended by the API service.
3733//
3734// - name: The name of the operation resource.
3735func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
3736	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3737	c.name = name
3738	return c
3739}
3740
3741// Fields allows partial responses to be retrieved. See
3742// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3743// for more information.
3744func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
3745	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3746	return c
3747}
3748
3749// IfNoneMatch sets the optional parameter which makes the operation
3750// fail if the object's ETag matches the given value. This is useful for
3751// getting updates only after the object has changed since the last
3752// request. Use googleapi.IsNotModified to check whether the response
3753// error from Do is the result of In-None-Match.
3754func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
3755	c.ifNoneMatch_ = entityTag
3756	return c
3757}
3758
3759// Context sets the context to be used in this call's Do method. Any
3760// pending HTTP request will be aborted if the provided context is
3761// canceled.
3762func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
3763	c.ctx_ = ctx
3764	return c
3765}
3766
3767// Header returns an http.Header that can be modified by the caller to
3768// add HTTP headers to the request.
3769func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
3770	if c.header_ == nil {
3771		c.header_ = make(http.Header)
3772	}
3773	return c.header_
3774}
3775
3776func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
3777	reqHeaders := make(http.Header)
3778	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
3779	for k, v := range c.header_ {
3780		reqHeaders[k] = v
3781	}
3782	reqHeaders.Set("User-Agent", c.s.userAgent())
3783	if c.ifNoneMatch_ != "" {
3784		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
3785	}
3786	var body io.Reader = nil
3787	c.urlParams_.Set("alt", alt)
3788	c.urlParams_.Set("prettyPrint", "false")
3789	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}")
3790	urls += "?" + c.urlParams_.Encode()
3791	req, err := http.NewRequest("GET", urls, body)
3792	if err != nil {
3793		return nil, err
3794	}
3795	req.Header = reqHeaders
3796	googleapi.Expand(req.URL, map[string]string{
3797		"name": c.name,
3798	})
3799	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3800}
3801
3802// Do executes the "memcache.projects.locations.operations.get" call.
3803// Exactly one of *Operation or error will be non-nil. Any non-2xx
3804// status code is an error. Response headers are in either
3805// *Operation.ServerResponse.Header or (if a response was returned at
3806// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
3807// to check whether the returned error was because
3808// http.StatusNotModified was returned.
3809func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
3810	gensupport.SetOptions(c.urlParams_, opts...)
3811	res, err := c.doRequest("json")
3812	if res != nil && res.StatusCode == http.StatusNotModified {
3813		if res.Body != nil {
3814			res.Body.Close()
3815		}
3816		return nil, &googleapi.Error{
3817			Code:   res.StatusCode,
3818			Header: res.Header,
3819		}
3820	}
3821	if err != nil {
3822		return nil, err
3823	}
3824	defer googleapi.CloseBody(res)
3825	if err := googleapi.CheckResponse(res); err != nil {
3826		return nil, err
3827	}
3828	ret := &Operation{
3829		ServerResponse: googleapi.ServerResponse{
3830			Header:         res.Header,
3831			HTTPStatusCode: res.StatusCode,
3832		},
3833	}
3834	target := &ret
3835	if err := gensupport.DecodeResponse(target, res); err != nil {
3836		return nil, err
3837	}
3838	return ret, nil
3839	// {
3840	//   "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.",
3841	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
3842	//   "httpMethod": "GET",
3843	//   "id": "memcache.projects.locations.operations.get",
3844	//   "parameterOrder": [
3845	//     "name"
3846	//   ],
3847	//   "parameters": {
3848	//     "name": {
3849	//       "description": "The name of the operation resource.",
3850	//       "location": "path",
3851	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
3852	//       "required": true,
3853	//       "type": "string"
3854	//     }
3855	//   },
3856	//   "path": "v1beta2/{+name}",
3857	//   "response": {
3858	//     "$ref": "Operation"
3859	//   },
3860	//   "scopes": [
3861	//     "https://www.googleapis.com/auth/cloud-platform"
3862	//   ]
3863	// }
3864
3865}
3866
3867// method id "memcache.projects.locations.operations.list":
3868
3869type ProjectsLocationsOperationsListCall struct {
3870	s            *Service
3871	name         string
3872	urlParams_   gensupport.URLParams
3873	ifNoneMatch_ string
3874	ctx_         context.Context
3875	header_      http.Header
3876}
3877
3878// List: Lists operations that match the specified filter in the
3879// request. If the server doesn't support this method, it returns
3880// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
3881// override the binding to use different resource name schemes, such as
3882// `users/*/operations`. To override the binding, API services can add a
3883// binding such as "/v1/{name=users/*}/operations" to their service
3884// configuration. For backwards compatibility, the default name includes
3885// the operations collection id, however overriding users must ensure
3886// the name binding is the parent resource, without the operations
3887// collection id.
3888//
3889// - name: The name of the operation's parent resource.
3890func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
3891	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3892	c.name = name
3893	return c
3894}
3895
3896// Filter sets the optional parameter "filter": The standard list
3897// filter.
3898func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
3899	c.urlParams_.Set("filter", filter)
3900	return c
3901}
3902
3903// PageSize sets the optional parameter "pageSize": The standard list
3904// page size.
3905func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
3906	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
3907	return c
3908}
3909
3910// PageToken sets the optional parameter "pageToken": The standard list
3911// page token.
3912func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
3913	c.urlParams_.Set("pageToken", pageToken)
3914	return c
3915}
3916
3917// Fields allows partial responses to be retrieved. See
3918// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3919// for more information.
3920func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
3921	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3922	return c
3923}
3924
3925// IfNoneMatch sets the optional parameter which makes the operation
3926// fail if the object's ETag matches the given value. This is useful for
3927// getting updates only after the object has changed since the last
3928// request. Use googleapi.IsNotModified to check whether the response
3929// error from Do is the result of In-None-Match.
3930func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
3931	c.ifNoneMatch_ = entityTag
3932	return c
3933}
3934
3935// Context sets the context to be used in this call's Do method. Any
3936// pending HTTP request will be aborted if the provided context is
3937// canceled.
3938func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
3939	c.ctx_ = ctx
3940	return c
3941}
3942
3943// Header returns an http.Header that can be modified by the caller to
3944// add HTTP headers to the request.
3945func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
3946	if c.header_ == nil {
3947		c.header_ = make(http.Header)
3948	}
3949	return c.header_
3950}
3951
3952func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
3953	reqHeaders := make(http.Header)
3954	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210915")
3955	for k, v := range c.header_ {
3956		reqHeaders[k] = v
3957	}
3958	reqHeaders.Set("User-Agent", c.s.userAgent())
3959	if c.ifNoneMatch_ != "" {
3960		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
3961	}
3962	var body io.Reader = nil
3963	c.urlParams_.Set("alt", alt)
3964	c.urlParams_.Set("prettyPrint", "false")
3965	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta2/{+name}/operations")
3966	urls += "?" + c.urlParams_.Encode()
3967	req, err := http.NewRequest("GET", urls, body)
3968	if err != nil {
3969		return nil, err
3970	}
3971	req.Header = reqHeaders
3972	googleapi.Expand(req.URL, map[string]string{
3973		"name": c.name,
3974	})
3975	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3976}
3977
3978// Do executes the "memcache.projects.locations.operations.list" call.
3979// Exactly one of *ListOperationsResponse or error will be non-nil. Any
3980// non-2xx status code is an error. Response headers are in either
3981// *ListOperationsResponse.ServerResponse.Header or (if a response was
3982// returned at all) in error.(*googleapi.Error).Header. Use
3983// googleapi.IsNotModified to check whether the returned error was
3984// because http.StatusNotModified was returned.
3985func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
3986	gensupport.SetOptions(c.urlParams_, opts...)
3987	res, err := c.doRequest("json")
3988	if res != nil && res.StatusCode == http.StatusNotModified {
3989		if res.Body != nil {
3990			res.Body.Close()
3991		}
3992		return nil, &googleapi.Error{
3993			Code:   res.StatusCode,
3994			Header: res.Header,
3995		}
3996	}
3997	if err != nil {
3998		return nil, err
3999	}
4000	defer googleapi.CloseBody(res)
4001	if err := googleapi.CheckResponse(res); err != nil {
4002		return nil, err
4003	}
4004	ret := &ListOperationsResponse{
4005		ServerResponse: googleapi.ServerResponse{
4006			Header:         res.Header,
4007			HTTPStatusCode: res.StatusCode,
4008		},
4009	}
4010	target := &ret
4011	if err := gensupport.DecodeResponse(target, res); err != nil {
4012		return nil, err
4013	}
4014	return ret, nil
4015	// {
4016	//   "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.",
4017	//   "flatPath": "v1beta2/projects/{projectsId}/locations/{locationsId}/operations",
4018	//   "httpMethod": "GET",
4019	//   "id": "memcache.projects.locations.operations.list",
4020	//   "parameterOrder": [
4021	//     "name"
4022	//   ],
4023	//   "parameters": {
4024	//     "filter": {
4025	//       "description": "The standard list filter.",
4026	//       "location": "query",
4027	//       "type": "string"
4028	//     },
4029	//     "name": {
4030	//       "description": "The name of the operation's parent resource.",
4031	//       "location": "path",
4032	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
4033	//       "required": true,
4034	//       "type": "string"
4035	//     },
4036	//     "pageSize": {
4037	//       "description": "The standard list page size.",
4038	//       "format": "int32",
4039	//       "location": "query",
4040	//       "type": "integer"
4041	//     },
4042	//     "pageToken": {
4043	//       "description": "The standard list page token.",
4044	//       "location": "query",
4045	//       "type": "string"
4046	//     }
4047	//   },
4048	//   "path": "v1beta2/{+name}/operations",
4049	//   "response": {
4050	//     "$ref": "ListOperationsResponse"
4051	//   },
4052	//   "scopes": [
4053	//     "https://www.googleapis.com/auth/cloud-platform"
4054	//   ]
4055	// }
4056
4057}
4058
4059// Pages invokes f for each page of results.
4060// A non-nil error returned from f will halt the iteration.
4061// The provided context supersedes any context provided to the Context method.
4062func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
4063	c.ctx_ = ctx
4064	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
4065	for {
4066		x, err := c.Do()
4067		if err != nil {
4068			return err
4069		}
4070		if err := f(x); err != nil {
4071			return err
4072		}
4073		if x.NextPageToken == "" {
4074			return nil
4075		}
4076		c.PageToken(x.NextPageToken)
4077	}
4078}
4079