...

Source file src/google.golang.org/api/looker/v1/looker-gen.go

Documentation: google.golang.org/api/looker/v1

     1  // Copyright 2024 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 looker provides access to the Looker (Google Cloud core) API.
     8  //
     9  // For product documentation, see: https://cloud.google.com/looker/docs/reference/rest/
    10  //
    11  // # Library status
    12  //
    13  // These client libraries are officially supported by Google. However, this
    14  // library is considered complete and is in maintenance mode. This means
    15  // that we will address critical bugs and security issues but will not add
    16  // any new features.
    17  //
    18  // When possible, we recommend using our newer
    19  // [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)
    20  // that are still actively being worked and iterated on.
    21  //
    22  // # Creating a client
    23  //
    24  // Usage example:
    25  //
    26  //	import "google.golang.org/api/looker/v1"
    27  //	...
    28  //	ctx := context.Background()
    29  //	lookerService, err := looker.NewService(ctx)
    30  //
    31  // In this example, Google Application Default Credentials are used for
    32  // authentication. For information on how to create and obtain Application
    33  // Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
    34  //
    35  // # Other authentication options
    36  //
    37  // To use an API key for authentication (note: some APIs do not support API
    38  // keys), use [google.golang.org/api/option.WithAPIKey]:
    39  //
    40  //	lookerService, err := looker.NewService(ctx, option.WithAPIKey("AIza..."))
    41  //
    42  // To use an OAuth token (e.g., a user token obtained via a three-legged OAuth
    43  // flow, use [google.golang.org/api/option.WithTokenSource]:
    44  //
    45  //	config := &oauth2.Config{...}
    46  //	// ...
    47  //	token, err := config.Exchange(ctx, ...)
    48  //	lookerService, err := looker.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
    49  //
    50  // See [google.golang.org/api/option.ClientOption] for details on options.
    51  package looker // import "google.golang.org/api/looker/v1"
    52  
    53  import (
    54  	"bytes"
    55  	"context"
    56  	"encoding/json"
    57  	"errors"
    58  	"fmt"
    59  	"io"
    60  	"net/http"
    61  	"net/url"
    62  	"strconv"
    63  	"strings"
    64  
    65  	googleapi "google.golang.org/api/googleapi"
    66  	internal "google.golang.org/api/internal"
    67  	gensupport "google.golang.org/api/internal/gensupport"
    68  	option "google.golang.org/api/option"
    69  	internaloption "google.golang.org/api/option/internaloption"
    70  	htransport "google.golang.org/api/transport/http"
    71  )
    72  
    73  // Always reference these packages, just in case the auto-generated code
    74  // below doesn't.
    75  var _ = bytes.NewBuffer
    76  var _ = strconv.Itoa
    77  var _ = fmt.Sprintf
    78  var _ = json.NewDecoder
    79  var _ = io.Copy
    80  var _ = url.Parse
    81  var _ = gensupport.MarshalJSON
    82  var _ = googleapi.Version
    83  var _ = errors.New
    84  var _ = strings.Replace
    85  var _ = context.Canceled
    86  var _ = internaloption.WithDefaultEndpoint
    87  var _ = internal.Version
    88  
    89  const apiId = "looker:v1"
    90  const apiName = "looker"
    91  const apiVersion = "v1"
    92  const basePath = "https://looker.googleapis.com/"
    93  const basePathTemplate = "https://looker.UNIVERSE_DOMAIN/"
    94  const mtlsBasePath = "https://looker.mtls.googleapis.com/"
    95  
    96  // OAuth2 scopes used by this API.
    97  const (
    98  	// See, edit, configure, and delete your Google Cloud data and see the email
    99  	// address for your Google Account.
   100  	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
   101  )
   102  
   103  // NewService creates a new Service.
   104  func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
   105  	scopesOption := internaloption.WithDefaultScopes(
   106  		"https://www.googleapis.com/auth/cloud-platform",
   107  	)
   108  	// NOTE: prepend, so we don't override user-specified scopes.
   109  	opts = append([]option.ClientOption{scopesOption}, opts...)
   110  	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
   111  	opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate))
   112  	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
   113  	opts = append(opts, internaloption.EnableNewAuthLibrary())
   114  	client, endpoint, err := htransport.NewClient(ctx, opts...)
   115  	if err != nil {
   116  		return nil, err
   117  	}
   118  	s, err := New(client)
   119  	if err != nil {
   120  		return nil, err
   121  	}
   122  	if endpoint != "" {
   123  		s.BasePath = endpoint
   124  	}
   125  	return s, nil
   126  }
   127  
   128  // New creates a new Service. It uses the provided http.Client for requests.
   129  //
   130  // Deprecated: please use NewService instead.
   131  // To provide a custom HTTP client, use option.WithHTTPClient.
   132  // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
   133  func New(client *http.Client) (*Service, error) {
   134  	if client == nil {
   135  		return nil, errors.New("client is nil")
   136  	}
   137  	s := &Service{client: client, BasePath: basePath}
   138  	s.Projects = NewProjectsService(s)
   139  	return s, nil
   140  }
   141  
   142  type Service struct {
   143  	client    *http.Client
   144  	BasePath  string // API endpoint base URL
   145  	UserAgent string // optional additional User-Agent fragment
   146  
   147  	Projects *ProjectsService
   148  }
   149  
   150  func (s *Service) userAgent() string {
   151  	if s.UserAgent == "" {
   152  		return googleapi.UserAgent
   153  	}
   154  	return googleapi.UserAgent + " " + s.UserAgent
   155  }
   156  
   157  func NewProjectsService(s *Service) *ProjectsService {
   158  	rs := &ProjectsService{s: s}
   159  	rs.Locations = NewProjectsLocationsService(s)
   160  	return rs
   161  }
   162  
   163  type ProjectsService struct {
   164  	s *Service
   165  
   166  	Locations *ProjectsLocationsService
   167  }
   168  
   169  func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
   170  	rs := &ProjectsLocationsService{s: s}
   171  	rs.Instances = NewProjectsLocationsInstancesService(s)
   172  	rs.Operations = NewProjectsLocationsOperationsService(s)
   173  	return rs
   174  }
   175  
   176  type ProjectsLocationsService struct {
   177  	s *Service
   178  
   179  	Instances *ProjectsLocationsInstancesService
   180  
   181  	Operations *ProjectsLocationsOperationsService
   182  }
   183  
   184  func NewProjectsLocationsInstancesService(s *Service) *ProjectsLocationsInstancesService {
   185  	rs := &ProjectsLocationsInstancesService{s: s}
   186  	rs.Backups = NewProjectsLocationsInstancesBackupsService(s)
   187  	return rs
   188  }
   189  
   190  type ProjectsLocationsInstancesService struct {
   191  	s *Service
   192  
   193  	Backups *ProjectsLocationsInstancesBackupsService
   194  }
   195  
   196  func NewProjectsLocationsInstancesBackupsService(s *Service) *ProjectsLocationsInstancesBackupsService {
   197  	rs := &ProjectsLocationsInstancesBackupsService{s: s}
   198  	return rs
   199  }
   200  
   201  type ProjectsLocationsInstancesBackupsService struct {
   202  	s *Service
   203  }
   204  
   205  func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
   206  	rs := &ProjectsLocationsOperationsService{s: s}
   207  	return rs
   208  }
   209  
   210  type ProjectsLocationsOperationsService struct {
   211  	s *Service
   212  }
   213  
   214  // AdminSettings: Looker instance Admin settings fields.
   215  type AdminSettings struct {
   216  	// AllowedEmailDomains: Email domain allowlist for the instance.
   217  	AllowedEmailDomains []string `json:"allowedEmailDomains,omitempty"`
   218  	// ForceSendFields is a list of field names (e.g. "AllowedEmailDomains") to
   219  	// unconditionally include in API requests. By default, fields with empty or
   220  	// default values are omitted from API requests. See
   221  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   222  	// details.
   223  	ForceSendFields []string `json:"-"`
   224  	// NullFields is a list of field names (e.g. "AllowedEmailDomains") to include
   225  	// in API requests with the JSON null value. By default, fields with empty
   226  	// values are omitted from API requests. See
   227  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   228  	NullFields []string `json:"-"`
   229  }
   230  
   231  func (s *AdminSettings) MarshalJSON() ([]byte, error) {
   232  	type NoMethod AdminSettings
   233  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   234  }
   235  
   236  // AuditConfig: Specifies the audit configuration for a service. The
   237  // configuration determines which permission types are logged, and what
   238  // identities, if any, are exempted from logging. An AuditConfig must have one
   239  // or more AuditLogConfigs. If there are AuditConfigs for both `allServices`
   240  // and a specific service, the union of the two AuditConfigs is used for that
   241  // service: the log_types specified in each AuditConfig are enabled, and the
   242  // exempted_members in each AuditLogConfig are exempted. Example Policy with
   243  // multiple AuditConfigs: { "audit_configs": [ { "service": "allServices",
   244  // "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [
   245  // "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" }, { "log_type":
   246  // "ADMIN_READ" } ] }, { "service": "sampleservice.googleapis.com",
   247  // "audit_log_configs": [ { "log_type": "DATA_READ" }, { "log_type":
   248  // "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For
   249  // sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ
   250  // logging. It also exempts `jose@example.com` from DATA_READ logging, and
   251  // `aliya@example.com` from DATA_WRITE logging.
   252  type AuditConfig struct {
   253  	// AuditLogConfigs: The configuration for logging of each type of permission.
   254  	AuditLogConfigs []*AuditLogConfig `json:"auditLogConfigs,omitempty"`
   255  	// Service: Specifies a service that will be enabled for audit logging. For
   256  	// example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices`
   257  	// is a special value that covers all services.
   258  	Service string `json:"service,omitempty"`
   259  	// ForceSendFields is a list of field names (e.g. "AuditLogConfigs") to
   260  	// unconditionally include in API requests. By default, fields with empty or
   261  	// default values are omitted from API requests. See
   262  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   263  	// details.
   264  	ForceSendFields []string `json:"-"`
   265  	// NullFields is a list of field names (e.g. "AuditLogConfigs") to include in
   266  	// API requests with the JSON null value. By default, fields with empty values
   267  	// are omitted from API requests. See
   268  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   269  	NullFields []string `json:"-"`
   270  }
   271  
   272  func (s *AuditConfig) MarshalJSON() ([]byte, error) {
   273  	type NoMethod AuditConfig
   274  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   275  }
   276  
   277  // AuditLogConfig: Provides the configuration for logging a type of
   278  // permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ",
   279  // "exempted_members": [ "user:jose@example.com" ] }, { "log_type":
   280  // "DATA_WRITE" } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while
   281  // exempting jose@example.com from DATA_READ logging.
   282  type AuditLogConfig struct {
   283  	// ExemptedMembers: Specifies the identities that do not cause logging for this
   284  	// type of permission. Follows the same format of Binding.members.
   285  	ExemptedMembers []string `json:"exemptedMembers,omitempty"`
   286  	// LogType: The log type that this config enables.
   287  	//
   288  	// Possible values:
   289  	//   "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this.
   290  	//   "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy
   291  	//   "DATA_WRITE" - Data writes. Example: CloudSQL Users create
   292  	//   "DATA_READ" - Data reads. Example: CloudSQL Users list
   293  	LogType string `json:"logType,omitempty"`
   294  	// ForceSendFields is a list of field names (e.g. "ExemptedMembers") to
   295  	// unconditionally include in API requests. By default, fields with empty or
   296  	// default values are omitted from API requests. See
   297  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   298  	// details.
   299  	ForceSendFields []string `json:"-"`
   300  	// NullFields is a list of field names (e.g. "ExemptedMembers") to include in
   301  	// API requests with the JSON null value. By default, fields with empty values
   302  	// are omitted from API requests. See
   303  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   304  	NullFields []string `json:"-"`
   305  }
   306  
   307  func (s *AuditLogConfig) MarshalJSON() ([]byte, error) {
   308  	type NoMethod AuditLogConfig
   309  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   310  }
   311  
   312  // Binding: Associates `members`, or principals, with a `role`.
   313  type Binding struct {
   314  	// Condition: The condition that is associated with this binding. If the
   315  	// condition evaluates to `true`, then this binding applies to the current
   316  	// request. If the condition evaluates to `false`, then this binding does not
   317  	// apply to the current request. However, a different role binding might grant
   318  	// the same role to one or more of the principals in this binding. To learn
   319  	// which resources support conditions in their IAM policies, see the IAM
   320  	// documentation
   321  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
   322  	Condition *Expr `json:"condition,omitempty"`
   323  	// Members: Specifies the principals requesting access for a Google Cloud
   324  	// resource. `members` can have the following values: * `allUsers`: A special
   325  	// identifier that represents anyone who is on the internet; with or without a
   326  	// Google account. * `allAuthenticatedUsers`: A special identifier that
   327  	// represents anyone who is authenticated with a Google account or a service
   328  	// account. Does not include identities that come from external identity
   329  	// providers (IdPs) through identity federation. * `user:{emailid}`: An email
   330  	// address that represents a specific Google account. For example,
   331  	// `alice@example.com` . * `serviceAccount:{emailid}`: An email address that
   332  	// represents a Google service account. For example,
   333  	// `my-other-app@appspot.gserviceaccount.com`. *
   334  	// `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`: An
   335  	// identifier for a Kubernetes service account
   336  	// (https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts).
   337  	// For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`. *
   338  	// `group:{emailid}`: An email address that represents a Google group. For
   339  	// example, `admins@example.com`. * `domain:{domain}`: The G Suite domain
   340  	// (primary) that represents all the users of that domain. For example,
   341  	// `google.com` or `example.com`. *
   342  	// `principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/sub
   343  	// ject/{subject_attribute_value}`: A single identity in a workforce identity
   344  	// pool. *
   345  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   346  	// group/{group_id}`: All workforce identities in a group. *
   347  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   348  	// attribute.{attribute_name}/{attribute_value}`: All workforce identities with
   349  	// a specific attribute value. *
   350  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   351  	// *`: All identities in a workforce identity pool. *
   352  	// `principal://iam.googleapis.com/projects/{project_number}/locations/global/wo
   353  	// rkloadIdentityPools/{pool_id}/subject/{subject_attribute_value}`: A single
   354  	// identity in a workload identity pool. *
   355  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   356  	// /workloadIdentityPools/{pool_id}/group/{group_id}`: A workload identity pool
   357  	// group. *
   358  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   359  	// /workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{attribute_value}
   360  	// `: All identities in a workload identity pool with a certain attribute. *
   361  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   362  	// /workloadIdentityPools/{pool_id}/*`: All identities in a workload identity
   363  	// pool. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus
   364  	// unique identifier) representing a user that has been recently deleted. For
   365  	// example, `alice@example.com?uid=123456789012345678901`. If the user is
   366  	// recovered, this value reverts to `user:{emailid}` and the recovered user
   367  	// retains the role in the binding. *
   368  	// `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
   369  	// unique identifier) representing a service account that has been recently
   370  	// deleted. For example,
   371  	// `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the
   372  	// service account is undeleted, this value reverts to
   373  	// `serviceAccount:{emailid}` and the undeleted service account retains the
   374  	// role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email
   375  	// address (plus unique identifier) representing a Google group that has been
   376  	// recently deleted. For example,
   377  	// `admins@example.com?uid=123456789012345678901`. If the group is recovered,
   378  	// this value reverts to `group:{emailid}` and the recovered group retains the
   379  	// role in the binding. *
   380  	// `deleted:principal://iam.googleapis.com/locations/global/workforcePools/{pool
   381  	// _id}/subject/{subject_attribute_value}`: Deleted single identity in a
   382  	// workforce identity pool. For example,
   383  	// `deleted:principal://iam.googleapis.com/locations/global/workforcePools/my-po
   384  	// ol-id/subject/my-subject-attribute-value`.
   385  	Members []string `json:"members,omitempty"`
   386  	// Role: Role that is assigned to the list of `members`, or principals. For
   387  	// example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview
   388  	// of the IAM roles and permissions, see the IAM documentation
   389  	// (https://cloud.google.com/iam/docs/roles-overview). For a list of the
   390  	// available pre-defined roles, see here
   391  	// (https://cloud.google.com/iam/docs/understanding-roles).
   392  	Role string `json:"role,omitempty"`
   393  	// ForceSendFields is a list of field names (e.g. "Condition") to
   394  	// unconditionally include in API requests. By default, fields with empty or
   395  	// default values are omitted from API requests. See
   396  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   397  	// details.
   398  	ForceSendFields []string `json:"-"`
   399  	// NullFields is a list of field names (e.g. "Condition") to include in API
   400  	// requests with the JSON null value. By default, fields with empty values are
   401  	// omitted from API requests. See
   402  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   403  	NullFields []string `json:"-"`
   404  }
   405  
   406  func (s *Binding) MarshalJSON() ([]byte, error) {
   407  	type NoMethod Binding
   408  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   409  }
   410  
   411  // CancelOperationRequest: The request message for Operations.CancelOperation.
   412  type CancelOperationRequest struct {
   413  }
   414  
   415  // CustomDomain: Custom domain information.
   416  type CustomDomain struct {
   417  	// Domain: Domain name.
   418  	Domain string `json:"domain,omitempty"`
   419  	// State: Domain state.
   420  	//
   421  	// Possible values:
   422  	//   "CUSTOM_DOMAIN_STATE_UNSPECIFIED" - Unspecified state.
   423  	//   "UNVERIFIED" - DNS record is not created.
   424  	//   "VERIFIED" - DNS record is created.
   425  	//   "MODIFYING" - Calling SLM to update.
   426  	//   "AVAILABLE" - ManagedCertificate is ready.
   427  	//   "UNAVAILABLE" - ManagedCertificate is not ready.
   428  	//   "UNKNOWN" - Status is not known.
   429  	State string `json:"state,omitempty"`
   430  	// ForceSendFields is a list of field names (e.g. "Domain") to unconditionally
   431  	// include in API requests. By default, fields with empty or default values are
   432  	// omitted from API requests. See
   433  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   434  	// details.
   435  	ForceSendFields []string `json:"-"`
   436  	// NullFields is a list of field names (e.g. "Domain") to include in API
   437  	// requests with the JSON null value. By default, fields with empty values are
   438  	// omitted from API requests. See
   439  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   440  	NullFields []string `json:"-"`
   441  }
   442  
   443  func (s *CustomDomain) MarshalJSON() ([]byte, error) {
   444  	type NoMethod CustomDomain
   445  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   446  }
   447  
   448  // Date: Represents a whole or partial calendar date, such as a birthday. The
   449  // time of day and time zone are either specified elsewhere or are
   450  // insignificant. The date is relative to the Gregorian Calendar. This can
   451  // represent one of the following: * A full date, with non-zero year, month,
   452  // and day values. * A month and day, with a zero year (for example, an
   453  // anniversary). * A year on its own, with a zero month and a zero day. * A
   454  // year and month, with a zero day (for example, a credit card expiration
   455  // date). Related types: * google.type.TimeOfDay * google.type.DateTime *
   456  // google.protobuf.Timestamp
   457  type Date struct {
   458  	// Day: Day of a month. Must be from 1 to 31 and valid for the year and month,
   459  	// or 0 to specify a year by itself or a year and month where the day isn't
   460  	// significant.
   461  	Day int64 `json:"day,omitempty"`
   462  	// Month: Month of a year. Must be from 1 to 12, or 0 to specify a year without
   463  	// a month and day.
   464  	Month int64 `json:"month,omitempty"`
   465  	// Year: Year of the date. Must be from 1 to 9999, or 0 to specify a date
   466  	// without a year.
   467  	Year int64 `json:"year,omitempty"`
   468  	// ForceSendFields is a list of field names (e.g. "Day") to unconditionally
   469  	// include in API requests. By default, fields with empty or default values are
   470  	// omitted from API requests. See
   471  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   472  	// details.
   473  	ForceSendFields []string `json:"-"`
   474  	// NullFields is a list of field names (e.g. "Day") to include in API requests
   475  	// with the JSON null value. By default, fields with empty values are omitted
   476  	// from API requests. See
   477  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   478  	NullFields []string `json:"-"`
   479  }
   480  
   481  func (s *Date) MarshalJSON() ([]byte, error) {
   482  	type NoMethod Date
   483  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   484  }
   485  
   486  // DenyMaintenancePeriod: Specifies the maintenance denial period.
   487  type DenyMaintenancePeriod struct {
   488  	// EndDate: Required. End date of the deny maintenance period.
   489  	EndDate *Date `json:"endDate,omitempty"`
   490  	// StartDate: Required. Start date of the deny maintenance period.
   491  	StartDate *Date `json:"startDate,omitempty"`
   492  	// Time: Required. Time in UTC when the period starts and ends.
   493  	Time *TimeOfDay `json:"time,omitempty"`
   494  	// ForceSendFields is a list of field names (e.g. "EndDate") to unconditionally
   495  	// include in API requests. By default, fields with empty or default values are
   496  	// omitted from API requests. See
   497  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   498  	// details.
   499  	ForceSendFields []string `json:"-"`
   500  	// NullFields is a list of field names (e.g. "EndDate") to include in API
   501  	// requests with the JSON null value. By default, fields with empty values are
   502  	// omitted from API requests. See
   503  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   504  	NullFields []string `json:"-"`
   505  }
   506  
   507  func (s *DenyMaintenancePeriod) MarshalJSON() ([]byte, error) {
   508  	type NoMethod DenyMaintenancePeriod
   509  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   510  }
   511  
   512  // Empty: A generic empty message that you can re-use to avoid defining
   513  // duplicated empty messages in your APIs. A typical example is to use it as
   514  // the request or the response type of an API method. For instance: service Foo
   515  // { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
   516  type Empty struct {
   517  	// ServerResponse contains the HTTP response code and headers from the server.
   518  	googleapi.ServerResponse `json:"-"`
   519  }
   520  
   521  // EncryptionConfig: Encryption configuration (i.e. CMEK).
   522  type EncryptionConfig struct {
   523  	// KmsKeyName: Name of the CMEK key in KMS (input parameter).
   524  	KmsKeyName string `json:"kmsKeyName,omitempty"`
   525  	// KmsKeyNameVersion: Output only. Full name and version of the CMEK key
   526  	// currently in use to encrypt Looker data. Format:
   527  	// `projects/{project}/locations/{location}/keyRings/{ring}/cryptoKeys/{key}/cry
   528  	// ptoKeyVersions/{version}`. Empty if CMEK is not configured in this instance.
   529  	KmsKeyNameVersion string `json:"kmsKeyNameVersion,omitempty"`
   530  	// KmsKeyState: Output only. Status of the CMEK key.
   531  	//
   532  	// Possible values:
   533  	//   "KMS_KEY_STATE_UNSPECIFIED" - CMEK status not specified.
   534  	//   "VALID" - CMEK key is currently valid.
   535  	//   "REVOKED" - CMEK key is currently revoked (instance should in restricted
   536  	// mode).
   537  	KmsKeyState string `json:"kmsKeyState,omitempty"`
   538  	// ForceSendFields is a list of field names (e.g. "KmsKeyName") to
   539  	// unconditionally include in API requests. By default, fields with empty or
   540  	// default values are omitted from API requests. See
   541  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   542  	// details.
   543  	ForceSendFields []string `json:"-"`
   544  	// NullFields is a list of field names (e.g. "KmsKeyName") to include in API
   545  	// requests with the JSON null value. By default, fields with empty values are
   546  	// omitted from API requests. See
   547  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   548  	NullFields []string `json:"-"`
   549  }
   550  
   551  func (s *EncryptionConfig) MarshalJSON() ([]byte, error) {
   552  	type NoMethod EncryptionConfig
   553  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   554  }
   555  
   556  // ExportEncryptionConfig: Configuration for Encryption - e.g. CMEK.
   557  type ExportEncryptionConfig struct {
   558  	// KmsKeyName: Required. Name of the CMEK key in KMS.
   559  	KmsKeyName string `json:"kmsKeyName,omitempty"`
   560  	// ForceSendFields is a list of field names (e.g. "KmsKeyName") to
   561  	// unconditionally include in API requests. By default, fields with empty or
   562  	// default values are omitted from API requests. See
   563  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   564  	// details.
   565  	ForceSendFields []string `json:"-"`
   566  	// NullFields is a list of field names (e.g. "KmsKeyName") to include in API
   567  	// requests with the JSON null value. By default, fields with empty values are
   568  	// omitted from API requests. See
   569  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   570  	NullFields []string `json:"-"`
   571  }
   572  
   573  func (s *ExportEncryptionConfig) MarshalJSON() ([]byte, error) {
   574  	type NoMethod ExportEncryptionConfig
   575  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   576  }
   577  
   578  // ExportInstanceRequest: Request options for exporting data of an Instance.
   579  type ExportInstanceRequest struct {
   580  	// EncryptionConfig: Required. Encryption configuration (CMEK). For CMEK
   581  	// enabled instances it should be same as looker CMEK.
   582  	EncryptionConfig *ExportEncryptionConfig `json:"encryptionConfig,omitempty"`
   583  	// GcsUri: The path to the folder in Google Cloud Storage where the export will
   584  	// be stored. The URI is in the form `gs://bucketName/folderName`.
   585  	GcsUri string `json:"gcsUri,omitempty"`
   586  	// ForceSendFields is a list of field names (e.g. "EncryptionConfig") to
   587  	// unconditionally include in API requests. By default, fields with empty or
   588  	// default values are omitted from API requests. See
   589  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   590  	// details.
   591  	ForceSendFields []string `json:"-"`
   592  	// NullFields is a list of field names (e.g. "EncryptionConfig") to include in
   593  	// API requests with the JSON null value. By default, fields with empty values
   594  	// are omitted from API requests. See
   595  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   596  	NullFields []string `json:"-"`
   597  }
   598  
   599  func (s *ExportInstanceRequest) MarshalJSON() ([]byte, error) {
   600  	type NoMethod ExportInstanceRequest
   601  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   602  }
   603  
   604  // ExportMetadata: ExportMetadata represents the metadata of the exported
   605  // artifacts. The metadata.json file in export artifact can be parsed as this
   606  // message
   607  type ExportMetadata struct {
   608  	// ExportEncryptionKey: Encryption key that was used to encrypt the export
   609  	// artifacts.
   610  	ExportEncryptionKey *ExportMetadataEncryptionKey `json:"exportEncryptionKey,omitempty"`
   611  	// FilePaths: List of files created as part of export artifact (excluding the
   612  	// metadata). The paths are relative to the folder containing the metadata.
   613  	FilePaths []string `json:"filePaths,omitempty"`
   614  	// LookerEncryptionKey: Looker encryption key, encrypted with the provided
   615  	// export encryption key. This value will only be populated if the looker
   616  	// instance uses Looker managed encryption instead of CMEK.
   617  	LookerEncryptionKey string `json:"lookerEncryptionKey,omitempty"`
   618  	// LookerInstance: Name of the exported instance. Format:
   619  	// projects/{project}/locations/{location}/instances/{instance}
   620  	LookerInstance string `json:"lookerInstance,omitempty"`
   621  	// LookerPlatformEdition: Platform edition of the exported instance.
   622  	LookerPlatformEdition string `json:"lookerPlatformEdition,omitempty"`
   623  	// LookerVersion: Version of instance when the export was created.
   624  	LookerVersion string `json:"lookerVersion,omitempty"`
   625  	// Source: The source type of the migration.
   626  	//
   627  	// Possible values:
   628  	//   "SOURCE_UNSPECIFIED" - Source not specified
   629  	//   "LOOKER_CORE" - Source of export is Looker Core
   630  	//   "LOOKER_ORIGINAL" - Source of export is Looker Original
   631  	Source string `json:"source,omitempty"`
   632  	// ForceSendFields is a list of field names (e.g. "ExportEncryptionKey") to
   633  	// unconditionally include in API requests. By default, fields with empty or
   634  	// default values are omitted from API requests. See
   635  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   636  	// details.
   637  	ForceSendFields []string `json:"-"`
   638  	// NullFields is a list of field names (e.g. "ExportEncryptionKey") to include
   639  	// in API requests with the JSON null value. By default, fields with empty
   640  	// values are omitted from API requests. See
   641  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   642  	NullFields []string `json:"-"`
   643  }
   644  
   645  func (s *ExportMetadata) MarshalJSON() ([]byte, error) {
   646  	type NoMethod ExportMetadata
   647  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   648  }
   649  
   650  // ExportMetadataEncryptionKey: Encryption key details for the exported
   651  // artifact.
   652  type ExportMetadataEncryptionKey struct {
   653  	// Cmek: Name of the CMEK.
   654  	Cmek string `json:"cmek,omitempty"`
   655  	// Version: Version of the CMEK.
   656  	Version string `json:"version,omitempty"`
   657  	// ForceSendFields is a list of field names (e.g. "Cmek") to unconditionally
   658  	// include in API requests. By default, fields with empty or default values are
   659  	// omitted from API requests. See
   660  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   661  	// details.
   662  	ForceSendFields []string `json:"-"`
   663  	// NullFields is a list of field names (e.g. "Cmek") to include in API requests
   664  	// with the JSON null value. By default, fields with empty values are omitted
   665  	// from API requests. See
   666  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   667  	NullFields []string `json:"-"`
   668  }
   669  
   670  func (s *ExportMetadataEncryptionKey) MarshalJSON() ([]byte, error) {
   671  	type NoMethod ExportMetadataEncryptionKey
   672  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   673  }
   674  
   675  // Expr: Represents a textual expression in the Common Expression Language
   676  // (CEL) syntax. CEL is a C-like expression language. The syntax and semantics
   677  // of CEL are documented at https://github.com/google/cel-spec. Example
   678  // (Comparison): title: "Summary size limit" description: "Determines if a
   679  // summary is less than 100 chars" expression: "document.summary.size() < 100"
   680  // Example (Equality): title: "Requestor is owner" description: "Determines if
   681  // requestor is the document owner" expression: "document.owner ==
   682  // request.auth.claims.email" Example (Logic): title: "Public documents"
   683  // description: "Determine whether the document should be publicly visible"
   684  // expression: "document.type != 'private' && document.type != 'internal'"
   685  // Example (Data Manipulation): title: "Notification string" description:
   686  // "Create a notification string with a timestamp." expression: "'New message
   687  // received at ' + string(document.create_time)" The exact variables and
   688  // functions that may be referenced within an expression are determined by the
   689  // service that evaluates it. See the service documentation for additional
   690  // information.
   691  type Expr struct {
   692  	// Description: Optional. Description of the expression. This is a longer text
   693  	// which describes the expression, e.g. when hovered over it in a UI.
   694  	Description string `json:"description,omitempty"`
   695  	// Expression: Textual representation of an expression in Common Expression
   696  	// Language syntax.
   697  	Expression string `json:"expression,omitempty"`
   698  	// Location: Optional. String indicating the location of the expression for
   699  	// error reporting, e.g. a file name and a position in the file.
   700  	Location string `json:"location,omitempty"`
   701  	// Title: Optional. Title for the expression, i.e. a short string describing
   702  	// its purpose. This can be used e.g. in UIs which allow to enter the
   703  	// expression.
   704  	Title string `json:"title,omitempty"`
   705  	// ForceSendFields is a list of field names (e.g. "Description") to
   706  	// unconditionally include in API requests. By default, fields with empty or
   707  	// default values are omitted from API requests. See
   708  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   709  	// details.
   710  	ForceSendFields []string `json:"-"`
   711  	// NullFields is a list of field names (e.g. "Description") to include in API
   712  	// requests with the JSON null value. By default, fields with empty values are
   713  	// omitted from API requests. See
   714  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   715  	NullFields []string `json:"-"`
   716  }
   717  
   718  func (s *Expr) MarshalJSON() ([]byte, error) {
   719  	type NoMethod Expr
   720  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   721  }
   722  
   723  // ImportInstanceRequest: Requestion options for importing looker data to an
   724  // Instance
   725  type ImportInstanceRequest struct {
   726  	// GcsUri: Path to the import folder in Google Cloud Storage, in the form
   727  	// `gs://bucketName/folderName`.
   728  	GcsUri string `json:"gcsUri,omitempty"`
   729  	// ForceSendFields is a list of field names (e.g. "GcsUri") to unconditionally
   730  	// include in API requests. By default, fields with empty or default values are
   731  	// omitted from API requests. See
   732  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   733  	// details.
   734  	ForceSendFields []string `json:"-"`
   735  	// NullFields is a list of field names (e.g. "GcsUri") to include in API
   736  	// requests with the JSON null value. By default, fields with empty values are
   737  	// omitted from API requests. See
   738  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   739  	NullFields []string `json:"-"`
   740  }
   741  
   742  func (s *ImportInstanceRequest) MarshalJSON() ([]byte, error) {
   743  	type NoMethod ImportInstanceRequest
   744  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   745  }
   746  
   747  // Instance: A Looker instance. LINT.IfChange
   748  type Instance struct {
   749  	// AdminSettings: Looker Instance Admin settings.
   750  	AdminSettings *AdminSettings `json:"adminSettings,omitempty"`
   751  	// ConsumerNetwork: Network name in the consumer project. Format:
   752  	// `projects/{project}/global/networks/{network}`. Note that the consumer
   753  	// network may be in a different GCP project than the consumer project that is
   754  	// hosting the Looker Instance.
   755  	ConsumerNetwork string `json:"consumerNetwork,omitempty"`
   756  	// CreateTime: Output only. The time when the Looker instance provisioning was
   757  	// first requested.
   758  	CreateTime   string        `json:"createTime,omitempty"`
   759  	CustomDomain *CustomDomain `json:"customDomain,omitempty"`
   760  	// DenyMaintenancePeriod: Maintenance denial period for this instance.
   761  	DenyMaintenancePeriod *DenyMaintenancePeriod `json:"denyMaintenancePeriod,omitempty"`
   762  	// EgressPublicIp: Output only. Public Egress IP (IPv4).
   763  	EgressPublicIp string `json:"egressPublicIp,omitempty"`
   764  	// EncryptionConfig: Encryption configuration (CMEK). Only set if CMEK has been
   765  	// enabled on the instance.
   766  	EncryptionConfig *EncryptionConfig `json:"encryptionConfig,omitempty"`
   767  	// IngressPrivateIp: Output only. Private Ingress IP (IPv4).
   768  	IngressPrivateIp string `json:"ingressPrivateIp,omitempty"`
   769  	// IngressPublicIp: Output only. Public Ingress IP (IPv4).
   770  	IngressPublicIp string `json:"ingressPublicIp,omitempty"`
   771  	// LastDenyMaintenancePeriod: Output only. Last computed maintenance denial
   772  	// period for this instance.
   773  	LastDenyMaintenancePeriod *DenyMaintenancePeriod `json:"lastDenyMaintenancePeriod,omitempty"`
   774  	// LinkedLspProjectNumber: Optional. Linked Google Cloud Project Number for
   775  	// Looker Studio Pro.
   776  	LinkedLspProjectNumber int64 `json:"linkedLspProjectNumber,omitempty,string"`
   777  	// LookerUri: Output only. Looker instance URI which can be used to access the
   778  	// Looker Instance UI.
   779  	LookerUri string `json:"lookerUri,omitempty"`
   780  	// LookerVersion: Output only. The Looker version that the instance is using.
   781  	LookerVersion string `json:"lookerVersion,omitempty"`
   782  	// MaintenanceSchedule: Maintenance schedule for this instance.
   783  	MaintenanceSchedule *MaintenanceSchedule `json:"maintenanceSchedule,omitempty"`
   784  	// MaintenanceWindow: Maintenance window for this instance.
   785  	MaintenanceWindow *MaintenanceWindow `json:"maintenanceWindow,omitempty"`
   786  	// Name: Output only. Format:
   787  	// `projects/{project}/locations/{location}/instances/{instance}`.
   788  	Name string `json:"name,omitempty"`
   789  	// OauthConfig: Looker instance OAuth login settings.
   790  	OauthConfig *OAuthConfig `json:"oauthConfig,omitempty"`
   791  	// PlatformEdition: Platform edition.
   792  	//
   793  	// Possible values:
   794  	//   "PLATFORM_EDITION_UNSPECIFIED" - Platform edition is unspecified.
   795  	//   "LOOKER_CORE_TRIAL" - Trial.
   796  	//   "LOOKER_CORE_STANDARD" - Standard.
   797  	//   "LOOKER_CORE_STANDARD_ANNUAL" - Subscription Standard.
   798  	//   "LOOKER_CORE_ENTERPRISE_ANNUAL" - Subscription Enterprise.
   799  	//   "LOOKER_CORE_EMBED_ANNUAL" - Subscription Embed.
   800  	PlatformEdition string `json:"platformEdition,omitempty"`
   801  	// PrivateIpEnabled: Whether private IP is enabled on the Looker instance.
   802  	PrivateIpEnabled bool `json:"privateIpEnabled,omitempty"`
   803  	// PublicIpEnabled: Whether public IP is enabled on the Looker instance.
   804  	PublicIpEnabled bool `json:"publicIpEnabled,omitempty"`
   805  	// ReservedRange: Name of a reserved IP address range within the
   806  	// Instance.consumer_network, to be used for private services access
   807  	// connection. May or may not be specified in a create request.
   808  	ReservedRange string `json:"reservedRange,omitempty"`
   809  	// State: Output only. The state of the instance.
   810  	//
   811  	// Possible values:
   812  	//   "STATE_UNSPECIFIED" - State is unspecified.
   813  	//   "ACTIVE" - Instance is active and ready for use.
   814  	//   "CREATING" - Instance provisioning is in progress.
   815  	//   "FAILED" - Instance is in a failed state.
   816  	//   "SUSPENDED" - Instance was suspended.
   817  	//   "UPDATING" - Instance update is in progress.
   818  	//   "DELETING" - Instance delete is in progress.
   819  	//   "EXPORTING" - Instance is being exported.
   820  	//   "IMPORTING" - Instance is importing data.
   821  	State string `json:"state,omitempty"`
   822  	// UpdateTime: Output only. The time when the Looker instance was last updated.
   823  	UpdateTime string `json:"updateTime,omitempty"`
   824  	// UserMetadata: User metadata.
   825  	UserMetadata *UserMetadata `json:"userMetadata,omitempty"`
   826  
   827  	// ServerResponse contains the HTTP response code and headers from the server.
   828  	googleapi.ServerResponse `json:"-"`
   829  	// ForceSendFields is a list of field names (e.g. "AdminSettings") to
   830  	// unconditionally include in API requests. By default, fields with empty or
   831  	// default values are omitted from API requests. See
   832  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   833  	// details.
   834  	ForceSendFields []string `json:"-"`
   835  	// NullFields is a list of field names (e.g. "AdminSettings") to include in API
   836  	// requests with the JSON null value. By default, fields with empty values are
   837  	// omitted from API requests. See
   838  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   839  	NullFields []string `json:"-"`
   840  }
   841  
   842  func (s *Instance) MarshalJSON() ([]byte, error) {
   843  	type NoMethod Instance
   844  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   845  }
   846  
   847  // ListInstancesResponse: Response from ListInstances.
   848  type ListInstancesResponse struct {
   849  	// Instances: The list of instances matching the request filters, up to the
   850  	// requested ListInstancesRequest.pageSize.
   851  	Instances []*Instance `json:"instances,omitempty"`
   852  	// NextPageToken: If provided, a page token that can look up the next
   853  	// ListInstancesRequest.pageSize results. If empty, the results list is
   854  	// exhausted.
   855  	NextPageToken string `json:"nextPageToken,omitempty"`
   856  	// Unreachable: Locations that could not be reached.
   857  	Unreachable []string `json:"unreachable,omitempty"`
   858  
   859  	// ServerResponse contains the HTTP response code and headers from the server.
   860  	googleapi.ServerResponse `json:"-"`
   861  	// ForceSendFields is a list of field names (e.g. "Instances") to
   862  	// unconditionally include in API requests. By default, fields with empty or
   863  	// default values are omitted from API requests. See
   864  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   865  	// details.
   866  	ForceSendFields []string `json:"-"`
   867  	// NullFields is a list of field names (e.g. "Instances") to include in API
   868  	// requests with the JSON null value. By default, fields with empty values are
   869  	// omitted from API requests. See
   870  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   871  	NullFields []string `json:"-"`
   872  }
   873  
   874  func (s *ListInstancesResponse) MarshalJSON() ([]byte, error) {
   875  	type NoMethod ListInstancesResponse
   876  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   877  }
   878  
   879  // ListLocationsResponse: The response message for Locations.ListLocations.
   880  type ListLocationsResponse struct {
   881  	// Locations: A list of locations that matches the specified filter in the
   882  	// request.
   883  	Locations []*Location `json:"locations,omitempty"`
   884  	// NextPageToken: The standard List next-page token.
   885  	NextPageToken string `json:"nextPageToken,omitempty"`
   886  
   887  	// ServerResponse contains the HTTP response code and headers from the server.
   888  	googleapi.ServerResponse `json:"-"`
   889  	// ForceSendFields is a list of field names (e.g. "Locations") to
   890  	// unconditionally include in API requests. By default, fields with empty or
   891  	// default values are omitted from API requests. See
   892  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   893  	// details.
   894  	ForceSendFields []string `json:"-"`
   895  	// NullFields is a list of field names (e.g. "Locations") to include in API
   896  	// requests with the JSON null value. By default, fields with empty values are
   897  	// omitted from API requests. See
   898  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   899  	NullFields []string `json:"-"`
   900  }
   901  
   902  func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) {
   903  	type NoMethod ListLocationsResponse
   904  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   905  }
   906  
   907  // ListOperationsResponse: The response message for Operations.ListOperations.
   908  type ListOperationsResponse struct {
   909  	// NextPageToken: The standard List next-page token.
   910  	NextPageToken string `json:"nextPageToken,omitempty"`
   911  	// Operations: A list of operations that matches the specified filter in the
   912  	// request.
   913  	Operations []*Operation `json:"operations,omitempty"`
   914  
   915  	// ServerResponse contains the HTTP response code and headers from the server.
   916  	googleapi.ServerResponse `json:"-"`
   917  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
   918  	// unconditionally include in API requests. By default, fields with empty or
   919  	// default values are omitted from API requests. See
   920  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   921  	// details.
   922  	ForceSendFields []string `json:"-"`
   923  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
   924  	// requests with the JSON null value. By default, fields with empty values are
   925  	// omitted from API requests. See
   926  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   927  	NullFields []string `json:"-"`
   928  }
   929  
   930  func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
   931  	type NoMethod ListOperationsResponse
   932  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   933  }
   934  
   935  // Location: A resource that represents a Google Cloud location.
   936  type Location struct {
   937  	// DisplayName: The friendly name for this location, typically a nearby city
   938  	// name. For example, "Tokyo".
   939  	DisplayName string `json:"displayName,omitempty"`
   940  	// Labels: Cross-service attributes for the location. For example
   941  	// {"cloud.googleapis.com/region": "us-east1"}
   942  	Labels map[string]string `json:"labels,omitempty"`
   943  	// LocationId: The canonical id for this location. For example: "us-east1".
   944  	LocationId string `json:"locationId,omitempty"`
   945  	// Metadata: Service-specific metadata. For example the available capacity at
   946  	// the given location.
   947  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
   948  	// Name: Resource name for the location, which may vary between
   949  	// implementations. For example:
   950  	// "projects/example-project/locations/us-east1"
   951  	Name string `json:"name,omitempty"`
   952  
   953  	// ServerResponse contains the HTTP response code and headers from the server.
   954  	googleapi.ServerResponse `json:"-"`
   955  	// ForceSendFields is a list of field names (e.g. "DisplayName") to
   956  	// unconditionally include in API requests. By default, fields with empty or
   957  	// default values are omitted from API requests. See
   958  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   959  	// details.
   960  	ForceSendFields []string `json:"-"`
   961  	// NullFields is a list of field names (e.g. "DisplayName") to include in API
   962  	// requests with the JSON null value. By default, fields with empty values are
   963  	// omitted from API requests. See
   964  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   965  	NullFields []string `json:"-"`
   966  }
   967  
   968  func (s *Location) MarshalJSON() ([]byte, error) {
   969  	type NoMethod Location
   970  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   971  }
   972  
   973  // MaintenanceSchedule: Published upcoming future maintenance schedule.
   974  type MaintenanceSchedule struct {
   975  	// EndTime: The scheduled end time for the maintenance.
   976  	EndTime string `json:"endTime,omitempty"`
   977  	// StartTime: The scheduled start time for the maintenance.
   978  	StartTime string `json:"startTime,omitempty"`
   979  	// ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally
   980  	// include in API requests. By default, fields with empty or default values are
   981  	// omitted from API requests. See
   982  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   983  	// details.
   984  	ForceSendFields []string `json:"-"`
   985  	// NullFields is a list of field names (e.g. "EndTime") to include in API
   986  	// requests with the JSON null value. By default, fields with empty values are
   987  	// omitted from API requests. See
   988  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   989  	NullFields []string `json:"-"`
   990  }
   991  
   992  func (s *MaintenanceSchedule) MarshalJSON() ([]byte, error) {
   993  	type NoMethod MaintenanceSchedule
   994  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   995  }
   996  
   997  // MaintenanceWindow: Specifies the recurring maintenance window.
   998  type MaintenanceWindow struct {
   999  	// DayOfWeek: Required. Day of the week for this MaintenanceWindow (in UTC).
  1000  	//
  1001  	// Possible values:
  1002  	//   "DAY_OF_WEEK_UNSPECIFIED" - The day of the week is unspecified.
  1003  	//   "MONDAY" - Monday
  1004  	//   "TUESDAY" - Tuesday
  1005  	//   "WEDNESDAY" - Wednesday
  1006  	//   "THURSDAY" - Thursday
  1007  	//   "FRIDAY" - Friday
  1008  	//   "SATURDAY" - Saturday
  1009  	//   "SUNDAY" - Sunday
  1010  	DayOfWeek string `json:"dayOfWeek,omitempty"`
  1011  	// StartTime: Required. Time in UTC when the period starts. Maintenance will be
  1012  	// scheduled within 60 minutes.
  1013  	StartTime *TimeOfDay `json:"startTime,omitempty"`
  1014  	// ForceSendFields is a list of field names (e.g. "DayOfWeek") to
  1015  	// unconditionally include in API requests. By default, fields with empty or
  1016  	// default values are omitted from API requests. See
  1017  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1018  	// details.
  1019  	ForceSendFields []string `json:"-"`
  1020  	// NullFields is a list of field names (e.g. "DayOfWeek") to include in API
  1021  	// requests with the JSON null value. By default, fields with empty values are
  1022  	// omitted from API requests. See
  1023  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1024  	NullFields []string `json:"-"`
  1025  }
  1026  
  1027  func (s *MaintenanceWindow) MarshalJSON() ([]byte, error) {
  1028  	type NoMethod MaintenanceWindow
  1029  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1030  }
  1031  
  1032  // OAuthConfig: Looker instance OAuth login settings.
  1033  type OAuthConfig struct {
  1034  	// ClientId: Input only. Client ID from an external OAuth application. This is
  1035  	// an input-only field, and thus will not be set in any responses.
  1036  	ClientId string `json:"clientId,omitempty"`
  1037  	// ClientSecret: Input only. Client secret from an external OAuth application.
  1038  	// This is an input-only field, and thus will not be set in any responses.
  1039  	ClientSecret string `json:"clientSecret,omitempty"`
  1040  	// ForceSendFields is a list of field names (e.g. "ClientId") to
  1041  	// unconditionally include in API requests. By default, fields with empty or
  1042  	// default values are omitted from API requests. See
  1043  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1044  	// details.
  1045  	ForceSendFields []string `json:"-"`
  1046  	// NullFields is a list of field names (e.g. "ClientId") to include in API
  1047  	// requests with the JSON null value. By default, fields with empty values are
  1048  	// omitted from API requests. See
  1049  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1050  	NullFields []string `json:"-"`
  1051  }
  1052  
  1053  func (s *OAuthConfig) MarshalJSON() ([]byte, error) {
  1054  	type NoMethod OAuthConfig
  1055  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1056  }
  1057  
  1058  // Operation: This resource represents a long-running operation that is the
  1059  // result of a network API call.
  1060  type Operation struct {
  1061  	// Done: If the value is `false`, it means the operation is still in progress.
  1062  	// If `true`, the operation is completed, and either `error` or `response` is
  1063  	// available.
  1064  	Done bool `json:"done,omitempty"`
  1065  	// Error: The error result of the operation in case of failure or cancellation.
  1066  	Error *Status `json:"error,omitempty"`
  1067  	// Metadata: Service-specific metadata associated with the operation. It
  1068  	// typically contains progress information and common metadata such as create
  1069  	// time. Some services might not provide such metadata. Any method that returns
  1070  	// a long-running operation should document the metadata type, if any.
  1071  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  1072  	// Name: The server-assigned name, which is only unique within the same service
  1073  	// that originally returns it. If you use the default HTTP mapping, the `name`
  1074  	// should be a resource name ending with `operations/{unique_id}`.
  1075  	Name string `json:"name,omitempty"`
  1076  	// Response: The normal, successful response of the operation. If the original
  1077  	// method returns no data on success, such as `Delete`, the response is
  1078  	// `google.protobuf.Empty`. If the original method is standard
  1079  	// `Get`/`Create`/`Update`, the response should be the resource. For other
  1080  	// methods, the response should have the type `XxxResponse`, where `Xxx` is the
  1081  	// original method name. For example, if the original method name is
  1082  	// `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
  1083  	Response googleapi.RawMessage `json:"response,omitempty"`
  1084  
  1085  	// ServerResponse contains the HTTP response code and headers from the server.
  1086  	googleapi.ServerResponse `json:"-"`
  1087  	// ForceSendFields is a list of field names (e.g. "Done") to unconditionally
  1088  	// include in API requests. By default, fields with empty or default values are
  1089  	// omitted from API requests. See
  1090  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1091  	// details.
  1092  	ForceSendFields []string `json:"-"`
  1093  	// NullFields is a list of field names (e.g. "Done") to include in API requests
  1094  	// with the JSON null value. By default, fields with empty values are omitted
  1095  	// from API requests. See
  1096  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1097  	NullFields []string `json:"-"`
  1098  }
  1099  
  1100  func (s *Operation) MarshalJSON() ([]byte, error) {
  1101  	type NoMethod Operation
  1102  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1103  }
  1104  
  1105  // OperationMetadata: Represents the metadata of the long-running operation.
  1106  type OperationMetadata struct {
  1107  	// ApiVersion: API version used to start the operation.
  1108  	ApiVersion string `json:"apiVersion,omitempty"`
  1109  	// CreateTime: The time the operation was created.
  1110  	CreateTime string `json:"createTime,omitempty"`
  1111  	// EndTime: The time the operation finished running.
  1112  	EndTime string `json:"endTime,omitempty"`
  1113  	// RequestedCancellation: Identifies whether the user has requested
  1114  	// cancellation of the operation. Operations that have successfully been
  1115  	// cancelled have Operation.error value with a google.rpc.Status.code of 1,
  1116  	// corresponding to `Code.CANCELLED`.
  1117  	RequestedCancellation bool `json:"requestedCancellation,omitempty"`
  1118  	// StatusMessage: Human-readable status of the operation, if any.
  1119  	StatusMessage string `json:"statusMessage,omitempty"`
  1120  	// Target: Server-defined resource path for the target of the operation.
  1121  	Target string `json:"target,omitempty"`
  1122  	// Verb: Name of the verb executed by the operation.
  1123  	Verb string `json:"verb,omitempty"`
  1124  	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
  1125  	// unconditionally include in API requests. By default, fields with empty or
  1126  	// default values are omitted from API requests. See
  1127  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1128  	// details.
  1129  	ForceSendFields []string `json:"-"`
  1130  	// NullFields is a list of field names (e.g. "ApiVersion") to include in API
  1131  	// requests with the JSON null value. By default, fields with empty values are
  1132  	// omitted from API requests. See
  1133  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1134  	NullFields []string `json:"-"`
  1135  }
  1136  
  1137  func (s *OperationMetadata) MarshalJSON() ([]byte, error) {
  1138  	type NoMethod OperationMetadata
  1139  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1140  }
  1141  
  1142  // Policy: An Identity and Access Management (IAM) policy, which specifies
  1143  // access controls for Google Cloud resources. A `Policy` is a collection of
  1144  // `bindings`. A `binding` binds one or more `members`, or principals, to a
  1145  // single `role`. Principals can be user accounts, service accounts, Google
  1146  // groups, and domains (such as G Suite). A `role` is a named list of
  1147  // permissions; each `role` can be an IAM predefined role or a user-created
  1148  // custom role. For some types of Google Cloud resources, a `binding` can also
  1149  // specify a `condition`, which is a logical expression that allows access to a
  1150  // resource only if the expression evaluates to `true`. A condition can add
  1151  // constraints based on attributes of the request, the resource, or both. To
  1152  // learn which resources support conditions in their IAM policies, see the IAM
  1153  // documentation
  1154  // (https://cloud.google.com/iam/help/conditions/resource-policies). **JSON
  1155  // example:** ``` { "bindings": [ { "role":
  1156  // "roles/resourcemanager.organizationAdmin", "members": [
  1157  // "user:mike@example.com", "group:admins@example.com", "domain:google.com",
  1158  // "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role":
  1159  // "roles/resourcemanager.organizationViewer", "members": [
  1160  // "user:eve@example.com" ], "condition": { "title": "expirable access",
  1161  // "description": "Does not grant access after Sep 2020", "expression":
  1162  // "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag":
  1163  // "BwWWja0YfJA=", "version": 3 } ``` **YAML example:** ``` bindings: -
  1164  // members: - user:mike@example.com - group:admins@example.com -
  1165  // domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com
  1166  // role: roles/resourcemanager.organizationAdmin - members: -
  1167  // user:eve@example.com role: roles/resourcemanager.organizationViewer
  1168  // condition: title: expirable access description: Does not grant access after
  1169  // Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
  1170  // etag: BwWWja0YfJA= version: 3 ``` For a description of IAM and its features,
  1171  // see the IAM documentation (https://cloud.google.com/iam/docs/).
  1172  type Policy struct {
  1173  	// AuditConfigs: Specifies cloud audit logging configuration for this policy.
  1174  	AuditConfigs []*AuditConfig `json:"auditConfigs,omitempty"`
  1175  	// Bindings: Associates a list of `members`, or principals, with a `role`.
  1176  	// Optionally, may specify a `condition` that determines how and when the
  1177  	// `bindings` are applied. Each of the `bindings` must contain at least one
  1178  	// principal. The `bindings` in a `Policy` can refer to up to 1,500 principals;
  1179  	// up to 250 of these principals can be Google groups. Each occurrence of a
  1180  	// principal counts towards these limits. For example, if the `bindings` grant
  1181  	// 50 different roles to `user:alice@example.com`, and not to any other
  1182  	// principal, then you can add another 1,450 principals to the `bindings` in
  1183  	// the `Policy`.
  1184  	Bindings []*Binding `json:"bindings,omitempty"`
  1185  	// Etag: `etag` is used for optimistic concurrency control as a way to help
  1186  	// prevent simultaneous updates of a policy from overwriting each other. It is
  1187  	// strongly suggested that systems make use of the `etag` in the
  1188  	// read-modify-write cycle to perform policy updates in order to avoid race
  1189  	// conditions: An `etag` is returned in the response to `getIamPolicy`, and
  1190  	// systems are expected to put that etag in the request to `setIamPolicy` to
  1191  	// ensure that their change will be applied to the same version of the policy.
  1192  	// **Important:** If you use IAM Conditions, you must include the `etag` field
  1193  	// whenever you call `setIamPolicy`. If you omit this field, then IAM allows
  1194  	// you to overwrite a version `3` policy with a version `1` policy, and all of
  1195  	// the conditions in the version `3` policy are lost.
  1196  	Etag string `json:"etag,omitempty"`
  1197  	// Version: Specifies the format of the policy. Valid values are `0`, `1`, and
  1198  	// `3`. Requests that specify an invalid value are rejected. Any operation that
  1199  	// affects conditional role bindings must specify version `3`. This requirement
  1200  	// applies to the following operations: * Getting a policy that includes a
  1201  	// conditional role binding * Adding a conditional role binding to a policy *
  1202  	// Changing a conditional role binding in a policy * Removing any role binding,
  1203  	// with or without a condition, from a policy that includes conditions
  1204  	// **Important:** If you use IAM Conditions, you must include the `etag` field
  1205  	// whenever you call `setIamPolicy`. If you omit this field, then IAM allows
  1206  	// you to overwrite a version `3` policy with a version `1` policy, and all of
  1207  	// the conditions in the version `3` policy are lost. If a policy does not
  1208  	// include any conditions, operations on that policy may specify any valid
  1209  	// version or leave the field unset. To learn which resources support
  1210  	// conditions in their IAM policies, see the IAM documentation
  1211  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
  1212  	Version int64 `json:"version,omitempty"`
  1213  
  1214  	// ServerResponse contains the HTTP response code and headers from the server.
  1215  	googleapi.ServerResponse `json:"-"`
  1216  	// ForceSendFields is a list of field names (e.g. "AuditConfigs") to
  1217  	// unconditionally include in API requests. By default, fields with empty or
  1218  	// default values are omitted from API requests. See
  1219  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1220  	// details.
  1221  	ForceSendFields []string `json:"-"`
  1222  	// NullFields is a list of field names (e.g. "AuditConfigs") to include in API
  1223  	// requests with the JSON null value. By default, fields with empty values are
  1224  	// omitted from API requests. See
  1225  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1226  	NullFields []string `json:"-"`
  1227  }
  1228  
  1229  func (s *Policy) MarshalJSON() ([]byte, error) {
  1230  	type NoMethod Policy
  1231  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1232  }
  1233  
  1234  // RestartInstanceRequest: Request options for restarting an instance.
  1235  type RestartInstanceRequest struct {
  1236  }
  1237  
  1238  // SetIamPolicyRequest: Request message for `SetIamPolicy` method.
  1239  type SetIamPolicyRequest struct {
  1240  	// Policy: REQUIRED: The complete policy to be applied to the `resource`. The
  1241  	// size of the policy is limited to a few 10s of KB. An empty policy is a valid
  1242  	// policy but certain Google Cloud services (such as Projects) might reject
  1243  	// them.
  1244  	Policy *Policy `json:"policy,omitempty"`
  1245  	// UpdateMask: OPTIONAL: A FieldMask specifying which fields of the policy to
  1246  	// modify. Only the fields in the mask will be modified. If no mask is
  1247  	// provided, the following default mask is used: `paths: "bindings, etag"
  1248  	UpdateMask string `json:"updateMask,omitempty"`
  1249  	// ForceSendFields is a list of field names (e.g. "Policy") to unconditionally
  1250  	// include in API requests. By default, fields with empty or default values are
  1251  	// omitted from API requests. See
  1252  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1253  	// details.
  1254  	ForceSendFields []string `json:"-"`
  1255  	// NullFields is a list of field names (e.g. "Policy") to include in API
  1256  	// requests with the JSON null value. By default, fields with empty values are
  1257  	// omitted from API requests. See
  1258  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1259  	NullFields []string `json:"-"`
  1260  }
  1261  
  1262  func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
  1263  	type NoMethod SetIamPolicyRequest
  1264  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1265  }
  1266  
  1267  // Status: The `Status` type defines a logical error model that is suitable for
  1268  // different programming environments, including REST APIs and RPC APIs. It is
  1269  // used by gRPC (https://github.com/grpc). Each `Status` message contains three
  1270  // pieces of data: error code, error message, and error details. You can find
  1271  // out more about this error model and how to work with it in the API Design
  1272  // Guide (https://cloud.google.com/apis/design/errors).
  1273  type Status struct {
  1274  	// Code: The status code, which should be an enum value of google.rpc.Code.
  1275  	Code int64 `json:"code,omitempty"`
  1276  	// Details: A list of messages that carry the error details. There is a common
  1277  	// set of message types for APIs to use.
  1278  	Details []googleapi.RawMessage `json:"details,omitempty"`
  1279  	// Message: A developer-facing error message, which should be in English. Any
  1280  	// user-facing error message should be localized and sent in the
  1281  	// google.rpc.Status.details field, or localized by the client.
  1282  	Message string `json:"message,omitempty"`
  1283  	// ForceSendFields is a list of field names (e.g. "Code") to unconditionally
  1284  	// include in API requests. By default, fields with empty or default values are
  1285  	// omitted from API requests. See
  1286  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1287  	// details.
  1288  	ForceSendFields []string `json:"-"`
  1289  	// NullFields is a list of field names (e.g. "Code") to include in API requests
  1290  	// with the JSON null value. By default, fields with empty values are omitted
  1291  	// from API requests. See
  1292  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1293  	NullFields []string `json:"-"`
  1294  }
  1295  
  1296  func (s *Status) MarshalJSON() ([]byte, error) {
  1297  	type NoMethod Status
  1298  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1299  }
  1300  
  1301  // TestIamPermissionsRequest: Request message for `TestIamPermissions` method.
  1302  type TestIamPermissionsRequest struct {
  1303  	// Permissions: The set of permissions to check for the `resource`. Permissions
  1304  	// with wildcards (such as `*` or `storage.*`) are not allowed. For more
  1305  	// information see IAM Overview
  1306  	// (https://cloud.google.com/iam/docs/overview#permissions).
  1307  	Permissions []string `json:"permissions,omitempty"`
  1308  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  1309  	// unconditionally include in API requests. By default, fields with empty or
  1310  	// default values are omitted from API requests. See
  1311  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1312  	// details.
  1313  	ForceSendFields []string `json:"-"`
  1314  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  1315  	// requests with the JSON null value. By default, fields with empty values are
  1316  	// omitted from API requests. See
  1317  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1318  	NullFields []string `json:"-"`
  1319  }
  1320  
  1321  func (s *TestIamPermissionsRequest) MarshalJSON() ([]byte, error) {
  1322  	type NoMethod TestIamPermissionsRequest
  1323  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1324  }
  1325  
  1326  // TestIamPermissionsResponse: Response message for `TestIamPermissions`
  1327  // method.
  1328  type TestIamPermissionsResponse struct {
  1329  	// Permissions: A subset of `TestPermissionsRequest.permissions` that the
  1330  	// caller is allowed.
  1331  	Permissions []string `json:"permissions,omitempty"`
  1332  
  1333  	// ServerResponse contains the HTTP response code and headers from the server.
  1334  	googleapi.ServerResponse `json:"-"`
  1335  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  1336  	// unconditionally include in API requests. By default, fields with empty or
  1337  	// default values are omitted from API requests. See
  1338  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1339  	// details.
  1340  	ForceSendFields []string `json:"-"`
  1341  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  1342  	// requests with the JSON null value. By default, fields with empty values are
  1343  	// omitted from API requests. See
  1344  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1345  	NullFields []string `json:"-"`
  1346  }
  1347  
  1348  func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) {
  1349  	type NoMethod TestIamPermissionsResponse
  1350  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1351  }
  1352  
  1353  // TimeOfDay: Represents a time of day. The date and time zone are either not
  1354  // significant or are specified elsewhere. An API may choose to allow leap
  1355  // seconds. Related types are google.type.Date and `google.protobuf.Timestamp`.
  1356  type TimeOfDay struct {
  1357  	// Hours: Hours of day in 24 hour format. Should be from 0 to 23. An API may
  1358  	// choose to allow the value "24:00:00" for scenarios like business closing
  1359  	// time.
  1360  	Hours int64 `json:"hours,omitempty"`
  1361  	// Minutes: Minutes of hour of day. Must be from 0 to 59.
  1362  	Minutes int64 `json:"minutes,omitempty"`
  1363  	// Nanos: Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.
  1364  	Nanos int64 `json:"nanos,omitempty"`
  1365  	// Seconds: Seconds of minutes of the time. Must normally be from 0 to 59. An
  1366  	// API may allow the value 60 if it allows leap-seconds.
  1367  	Seconds int64 `json:"seconds,omitempty"`
  1368  	// ForceSendFields is a list of field names (e.g. "Hours") to unconditionally
  1369  	// include in API requests. By default, fields with empty or default values are
  1370  	// omitted from API requests. See
  1371  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1372  	// details.
  1373  	ForceSendFields []string `json:"-"`
  1374  	// NullFields is a list of field names (e.g. "Hours") to include in API
  1375  	// requests with the JSON null value. By default, fields with empty values are
  1376  	// omitted from API requests. See
  1377  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1378  	NullFields []string `json:"-"`
  1379  }
  1380  
  1381  func (s *TimeOfDay) MarshalJSON() ([]byte, error) {
  1382  	type NoMethod TimeOfDay
  1383  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1384  }
  1385  
  1386  // UserMetadata: Metadata about users for a Looker instance.
  1387  type UserMetadata struct {
  1388  	// AdditionalDeveloperUserCount: Optional. The number of additional developer
  1389  	// users the instance owner has purchased.
  1390  	AdditionalDeveloperUserCount int64 `json:"additionalDeveloperUserCount,omitempty"`
  1391  	// AdditionalStandardUserCount: Optional. The number of additional standard
  1392  	// users the instance owner has purchased.
  1393  	AdditionalStandardUserCount int64 `json:"additionalStandardUserCount,omitempty"`
  1394  	// AdditionalViewerUserCount: Optional. The number of additional viewer users
  1395  	// the instance owner has purchased.
  1396  	AdditionalViewerUserCount int64 `json:"additionalViewerUserCount,omitempty"`
  1397  	// ForceSendFields is a list of field names (e.g.
  1398  	// "AdditionalDeveloperUserCount") to unconditionally include in API requests.
  1399  	// By default, fields with empty or default values are omitted from API
  1400  	// requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields
  1401  	// for more details.
  1402  	ForceSendFields []string `json:"-"`
  1403  	// NullFields is a list of field names (e.g. "AdditionalDeveloperUserCount") to
  1404  	// include in API requests with the JSON null value. By default, fields with
  1405  	// empty values are omitted from API requests. See
  1406  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1407  	NullFields []string `json:"-"`
  1408  }
  1409  
  1410  func (s *UserMetadata) MarshalJSON() ([]byte, error) {
  1411  	type NoMethod UserMetadata
  1412  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1413  }
  1414  
  1415  type ProjectsLocationsGetCall struct {
  1416  	s            *Service
  1417  	name         string
  1418  	urlParams_   gensupport.URLParams
  1419  	ifNoneMatch_ string
  1420  	ctx_         context.Context
  1421  	header_      http.Header
  1422  }
  1423  
  1424  // Get: Gets information about a location.
  1425  //
  1426  // - name: Resource name for the location.
  1427  func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall {
  1428  	c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1429  	c.name = name
  1430  	return c
  1431  }
  1432  
  1433  // Fields allows partial responses to be retrieved. See
  1434  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1435  // details.
  1436  func (c *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall {
  1437  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1438  	return c
  1439  }
  1440  
  1441  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  1442  // object's ETag matches the given value. This is useful for getting updates
  1443  // only after the object has changed since the last request.
  1444  func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall {
  1445  	c.ifNoneMatch_ = entityTag
  1446  	return c
  1447  }
  1448  
  1449  // Context sets the context to be used in this call's Do method.
  1450  func (c *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall {
  1451  	c.ctx_ = ctx
  1452  	return c
  1453  }
  1454  
  1455  // Header returns a http.Header that can be modified by the caller to add
  1456  // headers to the request.
  1457  func (c *ProjectsLocationsGetCall) Header() http.Header {
  1458  	if c.header_ == nil {
  1459  		c.header_ = make(http.Header)
  1460  	}
  1461  	return c.header_
  1462  }
  1463  
  1464  func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) {
  1465  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  1466  	if c.ifNoneMatch_ != "" {
  1467  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  1468  	}
  1469  	var body io.Reader = nil
  1470  	c.urlParams_.Set("alt", alt)
  1471  	c.urlParams_.Set("prettyPrint", "false")
  1472  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
  1473  	urls += "?" + c.urlParams_.Encode()
  1474  	req, err := http.NewRequest("GET", urls, body)
  1475  	if err != nil {
  1476  		return nil, err
  1477  	}
  1478  	req.Header = reqHeaders
  1479  	googleapi.Expand(req.URL, map[string]string{
  1480  		"name": c.name,
  1481  	})
  1482  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1483  }
  1484  
  1485  // Do executes the "looker.projects.locations.get" call.
  1486  // Any non-2xx status code is an error. Response headers are in either
  1487  // *Location.ServerResponse.Header or (if a response was returned at all) in
  1488  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  1489  // whether the returned error was because http.StatusNotModified was returned.
  1490  func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) {
  1491  	gensupport.SetOptions(c.urlParams_, opts...)
  1492  	res, err := c.doRequest("json")
  1493  	if res != nil && res.StatusCode == http.StatusNotModified {
  1494  		if res.Body != nil {
  1495  			res.Body.Close()
  1496  		}
  1497  		return nil, gensupport.WrapError(&googleapi.Error{
  1498  			Code:   res.StatusCode,
  1499  			Header: res.Header,
  1500  		})
  1501  	}
  1502  	if err != nil {
  1503  		return nil, err
  1504  	}
  1505  	defer googleapi.CloseBody(res)
  1506  	if err := googleapi.CheckResponse(res); err != nil {
  1507  		return nil, gensupport.WrapError(err)
  1508  	}
  1509  	ret := &Location{
  1510  		ServerResponse: googleapi.ServerResponse{
  1511  			Header:         res.Header,
  1512  			HTTPStatusCode: res.StatusCode,
  1513  		},
  1514  	}
  1515  	target := &ret
  1516  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1517  		return nil, err
  1518  	}
  1519  	return ret, nil
  1520  }
  1521  
  1522  type ProjectsLocationsListCall struct {
  1523  	s            *Service
  1524  	name         string
  1525  	urlParams_   gensupport.URLParams
  1526  	ifNoneMatch_ string
  1527  	ctx_         context.Context
  1528  	header_      http.Header
  1529  }
  1530  
  1531  // List: Lists information about the supported locations for this service.
  1532  //
  1533  // - name: The resource that owns the locations collection, if applicable.
  1534  func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall {
  1535  	c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1536  	c.name = name
  1537  	return c
  1538  }
  1539  
  1540  // Filter sets the optional parameter "filter": A filter to narrow down results
  1541  // to a preferred subset. The filtering language accepts strings like
  1542  // "displayName=tokyo", and is documented in more detail in AIP-160
  1543  // (https://google.aip.dev/160).
  1544  func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall {
  1545  	c.urlParams_.Set("filter", filter)
  1546  	return c
  1547  }
  1548  
  1549  // PageSize sets the optional parameter "pageSize": The maximum number of
  1550  // results to return. If not set, the service selects a default.
  1551  func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall {
  1552  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  1553  	return c
  1554  }
  1555  
  1556  // PageToken sets the optional parameter "pageToken": A page token received
  1557  // from the `next_page_token` field in the response. Send that page token to
  1558  // receive the subsequent page.
  1559  func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall {
  1560  	c.urlParams_.Set("pageToken", pageToken)
  1561  	return c
  1562  }
  1563  
  1564  // Fields allows partial responses to be retrieved. See
  1565  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1566  // details.
  1567  func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall {
  1568  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1569  	return c
  1570  }
  1571  
  1572  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  1573  // object's ETag matches the given value. This is useful for getting updates
  1574  // only after the object has changed since the last request.
  1575  func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall {
  1576  	c.ifNoneMatch_ = entityTag
  1577  	return c
  1578  }
  1579  
  1580  // Context sets the context to be used in this call's Do method.
  1581  func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall {
  1582  	c.ctx_ = ctx
  1583  	return c
  1584  }
  1585  
  1586  // Header returns a http.Header that can be modified by the caller to add
  1587  // headers to the request.
  1588  func (c *ProjectsLocationsListCall) Header() http.Header {
  1589  	if c.header_ == nil {
  1590  		c.header_ = make(http.Header)
  1591  	}
  1592  	return c.header_
  1593  }
  1594  
  1595  func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) {
  1596  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  1597  	if c.ifNoneMatch_ != "" {
  1598  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  1599  	}
  1600  	var body io.Reader = nil
  1601  	c.urlParams_.Set("alt", alt)
  1602  	c.urlParams_.Set("prettyPrint", "false")
  1603  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/locations")
  1604  	urls += "?" + c.urlParams_.Encode()
  1605  	req, err := http.NewRequest("GET", urls, body)
  1606  	if err != nil {
  1607  		return nil, err
  1608  	}
  1609  	req.Header = reqHeaders
  1610  	googleapi.Expand(req.URL, map[string]string{
  1611  		"name": c.name,
  1612  	})
  1613  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1614  }
  1615  
  1616  // Do executes the "looker.projects.locations.list" call.
  1617  // Any non-2xx status code is an error. Response headers are in either
  1618  // *ListLocationsResponse.ServerResponse.Header or (if a response was returned
  1619  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  1620  // check whether the returned error was because http.StatusNotModified was
  1621  // returned.
  1622  func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) {
  1623  	gensupport.SetOptions(c.urlParams_, opts...)
  1624  	res, err := c.doRequest("json")
  1625  	if res != nil && res.StatusCode == http.StatusNotModified {
  1626  		if res.Body != nil {
  1627  			res.Body.Close()
  1628  		}
  1629  		return nil, gensupport.WrapError(&googleapi.Error{
  1630  			Code:   res.StatusCode,
  1631  			Header: res.Header,
  1632  		})
  1633  	}
  1634  	if err != nil {
  1635  		return nil, err
  1636  	}
  1637  	defer googleapi.CloseBody(res)
  1638  	if err := googleapi.CheckResponse(res); err != nil {
  1639  		return nil, gensupport.WrapError(err)
  1640  	}
  1641  	ret := &ListLocationsResponse{
  1642  		ServerResponse: googleapi.ServerResponse{
  1643  			Header:         res.Header,
  1644  			HTTPStatusCode: res.StatusCode,
  1645  		},
  1646  	}
  1647  	target := &ret
  1648  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1649  		return nil, err
  1650  	}
  1651  	return ret, nil
  1652  }
  1653  
  1654  // Pages invokes f for each page of results.
  1655  // A non-nil error returned from f will halt the iteration.
  1656  // The provided context supersedes any context provided to the Context method.
  1657  func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) error) error {
  1658  	c.ctx_ = ctx
  1659  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  1660  	for {
  1661  		x, err := c.Do()
  1662  		if err != nil {
  1663  			return err
  1664  		}
  1665  		if err := f(x); err != nil {
  1666  			return err
  1667  		}
  1668  		if x.NextPageToken == "" {
  1669  			return nil
  1670  		}
  1671  		c.PageToken(x.NextPageToken)
  1672  	}
  1673  }
  1674  
  1675  type ProjectsLocationsInstancesCreateCall struct {
  1676  	s          *Service
  1677  	parent     string
  1678  	instance   *Instance
  1679  	urlParams_ gensupport.URLParams
  1680  	ctx_       context.Context
  1681  	header_    http.Header
  1682  }
  1683  
  1684  // Create: Creates a new Instance in a given project and location.
  1685  //
  1686  // - parent: Format: `projects/{project}/locations/{location}`.
  1687  func (r *ProjectsLocationsInstancesService) Create(parent string, instance *Instance) *ProjectsLocationsInstancesCreateCall {
  1688  	c := &ProjectsLocationsInstancesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1689  	c.parent = parent
  1690  	c.instance = instance
  1691  	return c
  1692  }
  1693  
  1694  // InstanceId sets the optional parameter "instanceId": Required. The unique
  1695  // instance identifier. Must contain only lowercase letters, numbers, or
  1696  // hyphens, with the first character a letter and the last a letter or a
  1697  // number. 63 characters maximum.
  1698  func (c *ProjectsLocationsInstancesCreateCall) InstanceId(instanceId string) *ProjectsLocationsInstancesCreateCall {
  1699  	c.urlParams_.Set("instanceId", instanceId)
  1700  	return c
  1701  }
  1702  
  1703  // Fields allows partial responses to be retrieved. See
  1704  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1705  // details.
  1706  func (c *ProjectsLocationsInstancesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesCreateCall {
  1707  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1708  	return c
  1709  }
  1710  
  1711  // Context sets the context to be used in this call's Do method.
  1712  func (c *ProjectsLocationsInstancesCreateCall) Context(ctx context.Context) *ProjectsLocationsInstancesCreateCall {
  1713  	c.ctx_ = ctx
  1714  	return c
  1715  }
  1716  
  1717  // Header returns a http.Header that can be modified by the caller to add
  1718  // headers to the request.
  1719  func (c *ProjectsLocationsInstancesCreateCall) Header() http.Header {
  1720  	if c.header_ == nil {
  1721  		c.header_ = make(http.Header)
  1722  	}
  1723  	return c.header_
  1724  }
  1725  
  1726  func (c *ProjectsLocationsInstancesCreateCall) doRequest(alt string) (*http.Response, error) {
  1727  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  1728  	var body io.Reader = nil
  1729  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.instance)
  1730  	if err != nil {
  1731  		return nil, err
  1732  	}
  1733  	c.urlParams_.Set("alt", alt)
  1734  	c.urlParams_.Set("prettyPrint", "false")
  1735  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/instances")
  1736  	urls += "?" + c.urlParams_.Encode()
  1737  	req, err := http.NewRequest("POST", urls, body)
  1738  	if err != nil {
  1739  		return nil, err
  1740  	}
  1741  	req.Header = reqHeaders
  1742  	googleapi.Expand(req.URL, map[string]string{
  1743  		"parent": c.parent,
  1744  	})
  1745  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1746  }
  1747  
  1748  // Do executes the "looker.projects.locations.instances.create" call.
  1749  // Any non-2xx status code is an error. Response headers are in either
  1750  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  1751  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  1752  // whether the returned error was because http.StatusNotModified was returned.
  1753  func (c *ProjectsLocationsInstancesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  1754  	gensupport.SetOptions(c.urlParams_, opts...)
  1755  	res, err := c.doRequest("json")
  1756  	if res != nil && res.StatusCode == http.StatusNotModified {
  1757  		if res.Body != nil {
  1758  			res.Body.Close()
  1759  		}
  1760  		return nil, gensupport.WrapError(&googleapi.Error{
  1761  			Code:   res.StatusCode,
  1762  			Header: res.Header,
  1763  		})
  1764  	}
  1765  	if err != nil {
  1766  		return nil, err
  1767  	}
  1768  	defer googleapi.CloseBody(res)
  1769  	if err := googleapi.CheckResponse(res); err != nil {
  1770  		return nil, gensupport.WrapError(err)
  1771  	}
  1772  	ret := &Operation{
  1773  		ServerResponse: googleapi.ServerResponse{
  1774  			Header:         res.Header,
  1775  			HTTPStatusCode: res.StatusCode,
  1776  		},
  1777  	}
  1778  	target := &ret
  1779  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1780  		return nil, err
  1781  	}
  1782  	return ret, nil
  1783  }
  1784  
  1785  type ProjectsLocationsInstancesDeleteCall struct {
  1786  	s          *Service
  1787  	name       string
  1788  	urlParams_ gensupport.URLParams
  1789  	ctx_       context.Context
  1790  	header_    http.Header
  1791  }
  1792  
  1793  // Delete: Delete instance.
  1794  //
  1795  //   - name: Format:
  1796  //     `projects/{project}/locations/{location}/instances/{instance}`.
  1797  func (r *ProjectsLocationsInstancesService) Delete(name string) *ProjectsLocationsInstancesDeleteCall {
  1798  	c := &ProjectsLocationsInstancesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1799  	c.name = name
  1800  	return c
  1801  }
  1802  
  1803  // Force sets the optional parameter "force": Whether to force cascading
  1804  // delete.
  1805  func (c *ProjectsLocationsInstancesDeleteCall) Force(force bool) *ProjectsLocationsInstancesDeleteCall {
  1806  	c.urlParams_.Set("force", fmt.Sprint(force))
  1807  	return c
  1808  }
  1809  
  1810  // Fields allows partial responses to be retrieved. See
  1811  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1812  // details.
  1813  func (c *ProjectsLocationsInstancesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDeleteCall {
  1814  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1815  	return c
  1816  }
  1817  
  1818  // Context sets the context to be used in this call's Do method.
  1819  func (c *ProjectsLocationsInstancesDeleteCall) Context(ctx context.Context) *ProjectsLocationsInstancesDeleteCall {
  1820  	c.ctx_ = ctx
  1821  	return c
  1822  }
  1823  
  1824  // Header returns a http.Header that can be modified by the caller to add
  1825  // headers to the request.
  1826  func (c *ProjectsLocationsInstancesDeleteCall) Header() http.Header {
  1827  	if c.header_ == nil {
  1828  		c.header_ = make(http.Header)
  1829  	}
  1830  	return c.header_
  1831  }
  1832  
  1833  func (c *ProjectsLocationsInstancesDeleteCall) doRequest(alt string) (*http.Response, error) {
  1834  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  1835  	var body io.Reader = nil
  1836  	c.urlParams_.Set("alt", alt)
  1837  	c.urlParams_.Set("prettyPrint", "false")
  1838  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
  1839  	urls += "?" + c.urlParams_.Encode()
  1840  	req, err := http.NewRequest("DELETE", urls, body)
  1841  	if err != nil {
  1842  		return nil, err
  1843  	}
  1844  	req.Header = reqHeaders
  1845  	googleapi.Expand(req.URL, map[string]string{
  1846  		"name": c.name,
  1847  	})
  1848  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1849  }
  1850  
  1851  // Do executes the "looker.projects.locations.instances.delete" call.
  1852  // Any non-2xx status code is an error. Response headers are in either
  1853  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  1854  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  1855  // whether the returned error was because http.StatusNotModified was returned.
  1856  func (c *ProjectsLocationsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  1857  	gensupport.SetOptions(c.urlParams_, opts...)
  1858  	res, err := c.doRequest("json")
  1859  	if res != nil && res.StatusCode == http.StatusNotModified {
  1860  		if res.Body != nil {
  1861  			res.Body.Close()
  1862  		}
  1863  		return nil, gensupport.WrapError(&googleapi.Error{
  1864  			Code:   res.StatusCode,
  1865  			Header: res.Header,
  1866  		})
  1867  	}
  1868  	if err != nil {
  1869  		return nil, err
  1870  	}
  1871  	defer googleapi.CloseBody(res)
  1872  	if err := googleapi.CheckResponse(res); err != nil {
  1873  		return nil, gensupport.WrapError(err)
  1874  	}
  1875  	ret := &Operation{
  1876  		ServerResponse: googleapi.ServerResponse{
  1877  			Header:         res.Header,
  1878  			HTTPStatusCode: res.StatusCode,
  1879  		},
  1880  	}
  1881  	target := &ret
  1882  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1883  		return nil, err
  1884  	}
  1885  	return ret, nil
  1886  }
  1887  
  1888  type ProjectsLocationsInstancesExportCall struct {
  1889  	s                     *Service
  1890  	name                  string
  1891  	exportinstancerequest *ExportInstanceRequest
  1892  	urlParams_            gensupport.URLParams
  1893  	ctx_                  context.Context
  1894  	header_               http.Header
  1895  }
  1896  
  1897  // Export: Export instance.
  1898  //
  1899  //   - name: Format:
  1900  //     `projects/{project}/locations/{location}/instances/{instance}`.
  1901  func (r *ProjectsLocationsInstancesService) Export(name string, exportinstancerequest *ExportInstanceRequest) *ProjectsLocationsInstancesExportCall {
  1902  	c := &ProjectsLocationsInstancesExportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1903  	c.name = name
  1904  	c.exportinstancerequest = exportinstancerequest
  1905  	return c
  1906  }
  1907  
  1908  // Fields allows partial responses to be retrieved. See
  1909  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1910  // details.
  1911  func (c *ProjectsLocationsInstancesExportCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesExportCall {
  1912  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1913  	return c
  1914  }
  1915  
  1916  // Context sets the context to be used in this call's Do method.
  1917  func (c *ProjectsLocationsInstancesExportCall) Context(ctx context.Context) *ProjectsLocationsInstancesExportCall {
  1918  	c.ctx_ = ctx
  1919  	return c
  1920  }
  1921  
  1922  // Header returns a http.Header that can be modified by the caller to add
  1923  // headers to the request.
  1924  func (c *ProjectsLocationsInstancesExportCall) Header() http.Header {
  1925  	if c.header_ == nil {
  1926  		c.header_ = make(http.Header)
  1927  	}
  1928  	return c.header_
  1929  }
  1930  
  1931  func (c *ProjectsLocationsInstancesExportCall) doRequest(alt string) (*http.Response, error) {
  1932  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  1933  	var body io.Reader = nil
  1934  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.exportinstancerequest)
  1935  	if err != nil {
  1936  		return nil, err
  1937  	}
  1938  	c.urlParams_.Set("alt", alt)
  1939  	c.urlParams_.Set("prettyPrint", "false")
  1940  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:export")
  1941  	urls += "?" + c.urlParams_.Encode()
  1942  	req, err := http.NewRequest("POST", urls, body)
  1943  	if err != nil {
  1944  		return nil, err
  1945  	}
  1946  	req.Header = reqHeaders
  1947  	googleapi.Expand(req.URL, map[string]string{
  1948  		"name": c.name,
  1949  	})
  1950  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1951  }
  1952  
  1953  // Do executes the "looker.projects.locations.instances.export" call.
  1954  // Any non-2xx status code is an error. Response headers are in either
  1955  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  1956  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  1957  // whether the returned error was because http.StatusNotModified was returned.
  1958  func (c *ProjectsLocationsInstancesExportCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  1959  	gensupport.SetOptions(c.urlParams_, opts...)
  1960  	res, err := c.doRequest("json")
  1961  	if res != nil && res.StatusCode == http.StatusNotModified {
  1962  		if res.Body != nil {
  1963  			res.Body.Close()
  1964  		}
  1965  		return nil, gensupport.WrapError(&googleapi.Error{
  1966  			Code:   res.StatusCode,
  1967  			Header: res.Header,
  1968  		})
  1969  	}
  1970  	if err != nil {
  1971  		return nil, err
  1972  	}
  1973  	defer googleapi.CloseBody(res)
  1974  	if err := googleapi.CheckResponse(res); err != nil {
  1975  		return nil, gensupport.WrapError(err)
  1976  	}
  1977  	ret := &Operation{
  1978  		ServerResponse: googleapi.ServerResponse{
  1979  			Header:         res.Header,
  1980  			HTTPStatusCode: res.StatusCode,
  1981  		},
  1982  	}
  1983  	target := &ret
  1984  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1985  		return nil, err
  1986  	}
  1987  	return ret, nil
  1988  }
  1989  
  1990  type ProjectsLocationsInstancesGetCall struct {
  1991  	s            *Service
  1992  	name         string
  1993  	urlParams_   gensupport.URLParams
  1994  	ifNoneMatch_ string
  1995  	ctx_         context.Context
  1996  	header_      http.Header
  1997  }
  1998  
  1999  // Get: Gets details of a single Instance.
  2000  //
  2001  //   - name: Format:
  2002  //     `projects/{project}/locations/{location}/instances/{instance}`.
  2003  func (r *ProjectsLocationsInstancesService) Get(name string) *ProjectsLocationsInstancesGetCall {
  2004  	c := &ProjectsLocationsInstancesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2005  	c.name = name
  2006  	return c
  2007  }
  2008  
  2009  // Fields allows partial responses to be retrieved. See
  2010  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2011  // details.
  2012  func (c *ProjectsLocationsInstancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetCall {
  2013  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2014  	return c
  2015  }
  2016  
  2017  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2018  // object's ETag matches the given value. This is useful for getting updates
  2019  // only after the object has changed since the last request.
  2020  func (c *ProjectsLocationsInstancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetCall {
  2021  	c.ifNoneMatch_ = entityTag
  2022  	return c
  2023  }
  2024  
  2025  // Context sets the context to be used in this call's Do method.
  2026  func (c *ProjectsLocationsInstancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetCall {
  2027  	c.ctx_ = ctx
  2028  	return c
  2029  }
  2030  
  2031  // Header returns a http.Header that can be modified by the caller to add
  2032  // headers to the request.
  2033  func (c *ProjectsLocationsInstancesGetCall) Header() http.Header {
  2034  	if c.header_ == nil {
  2035  		c.header_ = make(http.Header)
  2036  	}
  2037  	return c.header_
  2038  }
  2039  
  2040  func (c *ProjectsLocationsInstancesGetCall) doRequest(alt string) (*http.Response, error) {
  2041  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2042  	if c.ifNoneMatch_ != "" {
  2043  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2044  	}
  2045  	var body io.Reader = nil
  2046  	c.urlParams_.Set("alt", alt)
  2047  	c.urlParams_.Set("prettyPrint", "false")
  2048  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
  2049  	urls += "?" + c.urlParams_.Encode()
  2050  	req, err := http.NewRequest("GET", urls, body)
  2051  	if err != nil {
  2052  		return nil, err
  2053  	}
  2054  	req.Header = reqHeaders
  2055  	googleapi.Expand(req.URL, map[string]string{
  2056  		"name": c.name,
  2057  	})
  2058  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2059  }
  2060  
  2061  // Do executes the "looker.projects.locations.instances.get" call.
  2062  // Any non-2xx status code is an error. Response headers are in either
  2063  // *Instance.ServerResponse.Header or (if a response was returned at all) in
  2064  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2065  // whether the returned error was because http.StatusNotModified was returned.
  2066  func (c *ProjectsLocationsInstancesGetCall) Do(opts ...googleapi.CallOption) (*Instance, error) {
  2067  	gensupport.SetOptions(c.urlParams_, opts...)
  2068  	res, err := c.doRequest("json")
  2069  	if res != nil && res.StatusCode == http.StatusNotModified {
  2070  		if res.Body != nil {
  2071  			res.Body.Close()
  2072  		}
  2073  		return nil, gensupport.WrapError(&googleapi.Error{
  2074  			Code:   res.StatusCode,
  2075  			Header: res.Header,
  2076  		})
  2077  	}
  2078  	if err != nil {
  2079  		return nil, err
  2080  	}
  2081  	defer googleapi.CloseBody(res)
  2082  	if err := googleapi.CheckResponse(res); err != nil {
  2083  		return nil, gensupport.WrapError(err)
  2084  	}
  2085  	ret := &Instance{
  2086  		ServerResponse: googleapi.ServerResponse{
  2087  			Header:         res.Header,
  2088  			HTTPStatusCode: res.StatusCode,
  2089  		},
  2090  	}
  2091  	target := &ret
  2092  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2093  		return nil, err
  2094  	}
  2095  	return ret, nil
  2096  }
  2097  
  2098  type ProjectsLocationsInstancesGetIamPolicyCall struct {
  2099  	s            *Service
  2100  	resource     string
  2101  	urlParams_   gensupport.URLParams
  2102  	ifNoneMatch_ string
  2103  	ctx_         context.Context
  2104  	header_      http.Header
  2105  }
  2106  
  2107  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  2108  // empty policy if the resource exists and does not have a policy set.
  2109  //
  2110  //   - resource: REQUIRED: The resource for which the policy is being requested.
  2111  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  2112  //     for the appropriate value for this field.
  2113  func (r *ProjectsLocationsInstancesService) GetIamPolicy(resource string) *ProjectsLocationsInstancesGetIamPolicyCall {
  2114  	c := &ProjectsLocationsInstancesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2115  	c.resource = resource
  2116  	return c
  2117  }
  2118  
  2119  // OptionsRequestedPolicyVersion sets the optional parameter
  2120  // "options.requestedPolicyVersion": The maximum policy version that will be
  2121  // used to format the policy. Valid values are 0, 1, and 3. Requests specifying
  2122  // an invalid value will be rejected. Requests for policies with any
  2123  // conditional role bindings must specify version 3. Policies with no
  2124  // conditional role bindings may specify any valid value or leave the field
  2125  // unset. The policy in the response might use the policy version that you
  2126  // specified, or it might use a lower policy version. For example, if you
  2127  // specify version 3, but the policy has no conditional role bindings, the
  2128  // response uses version 1. To learn which resources support conditions in
  2129  // their IAM policies, see the IAM documentation
  2130  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  2131  func (c *ProjectsLocationsInstancesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsInstancesGetIamPolicyCall {
  2132  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  2133  	return c
  2134  }
  2135  
  2136  // Fields allows partial responses to be retrieved. See
  2137  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2138  // details.
  2139  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetIamPolicyCall {
  2140  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2141  	return c
  2142  }
  2143  
  2144  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2145  // object's ETag matches the given value. This is useful for getting updates
  2146  // only after the object has changed since the last request.
  2147  func (c *ProjectsLocationsInstancesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetIamPolicyCall {
  2148  	c.ifNoneMatch_ = entityTag
  2149  	return c
  2150  }
  2151  
  2152  // Context sets the context to be used in this call's Do method.
  2153  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetIamPolicyCall {
  2154  	c.ctx_ = ctx
  2155  	return c
  2156  }
  2157  
  2158  // Header returns a http.Header that can be modified by the caller to add
  2159  // headers to the request.
  2160  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Header() http.Header {
  2161  	if c.header_ == nil {
  2162  		c.header_ = make(http.Header)
  2163  	}
  2164  	return c.header_
  2165  }
  2166  
  2167  func (c *ProjectsLocationsInstancesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  2168  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2169  	if c.ifNoneMatch_ != "" {
  2170  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2171  	}
  2172  	var body io.Reader = nil
  2173  	c.urlParams_.Set("alt", alt)
  2174  	c.urlParams_.Set("prettyPrint", "false")
  2175  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy")
  2176  	urls += "?" + c.urlParams_.Encode()
  2177  	req, err := http.NewRequest("GET", urls, body)
  2178  	if err != nil {
  2179  		return nil, err
  2180  	}
  2181  	req.Header = reqHeaders
  2182  	googleapi.Expand(req.URL, map[string]string{
  2183  		"resource": c.resource,
  2184  	})
  2185  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2186  }
  2187  
  2188  // Do executes the "looker.projects.locations.instances.getIamPolicy" call.
  2189  // Any non-2xx status code is an error. Response headers are in either
  2190  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  2191  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2192  // whether the returned error was because http.StatusNotModified was returned.
  2193  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  2194  	gensupport.SetOptions(c.urlParams_, opts...)
  2195  	res, err := c.doRequest("json")
  2196  	if res != nil && res.StatusCode == http.StatusNotModified {
  2197  		if res.Body != nil {
  2198  			res.Body.Close()
  2199  		}
  2200  		return nil, gensupport.WrapError(&googleapi.Error{
  2201  			Code:   res.StatusCode,
  2202  			Header: res.Header,
  2203  		})
  2204  	}
  2205  	if err != nil {
  2206  		return nil, err
  2207  	}
  2208  	defer googleapi.CloseBody(res)
  2209  	if err := googleapi.CheckResponse(res); err != nil {
  2210  		return nil, gensupport.WrapError(err)
  2211  	}
  2212  	ret := &Policy{
  2213  		ServerResponse: googleapi.ServerResponse{
  2214  			Header:         res.Header,
  2215  			HTTPStatusCode: res.StatusCode,
  2216  		},
  2217  	}
  2218  	target := &ret
  2219  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2220  		return nil, err
  2221  	}
  2222  	return ret, nil
  2223  }
  2224  
  2225  type ProjectsLocationsInstancesImportCall struct {
  2226  	s                     *Service
  2227  	name                  string
  2228  	importinstancerequest *ImportInstanceRequest
  2229  	urlParams_            gensupport.URLParams
  2230  	ctx_                  context.Context
  2231  	header_               http.Header
  2232  }
  2233  
  2234  // Import: Import instance.
  2235  //
  2236  //   - name: Format:
  2237  //     `projects/{project}/locations/{location}/instances/{instance}`.
  2238  func (r *ProjectsLocationsInstancesService) Import(name string, importinstancerequest *ImportInstanceRequest) *ProjectsLocationsInstancesImportCall {
  2239  	c := &ProjectsLocationsInstancesImportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2240  	c.name = name
  2241  	c.importinstancerequest = importinstancerequest
  2242  	return c
  2243  }
  2244  
  2245  // Fields allows partial responses to be retrieved. See
  2246  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2247  // details.
  2248  func (c *ProjectsLocationsInstancesImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesImportCall {
  2249  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2250  	return c
  2251  }
  2252  
  2253  // Context sets the context to be used in this call's Do method.
  2254  func (c *ProjectsLocationsInstancesImportCall) Context(ctx context.Context) *ProjectsLocationsInstancesImportCall {
  2255  	c.ctx_ = ctx
  2256  	return c
  2257  }
  2258  
  2259  // Header returns a http.Header that can be modified by the caller to add
  2260  // headers to the request.
  2261  func (c *ProjectsLocationsInstancesImportCall) Header() http.Header {
  2262  	if c.header_ == nil {
  2263  		c.header_ = make(http.Header)
  2264  	}
  2265  	return c.header_
  2266  }
  2267  
  2268  func (c *ProjectsLocationsInstancesImportCall) doRequest(alt string) (*http.Response, error) {
  2269  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2270  	var body io.Reader = nil
  2271  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.importinstancerequest)
  2272  	if err != nil {
  2273  		return nil, err
  2274  	}
  2275  	c.urlParams_.Set("alt", alt)
  2276  	c.urlParams_.Set("prettyPrint", "false")
  2277  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:import")
  2278  	urls += "?" + c.urlParams_.Encode()
  2279  	req, err := http.NewRequest("POST", urls, body)
  2280  	if err != nil {
  2281  		return nil, err
  2282  	}
  2283  	req.Header = reqHeaders
  2284  	googleapi.Expand(req.URL, map[string]string{
  2285  		"name": c.name,
  2286  	})
  2287  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2288  }
  2289  
  2290  // Do executes the "looker.projects.locations.instances.import" call.
  2291  // Any non-2xx status code is an error. Response headers are in either
  2292  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2293  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2294  // whether the returned error was because http.StatusNotModified was returned.
  2295  func (c *ProjectsLocationsInstancesImportCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2296  	gensupport.SetOptions(c.urlParams_, opts...)
  2297  	res, err := c.doRequest("json")
  2298  	if res != nil && res.StatusCode == http.StatusNotModified {
  2299  		if res.Body != nil {
  2300  			res.Body.Close()
  2301  		}
  2302  		return nil, gensupport.WrapError(&googleapi.Error{
  2303  			Code:   res.StatusCode,
  2304  			Header: res.Header,
  2305  		})
  2306  	}
  2307  	if err != nil {
  2308  		return nil, err
  2309  	}
  2310  	defer googleapi.CloseBody(res)
  2311  	if err := googleapi.CheckResponse(res); err != nil {
  2312  		return nil, gensupport.WrapError(err)
  2313  	}
  2314  	ret := &Operation{
  2315  		ServerResponse: googleapi.ServerResponse{
  2316  			Header:         res.Header,
  2317  			HTTPStatusCode: res.StatusCode,
  2318  		},
  2319  	}
  2320  	target := &ret
  2321  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2322  		return nil, err
  2323  	}
  2324  	return ret, nil
  2325  }
  2326  
  2327  type ProjectsLocationsInstancesListCall struct {
  2328  	s            *Service
  2329  	parent       string
  2330  	urlParams_   gensupport.URLParams
  2331  	ifNoneMatch_ string
  2332  	ctx_         context.Context
  2333  	header_      http.Header
  2334  }
  2335  
  2336  // List: Lists Instances in a given project and location.
  2337  //
  2338  // - parent: Format: `projects/{project}/locations/{location}`.
  2339  func (r *ProjectsLocationsInstancesService) List(parent string) *ProjectsLocationsInstancesListCall {
  2340  	c := &ProjectsLocationsInstancesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2341  	c.parent = parent
  2342  	return c
  2343  }
  2344  
  2345  // PageSize sets the optional parameter "pageSize": The maximum number of
  2346  // instances to return. If unspecified at most 256 will be returned. The
  2347  // maximum possible value is 2048.
  2348  func (c *ProjectsLocationsInstancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesListCall {
  2349  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  2350  	return c
  2351  }
  2352  
  2353  // PageToken sets the optional parameter "pageToken": A page token received
  2354  // from a previous ListInstancesRequest.
  2355  func (c *ProjectsLocationsInstancesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesListCall {
  2356  	c.urlParams_.Set("pageToken", pageToken)
  2357  	return c
  2358  }
  2359  
  2360  // Fields allows partial responses to be retrieved. See
  2361  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2362  // details.
  2363  func (c *ProjectsLocationsInstancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesListCall {
  2364  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2365  	return c
  2366  }
  2367  
  2368  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2369  // object's ETag matches the given value. This is useful for getting updates
  2370  // only after the object has changed since the last request.
  2371  func (c *ProjectsLocationsInstancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesListCall {
  2372  	c.ifNoneMatch_ = entityTag
  2373  	return c
  2374  }
  2375  
  2376  // Context sets the context to be used in this call's Do method.
  2377  func (c *ProjectsLocationsInstancesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesListCall {
  2378  	c.ctx_ = ctx
  2379  	return c
  2380  }
  2381  
  2382  // Header returns a http.Header that can be modified by the caller to add
  2383  // headers to the request.
  2384  func (c *ProjectsLocationsInstancesListCall) Header() http.Header {
  2385  	if c.header_ == nil {
  2386  		c.header_ = make(http.Header)
  2387  	}
  2388  	return c.header_
  2389  }
  2390  
  2391  func (c *ProjectsLocationsInstancesListCall) doRequest(alt string) (*http.Response, error) {
  2392  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2393  	if c.ifNoneMatch_ != "" {
  2394  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2395  	}
  2396  	var body io.Reader = nil
  2397  	c.urlParams_.Set("alt", alt)
  2398  	c.urlParams_.Set("prettyPrint", "false")
  2399  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/instances")
  2400  	urls += "?" + c.urlParams_.Encode()
  2401  	req, err := http.NewRequest("GET", urls, body)
  2402  	if err != nil {
  2403  		return nil, err
  2404  	}
  2405  	req.Header = reqHeaders
  2406  	googleapi.Expand(req.URL, map[string]string{
  2407  		"parent": c.parent,
  2408  	})
  2409  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2410  }
  2411  
  2412  // Do executes the "looker.projects.locations.instances.list" call.
  2413  // Any non-2xx status code is an error. Response headers are in either
  2414  // *ListInstancesResponse.ServerResponse.Header or (if a response was returned
  2415  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  2416  // check whether the returned error was because http.StatusNotModified was
  2417  // returned.
  2418  func (c *ProjectsLocationsInstancesListCall) Do(opts ...googleapi.CallOption) (*ListInstancesResponse, error) {
  2419  	gensupport.SetOptions(c.urlParams_, opts...)
  2420  	res, err := c.doRequest("json")
  2421  	if res != nil && res.StatusCode == http.StatusNotModified {
  2422  		if res.Body != nil {
  2423  			res.Body.Close()
  2424  		}
  2425  		return nil, gensupport.WrapError(&googleapi.Error{
  2426  			Code:   res.StatusCode,
  2427  			Header: res.Header,
  2428  		})
  2429  	}
  2430  	if err != nil {
  2431  		return nil, err
  2432  	}
  2433  	defer googleapi.CloseBody(res)
  2434  	if err := googleapi.CheckResponse(res); err != nil {
  2435  		return nil, gensupport.WrapError(err)
  2436  	}
  2437  	ret := &ListInstancesResponse{
  2438  		ServerResponse: googleapi.ServerResponse{
  2439  			Header:         res.Header,
  2440  			HTTPStatusCode: res.StatusCode,
  2441  		},
  2442  	}
  2443  	target := &ret
  2444  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2445  		return nil, err
  2446  	}
  2447  	return ret, nil
  2448  }
  2449  
  2450  // Pages invokes f for each page of results.
  2451  // A non-nil error returned from f will halt the iteration.
  2452  // The provided context supersedes any context provided to the Context method.
  2453  func (c *ProjectsLocationsInstancesListCall) Pages(ctx context.Context, f func(*ListInstancesResponse) error) error {
  2454  	c.ctx_ = ctx
  2455  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  2456  	for {
  2457  		x, err := c.Do()
  2458  		if err != nil {
  2459  			return err
  2460  		}
  2461  		if err := f(x); err != nil {
  2462  			return err
  2463  		}
  2464  		if x.NextPageToken == "" {
  2465  			return nil
  2466  		}
  2467  		c.PageToken(x.NextPageToken)
  2468  	}
  2469  }
  2470  
  2471  type ProjectsLocationsInstancesPatchCall struct {
  2472  	s          *Service
  2473  	name       string
  2474  	instance   *Instance
  2475  	urlParams_ gensupport.URLParams
  2476  	ctx_       context.Context
  2477  	header_    http.Header
  2478  }
  2479  
  2480  // Patch: Update Instance.
  2481  //
  2482  //   - name: Output only. Format:
  2483  //     `projects/{project}/locations/{location}/instances/{instance}`.
  2484  func (r *ProjectsLocationsInstancesService) Patch(name string, instance *Instance) *ProjectsLocationsInstancesPatchCall {
  2485  	c := &ProjectsLocationsInstancesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2486  	c.name = name
  2487  	c.instance = instance
  2488  	return c
  2489  }
  2490  
  2491  // UpdateMask sets the optional parameter "updateMask": Required. Field mask
  2492  // used to specify the fields to be overwritten in the Instance resource by the
  2493  // update. The fields specified in the mask are relative to the resource, not
  2494  // the full request. A field will be overwritten if it is in the mask.
  2495  func (c *ProjectsLocationsInstancesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsInstancesPatchCall {
  2496  	c.urlParams_.Set("updateMask", updateMask)
  2497  	return c
  2498  }
  2499  
  2500  // Fields allows partial responses to be retrieved. See
  2501  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2502  // details.
  2503  func (c *ProjectsLocationsInstancesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesPatchCall {
  2504  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2505  	return c
  2506  }
  2507  
  2508  // Context sets the context to be used in this call's Do method.
  2509  func (c *ProjectsLocationsInstancesPatchCall) Context(ctx context.Context) *ProjectsLocationsInstancesPatchCall {
  2510  	c.ctx_ = ctx
  2511  	return c
  2512  }
  2513  
  2514  // Header returns a http.Header that can be modified by the caller to add
  2515  // headers to the request.
  2516  func (c *ProjectsLocationsInstancesPatchCall) Header() http.Header {
  2517  	if c.header_ == nil {
  2518  		c.header_ = make(http.Header)
  2519  	}
  2520  	return c.header_
  2521  }
  2522  
  2523  func (c *ProjectsLocationsInstancesPatchCall) doRequest(alt string) (*http.Response, error) {
  2524  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2525  	var body io.Reader = nil
  2526  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.instance)
  2527  	if err != nil {
  2528  		return nil, err
  2529  	}
  2530  	c.urlParams_.Set("alt", alt)
  2531  	c.urlParams_.Set("prettyPrint", "false")
  2532  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
  2533  	urls += "?" + c.urlParams_.Encode()
  2534  	req, err := http.NewRequest("PATCH", urls, body)
  2535  	if err != nil {
  2536  		return nil, err
  2537  	}
  2538  	req.Header = reqHeaders
  2539  	googleapi.Expand(req.URL, map[string]string{
  2540  		"name": c.name,
  2541  	})
  2542  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2543  }
  2544  
  2545  // Do executes the "looker.projects.locations.instances.patch" call.
  2546  // Any non-2xx status code is an error. Response headers are in either
  2547  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2548  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2549  // whether the returned error was because http.StatusNotModified was returned.
  2550  func (c *ProjectsLocationsInstancesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2551  	gensupport.SetOptions(c.urlParams_, opts...)
  2552  	res, err := c.doRequest("json")
  2553  	if res != nil && res.StatusCode == http.StatusNotModified {
  2554  		if res.Body != nil {
  2555  			res.Body.Close()
  2556  		}
  2557  		return nil, gensupport.WrapError(&googleapi.Error{
  2558  			Code:   res.StatusCode,
  2559  			Header: res.Header,
  2560  		})
  2561  	}
  2562  	if err != nil {
  2563  		return nil, err
  2564  	}
  2565  	defer googleapi.CloseBody(res)
  2566  	if err := googleapi.CheckResponse(res); err != nil {
  2567  		return nil, gensupport.WrapError(err)
  2568  	}
  2569  	ret := &Operation{
  2570  		ServerResponse: googleapi.ServerResponse{
  2571  			Header:         res.Header,
  2572  			HTTPStatusCode: res.StatusCode,
  2573  		},
  2574  	}
  2575  	target := &ret
  2576  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2577  		return nil, err
  2578  	}
  2579  	return ret, nil
  2580  }
  2581  
  2582  type ProjectsLocationsInstancesRestartCall struct {
  2583  	s                      *Service
  2584  	name                   string
  2585  	restartinstancerequest *RestartInstanceRequest
  2586  	urlParams_             gensupport.URLParams
  2587  	ctx_                   context.Context
  2588  	header_                http.Header
  2589  }
  2590  
  2591  // Restart: Restart instance.
  2592  //
  2593  //   - name: Format:
  2594  //     `projects/{project}/locations/{location}/instances/{instance}`.
  2595  func (r *ProjectsLocationsInstancesService) Restart(name string, restartinstancerequest *RestartInstanceRequest) *ProjectsLocationsInstancesRestartCall {
  2596  	c := &ProjectsLocationsInstancesRestartCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2597  	c.name = name
  2598  	c.restartinstancerequest = restartinstancerequest
  2599  	return c
  2600  }
  2601  
  2602  // Fields allows partial responses to be retrieved. See
  2603  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2604  // details.
  2605  func (c *ProjectsLocationsInstancesRestartCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesRestartCall {
  2606  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2607  	return c
  2608  }
  2609  
  2610  // Context sets the context to be used in this call's Do method.
  2611  func (c *ProjectsLocationsInstancesRestartCall) Context(ctx context.Context) *ProjectsLocationsInstancesRestartCall {
  2612  	c.ctx_ = ctx
  2613  	return c
  2614  }
  2615  
  2616  // Header returns a http.Header that can be modified by the caller to add
  2617  // headers to the request.
  2618  func (c *ProjectsLocationsInstancesRestartCall) Header() http.Header {
  2619  	if c.header_ == nil {
  2620  		c.header_ = make(http.Header)
  2621  	}
  2622  	return c.header_
  2623  }
  2624  
  2625  func (c *ProjectsLocationsInstancesRestartCall) doRequest(alt string) (*http.Response, error) {
  2626  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2627  	var body io.Reader = nil
  2628  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.restartinstancerequest)
  2629  	if err != nil {
  2630  		return nil, err
  2631  	}
  2632  	c.urlParams_.Set("alt", alt)
  2633  	c.urlParams_.Set("prettyPrint", "false")
  2634  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:restart")
  2635  	urls += "?" + c.urlParams_.Encode()
  2636  	req, err := http.NewRequest("POST", urls, body)
  2637  	if err != nil {
  2638  		return nil, err
  2639  	}
  2640  	req.Header = reqHeaders
  2641  	googleapi.Expand(req.URL, map[string]string{
  2642  		"name": c.name,
  2643  	})
  2644  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2645  }
  2646  
  2647  // Do executes the "looker.projects.locations.instances.restart" call.
  2648  // Any non-2xx status code is an error. Response headers are in either
  2649  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2650  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2651  // whether the returned error was because http.StatusNotModified was returned.
  2652  func (c *ProjectsLocationsInstancesRestartCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2653  	gensupport.SetOptions(c.urlParams_, opts...)
  2654  	res, err := c.doRequest("json")
  2655  	if res != nil && res.StatusCode == http.StatusNotModified {
  2656  		if res.Body != nil {
  2657  			res.Body.Close()
  2658  		}
  2659  		return nil, gensupport.WrapError(&googleapi.Error{
  2660  			Code:   res.StatusCode,
  2661  			Header: res.Header,
  2662  		})
  2663  	}
  2664  	if err != nil {
  2665  		return nil, err
  2666  	}
  2667  	defer googleapi.CloseBody(res)
  2668  	if err := googleapi.CheckResponse(res); err != nil {
  2669  		return nil, gensupport.WrapError(err)
  2670  	}
  2671  	ret := &Operation{
  2672  		ServerResponse: googleapi.ServerResponse{
  2673  			Header:         res.Header,
  2674  			HTTPStatusCode: res.StatusCode,
  2675  		},
  2676  	}
  2677  	target := &ret
  2678  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2679  		return nil, err
  2680  	}
  2681  	return ret, nil
  2682  }
  2683  
  2684  type ProjectsLocationsInstancesSetIamPolicyCall struct {
  2685  	s                   *Service
  2686  	resource            string
  2687  	setiampolicyrequest *SetIamPolicyRequest
  2688  	urlParams_          gensupport.URLParams
  2689  	ctx_                context.Context
  2690  	header_             http.Header
  2691  }
  2692  
  2693  // SetIamPolicy: Sets the access control policy on the specified resource.
  2694  // Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`,
  2695  // and `PERMISSION_DENIED` errors.
  2696  //
  2697  //   - resource: REQUIRED: The resource for which the policy is being specified.
  2698  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  2699  //     for the appropriate value for this field.
  2700  func (r *ProjectsLocationsInstancesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsInstancesSetIamPolicyCall {
  2701  	c := &ProjectsLocationsInstancesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2702  	c.resource = resource
  2703  	c.setiampolicyrequest = setiampolicyrequest
  2704  	return c
  2705  }
  2706  
  2707  // Fields allows partial responses to be retrieved. See
  2708  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2709  // details.
  2710  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesSetIamPolicyCall {
  2711  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2712  	return c
  2713  }
  2714  
  2715  // Context sets the context to be used in this call's Do method.
  2716  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesSetIamPolicyCall {
  2717  	c.ctx_ = ctx
  2718  	return c
  2719  }
  2720  
  2721  // Header returns a http.Header that can be modified by the caller to add
  2722  // headers to the request.
  2723  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Header() http.Header {
  2724  	if c.header_ == nil {
  2725  		c.header_ = make(http.Header)
  2726  	}
  2727  	return c.header_
  2728  }
  2729  
  2730  func (c *ProjectsLocationsInstancesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  2731  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2732  	var body io.Reader = nil
  2733  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  2734  	if err != nil {
  2735  		return nil, err
  2736  	}
  2737  	c.urlParams_.Set("alt", alt)
  2738  	c.urlParams_.Set("prettyPrint", "false")
  2739  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy")
  2740  	urls += "?" + c.urlParams_.Encode()
  2741  	req, err := http.NewRequest("POST", urls, body)
  2742  	if err != nil {
  2743  		return nil, err
  2744  	}
  2745  	req.Header = reqHeaders
  2746  	googleapi.Expand(req.URL, map[string]string{
  2747  		"resource": c.resource,
  2748  	})
  2749  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2750  }
  2751  
  2752  // Do executes the "looker.projects.locations.instances.setIamPolicy" call.
  2753  // Any non-2xx status code is an error. Response headers are in either
  2754  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  2755  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2756  // whether the returned error was because http.StatusNotModified was returned.
  2757  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  2758  	gensupport.SetOptions(c.urlParams_, opts...)
  2759  	res, err := c.doRequest("json")
  2760  	if res != nil && res.StatusCode == http.StatusNotModified {
  2761  		if res.Body != nil {
  2762  			res.Body.Close()
  2763  		}
  2764  		return nil, gensupport.WrapError(&googleapi.Error{
  2765  			Code:   res.StatusCode,
  2766  			Header: res.Header,
  2767  		})
  2768  	}
  2769  	if err != nil {
  2770  		return nil, err
  2771  	}
  2772  	defer googleapi.CloseBody(res)
  2773  	if err := googleapi.CheckResponse(res); err != nil {
  2774  		return nil, gensupport.WrapError(err)
  2775  	}
  2776  	ret := &Policy{
  2777  		ServerResponse: googleapi.ServerResponse{
  2778  			Header:         res.Header,
  2779  			HTTPStatusCode: res.StatusCode,
  2780  		},
  2781  	}
  2782  	target := &ret
  2783  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2784  		return nil, err
  2785  	}
  2786  	return ret, nil
  2787  }
  2788  
  2789  type ProjectsLocationsInstancesTestIamPermissionsCall struct {
  2790  	s                         *Service
  2791  	resource                  string
  2792  	testiampermissionsrequest *TestIamPermissionsRequest
  2793  	urlParams_                gensupport.URLParams
  2794  	ctx_                      context.Context
  2795  	header_                   http.Header
  2796  }
  2797  
  2798  // TestIamPermissions: Returns permissions that a caller has on the specified
  2799  // resource. If the resource does not exist, this will return an empty set of
  2800  // permissions, not a `NOT_FOUND` error. Note: This operation is designed to be
  2801  // used for building permission-aware UIs and command-line tools, not for
  2802  // authorization checking. This operation may "fail open" without warning.
  2803  //
  2804  //   - resource: REQUIRED: The resource for which the policy detail is being
  2805  //     requested. See Resource names
  2806  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  2807  //     value for this field.
  2808  func (r *ProjectsLocationsInstancesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsInstancesTestIamPermissionsCall {
  2809  	c := &ProjectsLocationsInstancesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2810  	c.resource = resource
  2811  	c.testiampermissionsrequest = testiampermissionsrequest
  2812  	return c
  2813  }
  2814  
  2815  // Fields allows partial responses to be retrieved. See
  2816  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2817  // details.
  2818  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesTestIamPermissionsCall {
  2819  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2820  	return c
  2821  }
  2822  
  2823  // Context sets the context to be used in this call's Do method.
  2824  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsInstancesTestIamPermissionsCall {
  2825  	c.ctx_ = ctx
  2826  	return c
  2827  }
  2828  
  2829  // Header returns a http.Header that can be modified by the caller to add
  2830  // headers to the request.
  2831  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Header() http.Header {
  2832  	if c.header_ == nil {
  2833  		c.header_ = make(http.Header)
  2834  	}
  2835  	return c.header_
  2836  }
  2837  
  2838  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  2839  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2840  	var body io.Reader = nil
  2841  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  2842  	if err != nil {
  2843  		return nil, err
  2844  	}
  2845  	c.urlParams_.Set("alt", alt)
  2846  	c.urlParams_.Set("prettyPrint", "false")
  2847  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:testIamPermissions")
  2848  	urls += "?" + c.urlParams_.Encode()
  2849  	req, err := http.NewRequest("POST", urls, body)
  2850  	if err != nil {
  2851  		return nil, err
  2852  	}
  2853  	req.Header = reqHeaders
  2854  	googleapi.Expand(req.URL, map[string]string{
  2855  		"resource": c.resource,
  2856  	})
  2857  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2858  }
  2859  
  2860  // Do executes the "looker.projects.locations.instances.testIamPermissions" call.
  2861  // Any non-2xx status code is an error. Response headers are in either
  2862  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  2863  // returned at all) in error.(*googleapi.Error).Header. Use
  2864  // googleapi.IsNotModified to check whether the returned error was because
  2865  // http.StatusNotModified was returned.
  2866  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  2867  	gensupport.SetOptions(c.urlParams_, opts...)
  2868  	res, err := c.doRequest("json")
  2869  	if res != nil && res.StatusCode == http.StatusNotModified {
  2870  		if res.Body != nil {
  2871  			res.Body.Close()
  2872  		}
  2873  		return nil, gensupport.WrapError(&googleapi.Error{
  2874  			Code:   res.StatusCode,
  2875  			Header: res.Header,
  2876  		})
  2877  	}
  2878  	if err != nil {
  2879  		return nil, err
  2880  	}
  2881  	defer googleapi.CloseBody(res)
  2882  	if err := googleapi.CheckResponse(res); err != nil {
  2883  		return nil, gensupport.WrapError(err)
  2884  	}
  2885  	ret := &TestIamPermissionsResponse{
  2886  		ServerResponse: googleapi.ServerResponse{
  2887  			Header:         res.Header,
  2888  			HTTPStatusCode: res.StatusCode,
  2889  		},
  2890  	}
  2891  	target := &ret
  2892  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2893  		return nil, err
  2894  	}
  2895  	return ret, nil
  2896  }
  2897  
  2898  type ProjectsLocationsInstancesBackupsGetIamPolicyCall struct {
  2899  	s            *Service
  2900  	resource     string
  2901  	urlParams_   gensupport.URLParams
  2902  	ifNoneMatch_ string
  2903  	ctx_         context.Context
  2904  	header_      http.Header
  2905  }
  2906  
  2907  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  2908  // empty policy if the resource exists and does not have a policy set.
  2909  //
  2910  //   - resource: REQUIRED: The resource for which the policy is being requested.
  2911  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  2912  //     for the appropriate value for this field.
  2913  func (r *ProjectsLocationsInstancesBackupsService) GetIamPolicy(resource string) *ProjectsLocationsInstancesBackupsGetIamPolicyCall {
  2914  	c := &ProjectsLocationsInstancesBackupsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2915  	c.resource = resource
  2916  	return c
  2917  }
  2918  
  2919  // OptionsRequestedPolicyVersion sets the optional parameter
  2920  // "options.requestedPolicyVersion": The maximum policy version that will be
  2921  // used to format the policy. Valid values are 0, 1, and 3. Requests specifying
  2922  // an invalid value will be rejected. Requests for policies with any
  2923  // conditional role bindings must specify version 3. Policies with no
  2924  // conditional role bindings may specify any valid value or leave the field
  2925  // unset. The policy in the response might use the policy version that you
  2926  // specified, or it might use a lower policy version. For example, if you
  2927  // specify version 3, but the policy has no conditional role bindings, the
  2928  // response uses version 1. To learn which resources support conditions in
  2929  // their IAM policies, see the IAM documentation
  2930  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  2931  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsInstancesBackupsGetIamPolicyCall {
  2932  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  2933  	return c
  2934  }
  2935  
  2936  // Fields allows partial responses to be retrieved. See
  2937  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2938  // details.
  2939  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesBackupsGetIamPolicyCall {
  2940  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2941  	return c
  2942  }
  2943  
  2944  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2945  // object's ETag matches the given value. This is useful for getting updates
  2946  // only after the object has changed since the last request.
  2947  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesBackupsGetIamPolicyCall {
  2948  	c.ifNoneMatch_ = entityTag
  2949  	return c
  2950  }
  2951  
  2952  // Context sets the context to be used in this call's Do method.
  2953  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesBackupsGetIamPolicyCall {
  2954  	c.ctx_ = ctx
  2955  	return c
  2956  }
  2957  
  2958  // Header returns a http.Header that can be modified by the caller to add
  2959  // headers to the request.
  2960  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) Header() http.Header {
  2961  	if c.header_ == nil {
  2962  		c.header_ = make(http.Header)
  2963  	}
  2964  	return c.header_
  2965  }
  2966  
  2967  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  2968  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2969  	if c.ifNoneMatch_ != "" {
  2970  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2971  	}
  2972  	var body io.Reader = nil
  2973  	c.urlParams_.Set("alt", alt)
  2974  	c.urlParams_.Set("prettyPrint", "false")
  2975  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy")
  2976  	urls += "?" + c.urlParams_.Encode()
  2977  	req, err := http.NewRequest("GET", urls, body)
  2978  	if err != nil {
  2979  		return nil, err
  2980  	}
  2981  	req.Header = reqHeaders
  2982  	googleapi.Expand(req.URL, map[string]string{
  2983  		"resource": c.resource,
  2984  	})
  2985  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2986  }
  2987  
  2988  // Do executes the "looker.projects.locations.instances.backups.getIamPolicy" call.
  2989  // Any non-2xx status code is an error. Response headers are in either
  2990  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  2991  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2992  // whether the returned error was because http.StatusNotModified was returned.
  2993  func (c *ProjectsLocationsInstancesBackupsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  2994  	gensupport.SetOptions(c.urlParams_, opts...)
  2995  	res, err := c.doRequest("json")
  2996  	if res != nil && res.StatusCode == http.StatusNotModified {
  2997  		if res.Body != nil {
  2998  			res.Body.Close()
  2999  		}
  3000  		return nil, gensupport.WrapError(&googleapi.Error{
  3001  			Code:   res.StatusCode,
  3002  			Header: res.Header,
  3003  		})
  3004  	}
  3005  	if err != nil {
  3006  		return nil, err
  3007  	}
  3008  	defer googleapi.CloseBody(res)
  3009  	if err := googleapi.CheckResponse(res); err != nil {
  3010  		return nil, gensupport.WrapError(err)
  3011  	}
  3012  	ret := &Policy{
  3013  		ServerResponse: googleapi.ServerResponse{
  3014  			Header:         res.Header,
  3015  			HTTPStatusCode: res.StatusCode,
  3016  		},
  3017  	}
  3018  	target := &ret
  3019  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3020  		return nil, err
  3021  	}
  3022  	return ret, nil
  3023  }
  3024  
  3025  type ProjectsLocationsInstancesBackupsSetIamPolicyCall struct {
  3026  	s                   *Service
  3027  	resource            string
  3028  	setiampolicyrequest *SetIamPolicyRequest
  3029  	urlParams_          gensupport.URLParams
  3030  	ctx_                context.Context
  3031  	header_             http.Header
  3032  }
  3033  
  3034  // SetIamPolicy: Sets the access control policy on the specified resource.
  3035  // Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`,
  3036  // and `PERMISSION_DENIED` errors.
  3037  //
  3038  //   - resource: REQUIRED: The resource for which the policy is being specified.
  3039  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3040  //     for the appropriate value for this field.
  3041  func (r *ProjectsLocationsInstancesBackupsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsInstancesBackupsSetIamPolicyCall {
  3042  	c := &ProjectsLocationsInstancesBackupsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3043  	c.resource = resource
  3044  	c.setiampolicyrequest = setiampolicyrequest
  3045  	return c
  3046  }
  3047  
  3048  // Fields allows partial responses to be retrieved. See
  3049  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3050  // details.
  3051  func (c *ProjectsLocationsInstancesBackupsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesBackupsSetIamPolicyCall {
  3052  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3053  	return c
  3054  }
  3055  
  3056  // Context sets the context to be used in this call's Do method.
  3057  func (c *ProjectsLocationsInstancesBackupsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesBackupsSetIamPolicyCall {
  3058  	c.ctx_ = ctx
  3059  	return c
  3060  }
  3061  
  3062  // Header returns a http.Header that can be modified by the caller to add
  3063  // headers to the request.
  3064  func (c *ProjectsLocationsInstancesBackupsSetIamPolicyCall) Header() http.Header {
  3065  	if c.header_ == nil {
  3066  		c.header_ = make(http.Header)
  3067  	}
  3068  	return c.header_
  3069  }
  3070  
  3071  func (c *ProjectsLocationsInstancesBackupsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3072  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3073  	var body io.Reader = nil
  3074  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  3075  	if err != nil {
  3076  		return nil, err
  3077  	}
  3078  	c.urlParams_.Set("alt", alt)
  3079  	c.urlParams_.Set("prettyPrint", "false")
  3080  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy")
  3081  	urls += "?" + c.urlParams_.Encode()
  3082  	req, err := http.NewRequest("POST", urls, body)
  3083  	if err != nil {
  3084  		return nil, err
  3085  	}
  3086  	req.Header = reqHeaders
  3087  	googleapi.Expand(req.URL, map[string]string{
  3088  		"resource": c.resource,
  3089  	})
  3090  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3091  }
  3092  
  3093  // Do executes the "looker.projects.locations.instances.backups.setIamPolicy" call.
  3094  // Any non-2xx status code is an error. Response headers are in either
  3095  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3096  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3097  // whether the returned error was because http.StatusNotModified was returned.
  3098  func (c *ProjectsLocationsInstancesBackupsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3099  	gensupport.SetOptions(c.urlParams_, opts...)
  3100  	res, err := c.doRequest("json")
  3101  	if res != nil && res.StatusCode == http.StatusNotModified {
  3102  		if res.Body != nil {
  3103  			res.Body.Close()
  3104  		}
  3105  		return nil, gensupport.WrapError(&googleapi.Error{
  3106  			Code:   res.StatusCode,
  3107  			Header: res.Header,
  3108  		})
  3109  	}
  3110  	if err != nil {
  3111  		return nil, err
  3112  	}
  3113  	defer googleapi.CloseBody(res)
  3114  	if err := googleapi.CheckResponse(res); err != nil {
  3115  		return nil, gensupport.WrapError(err)
  3116  	}
  3117  	ret := &Policy{
  3118  		ServerResponse: googleapi.ServerResponse{
  3119  			Header:         res.Header,
  3120  			HTTPStatusCode: res.StatusCode,
  3121  		},
  3122  	}
  3123  	target := &ret
  3124  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3125  		return nil, err
  3126  	}
  3127  	return ret, nil
  3128  }
  3129  
  3130  type ProjectsLocationsInstancesBackupsTestIamPermissionsCall struct {
  3131  	s                         *Service
  3132  	resource                  string
  3133  	testiampermissionsrequest *TestIamPermissionsRequest
  3134  	urlParams_                gensupport.URLParams
  3135  	ctx_                      context.Context
  3136  	header_                   http.Header
  3137  }
  3138  
  3139  // TestIamPermissions: Returns permissions that a caller has on the specified
  3140  // resource. If the resource does not exist, this will return an empty set of
  3141  // permissions, not a `NOT_FOUND` error. Note: This operation is designed to be
  3142  // used for building permission-aware UIs and command-line tools, not for
  3143  // authorization checking. This operation may "fail open" without warning.
  3144  //
  3145  //   - resource: REQUIRED: The resource for which the policy detail is being
  3146  //     requested. See Resource names
  3147  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  3148  //     value for this field.
  3149  func (r *ProjectsLocationsInstancesBackupsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsInstancesBackupsTestIamPermissionsCall {
  3150  	c := &ProjectsLocationsInstancesBackupsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3151  	c.resource = resource
  3152  	c.testiampermissionsrequest = testiampermissionsrequest
  3153  	return c
  3154  }
  3155  
  3156  // Fields allows partial responses to be retrieved. See
  3157  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3158  // details.
  3159  func (c *ProjectsLocationsInstancesBackupsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesBackupsTestIamPermissionsCall {
  3160  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3161  	return c
  3162  }
  3163  
  3164  // Context sets the context to be used in this call's Do method.
  3165  func (c *ProjectsLocationsInstancesBackupsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsInstancesBackupsTestIamPermissionsCall {
  3166  	c.ctx_ = ctx
  3167  	return c
  3168  }
  3169  
  3170  // Header returns a http.Header that can be modified by the caller to add
  3171  // headers to the request.
  3172  func (c *ProjectsLocationsInstancesBackupsTestIamPermissionsCall) Header() http.Header {
  3173  	if c.header_ == nil {
  3174  		c.header_ = make(http.Header)
  3175  	}
  3176  	return c.header_
  3177  }
  3178  
  3179  func (c *ProjectsLocationsInstancesBackupsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  3180  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3181  	var body io.Reader = nil
  3182  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  3183  	if err != nil {
  3184  		return nil, err
  3185  	}
  3186  	c.urlParams_.Set("alt", alt)
  3187  	c.urlParams_.Set("prettyPrint", "false")
  3188  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:testIamPermissions")
  3189  	urls += "?" + c.urlParams_.Encode()
  3190  	req, err := http.NewRequest("POST", urls, body)
  3191  	if err != nil {
  3192  		return nil, err
  3193  	}
  3194  	req.Header = reqHeaders
  3195  	googleapi.Expand(req.URL, map[string]string{
  3196  		"resource": c.resource,
  3197  	})
  3198  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3199  }
  3200  
  3201  // Do executes the "looker.projects.locations.instances.backups.testIamPermissions" call.
  3202  // Any non-2xx status code is an error. Response headers are in either
  3203  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  3204  // returned at all) in error.(*googleapi.Error).Header. Use
  3205  // googleapi.IsNotModified to check whether the returned error was because
  3206  // http.StatusNotModified was returned.
  3207  func (c *ProjectsLocationsInstancesBackupsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  3208  	gensupport.SetOptions(c.urlParams_, opts...)
  3209  	res, err := c.doRequest("json")
  3210  	if res != nil && res.StatusCode == http.StatusNotModified {
  3211  		if res.Body != nil {
  3212  			res.Body.Close()
  3213  		}
  3214  		return nil, gensupport.WrapError(&googleapi.Error{
  3215  			Code:   res.StatusCode,
  3216  			Header: res.Header,
  3217  		})
  3218  	}
  3219  	if err != nil {
  3220  		return nil, err
  3221  	}
  3222  	defer googleapi.CloseBody(res)
  3223  	if err := googleapi.CheckResponse(res); err != nil {
  3224  		return nil, gensupport.WrapError(err)
  3225  	}
  3226  	ret := &TestIamPermissionsResponse{
  3227  		ServerResponse: googleapi.ServerResponse{
  3228  			Header:         res.Header,
  3229  			HTTPStatusCode: res.StatusCode,
  3230  		},
  3231  	}
  3232  	target := &ret
  3233  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3234  		return nil, err
  3235  	}
  3236  	return ret, nil
  3237  }
  3238  
  3239  type ProjectsLocationsOperationsCancelCall struct {
  3240  	s                      *Service
  3241  	name                   string
  3242  	canceloperationrequest *CancelOperationRequest
  3243  	urlParams_             gensupport.URLParams
  3244  	ctx_                   context.Context
  3245  	header_                http.Header
  3246  }
  3247  
  3248  // Cancel: Starts asynchronous cancellation on a long-running operation. The
  3249  // server makes a best effort to cancel the operation, but success is not
  3250  // guaranteed. If the server doesn't support this method, it returns
  3251  // `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or
  3252  // other methods to check whether the cancellation succeeded or whether the
  3253  // operation completed despite cancellation. On successful cancellation, the
  3254  // operation is not deleted; instead, it becomes an operation with an
  3255  // Operation.error value with a google.rpc.Status.code of 1, corresponding to
  3256  // `Code.CANCELLED`.
  3257  //
  3258  // - name: The name of the operation resource to be cancelled.
  3259  func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall {
  3260  	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3261  	c.name = name
  3262  	c.canceloperationrequest = canceloperationrequest
  3263  	return c
  3264  }
  3265  
  3266  // Fields allows partial responses to be retrieved. See
  3267  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3268  // details.
  3269  func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
  3270  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3271  	return c
  3272  }
  3273  
  3274  // Context sets the context to be used in this call's Do method.
  3275  func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
  3276  	c.ctx_ = ctx
  3277  	return c
  3278  }
  3279  
  3280  // Header returns a http.Header that can be modified by the caller to add
  3281  // headers to the request.
  3282  func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
  3283  	if c.header_ == nil {
  3284  		c.header_ = make(http.Header)
  3285  	}
  3286  	return c.header_
  3287  }
  3288  
  3289  func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
  3290  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3291  	var body io.Reader = nil
  3292  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest)
  3293  	if err != nil {
  3294  		return nil, err
  3295  	}
  3296  	c.urlParams_.Set("alt", alt)
  3297  	c.urlParams_.Set("prettyPrint", "false")
  3298  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel")
  3299  	urls += "?" + c.urlParams_.Encode()
  3300  	req, err := http.NewRequest("POST", urls, body)
  3301  	if err != nil {
  3302  		return nil, err
  3303  	}
  3304  	req.Header = reqHeaders
  3305  	googleapi.Expand(req.URL, map[string]string{
  3306  		"name": c.name,
  3307  	})
  3308  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3309  }
  3310  
  3311  // Do executes the "looker.projects.locations.operations.cancel" call.
  3312  // Any non-2xx status code is an error. Response headers are in either
  3313  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  3314  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3315  // whether the returned error was because http.StatusNotModified was returned.
  3316  func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  3317  	gensupport.SetOptions(c.urlParams_, opts...)
  3318  	res, err := c.doRequest("json")
  3319  	if res != nil && res.StatusCode == http.StatusNotModified {
  3320  		if res.Body != nil {
  3321  			res.Body.Close()
  3322  		}
  3323  		return nil, gensupport.WrapError(&googleapi.Error{
  3324  			Code:   res.StatusCode,
  3325  			Header: res.Header,
  3326  		})
  3327  	}
  3328  	if err != nil {
  3329  		return nil, err
  3330  	}
  3331  	defer googleapi.CloseBody(res)
  3332  	if err := googleapi.CheckResponse(res); err != nil {
  3333  		return nil, gensupport.WrapError(err)
  3334  	}
  3335  	ret := &Empty{
  3336  		ServerResponse: googleapi.ServerResponse{
  3337  			Header:         res.Header,
  3338  			HTTPStatusCode: res.StatusCode,
  3339  		},
  3340  	}
  3341  	target := &ret
  3342  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3343  		return nil, err
  3344  	}
  3345  	return ret, nil
  3346  }
  3347  
  3348  type ProjectsLocationsOperationsDeleteCall struct {
  3349  	s          *Service
  3350  	name       string
  3351  	urlParams_ gensupport.URLParams
  3352  	ctx_       context.Context
  3353  	header_    http.Header
  3354  }
  3355  
  3356  // Delete: Deletes a long-running operation. This method indicates that the
  3357  // client is no longer interested in the operation result. It does not cancel
  3358  // the operation. If the server doesn't support this method, it returns
  3359  // `google.rpc.Code.UNIMPLEMENTED`.
  3360  //
  3361  // - name: The name of the operation resource to be deleted.
  3362  func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall {
  3363  	c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3364  	c.name = name
  3365  	return c
  3366  }
  3367  
  3368  // Fields allows partial responses to be retrieved. See
  3369  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3370  // details.
  3371  func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall {
  3372  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3373  	return c
  3374  }
  3375  
  3376  // Context sets the context to be used in this call's Do method.
  3377  func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall {
  3378  	c.ctx_ = ctx
  3379  	return c
  3380  }
  3381  
  3382  // Header returns a http.Header that can be modified by the caller to add
  3383  // headers to the request.
  3384  func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header {
  3385  	if c.header_ == nil {
  3386  		c.header_ = make(http.Header)
  3387  	}
  3388  	return c.header_
  3389  }
  3390  
  3391  func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) {
  3392  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3393  	var body io.Reader = nil
  3394  	c.urlParams_.Set("alt", alt)
  3395  	c.urlParams_.Set("prettyPrint", "false")
  3396  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
  3397  	urls += "?" + c.urlParams_.Encode()
  3398  	req, err := http.NewRequest("DELETE", urls, body)
  3399  	if err != nil {
  3400  		return nil, err
  3401  	}
  3402  	req.Header = reqHeaders
  3403  	googleapi.Expand(req.URL, map[string]string{
  3404  		"name": c.name,
  3405  	})
  3406  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3407  }
  3408  
  3409  // Do executes the "looker.projects.locations.operations.delete" call.
  3410  // Any non-2xx status code is an error. Response headers are in either
  3411  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  3412  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3413  // whether the returned error was because http.StatusNotModified was returned.
  3414  func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  3415  	gensupport.SetOptions(c.urlParams_, opts...)
  3416  	res, err := c.doRequest("json")
  3417  	if res != nil && res.StatusCode == http.StatusNotModified {
  3418  		if res.Body != nil {
  3419  			res.Body.Close()
  3420  		}
  3421  		return nil, gensupport.WrapError(&googleapi.Error{
  3422  			Code:   res.StatusCode,
  3423  			Header: res.Header,
  3424  		})
  3425  	}
  3426  	if err != nil {
  3427  		return nil, err
  3428  	}
  3429  	defer googleapi.CloseBody(res)
  3430  	if err := googleapi.CheckResponse(res); err != nil {
  3431  		return nil, gensupport.WrapError(err)
  3432  	}
  3433  	ret := &Empty{
  3434  		ServerResponse: googleapi.ServerResponse{
  3435  			Header:         res.Header,
  3436  			HTTPStatusCode: res.StatusCode,
  3437  		},
  3438  	}
  3439  	target := &ret
  3440  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3441  		return nil, err
  3442  	}
  3443  	return ret, nil
  3444  }
  3445  
  3446  type ProjectsLocationsOperationsGetCall struct {
  3447  	s            *Service
  3448  	name         string
  3449  	urlParams_   gensupport.URLParams
  3450  	ifNoneMatch_ string
  3451  	ctx_         context.Context
  3452  	header_      http.Header
  3453  }
  3454  
  3455  // Get: Gets the latest state of a long-running operation. Clients can use this
  3456  // method to poll the operation result at intervals as recommended by the API
  3457  // service.
  3458  //
  3459  // - name: The name of the operation resource.
  3460  func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
  3461  	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3462  	c.name = name
  3463  	return c
  3464  }
  3465  
  3466  // Fields allows partial responses to be retrieved. See
  3467  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3468  // details.
  3469  func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
  3470  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3471  	return c
  3472  }
  3473  
  3474  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3475  // object's ETag matches the given value. This is useful for getting updates
  3476  // only after the object has changed since the last request.
  3477  func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
  3478  	c.ifNoneMatch_ = entityTag
  3479  	return c
  3480  }
  3481  
  3482  // Context sets the context to be used in this call's Do method.
  3483  func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
  3484  	c.ctx_ = ctx
  3485  	return c
  3486  }
  3487  
  3488  // Header returns a http.Header that can be modified by the caller to add
  3489  // headers to the request.
  3490  func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
  3491  	if c.header_ == nil {
  3492  		c.header_ = make(http.Header)
  3493  	}
  3494  	return c.header_
  3495  }
  3496  
  3497  func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
  3498  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3499  	if c.ifNoneMatch_ != "" {
  3500  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3501  	}
  3502  	var body io.Reader = nil
  3503  	c.urlParams_.Set("alt", alt)
  3504  	c.urlParams_.Set("prettyPrint", "false")
  3505  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
  3506  	urls += "?" + c.urlParams_.Encode()
  3507  	req, err := http.NewRequest("GET", urls, body)
  3508  	if err != nil {
  3509  		return nil, err
  3510  	}
  3511  	req.Header = reqHeaders
  3512  	googleapi.Expand(req.URL, map[string]string{
  3513  		"name": c.name,
  3514  	})
  3515  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3516  }
  3517  
  3518  // Do executes the "looker.projects.locations.operations.get" call.
  3519  // Any non-2xx status code is an error. Response headers are in either
  3520  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3521  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3522  // whether the returned error was because http.StatusNotModified was returned.
  3523  func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, 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, gensupport.WrapError(&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, gensupport.WrapError(err)
  3541  	}
  3542  	ret := &Operation{
  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  
  3555  type ProjectsLocationsOperationsListCall struct {
  3556  	s            *Service
  3557  	name         string
  3558  	urlParams_   gensupport.URLParams
  3559  	ifNoneMatch_ string
  3560  	ctx_         context.Context
  3561  	header_      http.Header
  3562  }
  3563  
  3564  // List: Lists operations that match the specified filter in the request. If
  3565  // the server doesn't support this method, it returns `UNIMPLEMENTED`.
  3566  //
  3567  // - name: The name of the operation's parent resource.
  3568  func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
  3569  	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3570  	c.name = name
  3571  	return c
  3572  }
  3573  
  3574  // Filter sets the optional parameter "filter": The standard list filter.
  3575  func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
  3576  	c.urlParams_.Set("filter", filter)
  3577  	return c
  3578  }
  3579  
  3580  // PageSize sets the optional parameter "pageSize": The standard list page
  3581  // size.
  3582  func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
  3583  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3584  	return c
  3585  }
  3586  
  3587  // PageToken sets the optional parameter "pageToken": The standard list page
  3588  // token.
  3589  func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
  3590  	c.urlParams_.Set("pageToken", pageToken)
  3591  	return c
  3592  }
  3593  
  3594  // Fields allows partial responses to be retrieved. See
  3595  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3596  // details.
  3597  func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
  3598  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3599  	return c
  3600  }
  3601  
  3602  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3603  // object's ETag matches the given value. This is useful for getting updates
  3604  // only after the object has changed since the last request.
  3605  func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
  3606  	c.ifNoneMatch_ = entityTag
  3607  	return c
  3608  }
  3609  
  3610  // Context sets the context to be used in this call's Do method.
  3611  func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
  3612  	c.ctx_ = ctx
  3613  	return c
  3614  }
  3615  
  3616  // Header returns a http.Header that can be modified by the caller to add
  3617  // headers to the request.
  3618  func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
  3619  	if c.header_ == nil {
  3620  		c.header_ = make(http.Header)
  3621  	}
  3622  	return c.header_
  3623  }
  3624  
  3625  func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
  3626  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3627  	if c.ifNoneMatch_ != "" {
  3628  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3629  	}
  3630  	var body io.Reader = nil
  3631  	c.urlParams_.Set("alt", alt)
  3632  	c.urlParams_.Set("prettyPrint", "false")
  3633  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations")
  3634  	urls += "?" + c.urlParams_.Encode()
  3635  	req, err := http.NewRequest("GET", urls, body)
  3636  	if err != nil {
  3637  		return nil, err
  3638  	}
  3639  	req.Header = reqHeaders
  3640  	googleapi.Expand(req.URL, map[string]string{
  3641  		"name": c.name,
  3642  	})
  3643  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3644  }
  3645  
  3646  // Do executes the "looker.projects.locations.operations.list" call.
  3647  // Any non-2xx status code is an error. Response headers are in either
  3648  // *ListOperationsResponse.ServerResponse.Header or (if a response was returned
  3649  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3650  // check whether the returned error was because http.StatusNotModified was
  3651  // returned.
  3652  func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
  3653  	gensupport.SetOptions(c.urlParams_, opts...)
  3654  	res, err := c.doRequest("json")
  3655  	if res != nil && res.StatusCode == http.StatusNotModified {
  3656  		if res.Body != nil {
  3657  			res.Body.Close()
  3658  		}
  3659  		return nil, gensupport.WrapError(&googleapi.Error{
  3660  			Code:   res.StatusCode,
  3661  			Header: res.Header,
  3662  		})
  3663  	}
  3664  	if err != nil {
  3665  		return nil, err
  3666  	}
  3667  	defer googleapi.CloseBody(res)
  3668  	if err := googleapi.CheckResponse(res); err != nil {
  3669  		return nil, gensupport.WrapError(err)
  3670  	}
  3671  	ret := &ListOperationsResponse{
  3672  		ServerResponse: googleapi.ServerResponse{
  3673  			Header:         res.Header,
  3674  			HTTPStatusCode: res.StatusCode,
  3675  		},
  3676  	}
  3677  	target := &ret
  3678  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3679  		return nil, err
  3680  	}
  3681  	return ret, nil
  3682  }
  3683  
  3684  // Pages invokes f for each page of results.
  3685  // A non-nil error returned from f will halt the iteration.
  3686  // The provided context supersedes any context provided to the Context method.
  3687  func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
  3688  	c.ctx_ = ctx
  3689  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3690  	for {
  3691  		x, err := c.Do()
  3692  		if err != nil {
  3693  			return err
  3694  		}
  3695  		if err := f(x); err != nil {
  3696  			return err
  3697  		}
  3698  		if x.NextPageToken == "" {
  3699  			return nil
  3700  		}
  3701  		c.PageToken(x.NextPageToken)
  3702  	}
  3703  }
  3704  

View as plain text