...

Source file src/google.golang.org/api/datafusion/v1beta1/datafusion-gen.go

Documentation: google.golang.org/api/datafusion/v1beta1

     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 datafusion provides access to the Cloud Data Fusion API.
     8  //
     9  // For product documentation, see: https://cloud.google.com/data-fusion/docs
    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/datafusion/v1beta1"
    27  //	...
    28  //	ctx := context.Background()
    29  //	datafusionService, err := datafusion.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  //	datafusionService, err := datafusion.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  //	datafusionService, err := datafusion.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
    49  //
    50  // See [google.golang.org/api/option.ClientOption] for details on options.
    51  package datafusion // import "google.golang.org/api/datafusion/v1beta1"
    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 = "datafusion:v1beta1"
    90  const apiName = "datafusion"
    91  const apiVersion = "v1beta1"
    92  const basePath = "https://datafusion.googleapis.com/"
    93  const basePathTemplate = "https://datafusion.UNIVERSE_DOMAIN/"
    94  const mtlsBasePath = "https://datafusion.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  	rs.Versions = NewProjectsLocationsVersionsService(s)
   174  	return rs
   175  }
   176  
   177  type ProjectsLocationsService struct {
   178  	s *Service
   179  
   180  	Instances *ProjectsLocationsInstancesService
   181  
   182  	Operations *ProjectsLocationsOperationsService
   183  
   184  	Versions *ProjectsLocationsVersionsService
   185  }
   186  
   187  func NewProjectsLocationsInstancesService(s *Service) *ProjectsLocationsInstancesService {
   188  	rs := &ProjectsLocationsInstancesService{s: s}
   189  	rs.DnsPeerings = NewProjectsLocationsInstancesDnsPeeringsService(s)
   190  	rs.Namespaces = NewProjectsLocationsInstancesNamespacesService(s)
   191  	return rs
   192  }
   193  
   194  type ProjectsLocationsInstancesService struct {
   195  	s *Service
   196  
   197  	DnsPeerings *ProjectsLocationsInstancesDnsPeeringsService
   198  
   199  	Namespaces *ProjectsLocationsInstancesNamespacesService
   200  }
   201  
   202  func NewProjectsLocationsInstancesDnsPeeringsService(s *Service) *ProjectsLocationsInstancesDnsPeeringsService {
   203  	rs := &ProjectsLocationsInstancesDnsPeeringsService{s: s}
   204  	return rs
   205  }
   206  
   207  type ProjectsLocationsInstancesDnsPeeringsService struct {
   208  	s *Service
   209  }
   210  
   211  func NewProjectsLocationsInstancesNamespacesService(s *Service) *ProjectsLocationsInstancesNamespacesService {
   212  	rs := &ProjectsLocationsInstancesNamespacesService{s: s}
   213  	return rs
   214  }
   215  
   216  type ProjectsLocationsInstancesNamespacesService struct {
   217  	s *Service
   218  }
   219  
   220  func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
   221  	rs := &ProjectsLocationsOperationsService{s: s}
   222  	return rs
   223  }
   224  
   225  type ProjectsLocationsOperationsService struct {
   226  	s *Service
   227  }
   228  
   229  func NewProjectsLocationsVersionsService(s *Service) *ProjectsLocationsVersionsService {
   230  	rs := &ProjectsLocationsVersionsService{s: s}
   231  	return rs
   232  }
   233  
   234  type ProjectsLocationsVersionsService struct {
   235  	s *Service
   236  }
   237  
   238  // Accelerator: Identifies Data Fusion accelerators for an instance.
   239  type Accelerator struct {
   240  	// AcceleratorType: The type of an accelator for a CDF instance.
   241  	//
   242  	// Possible values:
   243  	//   "ACCELERATOR_TYPE_UNSPECIFIED" - Default value, if unspecified.
   244  	//   "CDC" - Change Data Capture accelerator for CDF.
   245  	//   "HEALTHCARE" - Cloud Healthcare accelerator for CDF. This accelerator is
   246  	// to enable Cloud Healthcare specific CDF plugins developed by Healthcare
   247  	// team.
   248  	//   "CCAI_INSIGHTS" - Contact Center AI Insights This accelerator is used to
   249  	// enable import and export pipelines custom built to streamline CCAI Insights
   250  	// processing.
   251  	//   "CLOUDSEARCH" - Cloud search accelerator for CDF. This accelerator is to
   252  	// enable Cloud search specific CDF plugins developed by Cloudsearch team.
   253  	AcceleratorType string `json:"acceleratorType,omitempty"`
   254  	// State: The state of the accelerator.
   255  	//
   256  	// Possible values:
   257  	//   "STATE_UNSPECIFIED" - Default value, do not use.
   258  	//   "ENABLED" - Indicates that the accelerator is enabled and available to
   259  	// use.
   260  	//   "DISABLED" - Indicates that the accelerator is disabled and not available
   261  	// to use.
   262  	//   "UNKNOWN" - Indicates that accelerator state is currently unknown.
   263  	// Requests for enable, disable could be retried while in this state.
   264  	State string `json:"state,omitempty"`
   265  	// ForceSendFields is a list of field names (e.g. "AcceleratorType") to
   266  	// unconditionally include in API requests. By default, fields with empty or
   267  	// default values are omitted from API requests. See
   268  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   269  	// details.
   270  	ForceSendFields []string `json:"-"`
   271  	// NullFields is a list of field names (e.g. "AcceleratorType") to include in
   272  	// API requests with the JSON null value. By default, fields with empty values
   273  	// are omitted from API requests. See
   274  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   275  	NullFields []string `json:"-"`
   276  }
   277  
   278  func (s *Accelerator) MarshalJSON() ([]byte, error) {
   279  	type NoMethod Accelerator
   280  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   281  }
   282  
   283  // AuditConfig: Specifies the audit configuration for a service. The
   284  // configuration determines which permission types are logged, and what
   285  // identities, if any, are exempted from logging. An AuditConfig must have one
   286  // or more AuditLogConfigs. If there are AuditConfigs for both `allServices`
   287  // and a specific service, the union of the two AuditConfigs is used for that
   288  // service: the log_types specified in each AuditConfig are enabled, and the
   289  // exempted_members in each AuditLogConfig are exempted. Example Policy with
   290  // multiple AuditConfigs: { "audit_configs": [ { "service": "allServices",
   291  // "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [
   292  // "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" }, { "log_type":
   293  // "ADMIN_READ" } ] }, { "service": "sampleservice.googleapis.com",
   294  // "audit_log_configs": [ { "log_type": "DATA_READ" }, { "log_type":
   295  // "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For
   296  // sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ
   297  // logging. It also exempts `jose@example.com` from DATA_READ logging, and
   298  // `aliya@example.com` from DATA_WRITE logging.
   299  type AuditConfig struct {
   300  	// AuditLogConfigs: The configuration for logging of each type of permission.
   301  	AuditLogConfigs []*AuditLogConfig `json:"auditLogConfigs,omitempty"`
   302  	// Service: Specifies a service that will be enabled for audit logging. For
   303  	// example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices`
   304  	// is a special value that covers all services.
   305  	Service string `json:"service,omitempty"`
   306  	// ForceSendFields is a list of field names (e.g. "AuditLogConfigs") to
   307  	// unconditionally include in API requests. By default, fields with empty or
   308  	// default values are omitted from API requests. See
   309  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   310  	// details.
   311  	ForceSendFields []string `json:"-"`
   312  	// NullFields is a list of field names (e.g. "AuditLogConfigs") to include in
   313  	// API requests with the JSON null value. By default, fields with empty values
   314  	// are omitted from API requests. See
   315  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   316  	NullFields []string `json:"-"`
   317  }
   318  
   319  func (s *AuditConfig) MarshalJSON() ([]byte, error) {
   320  	type NoMethod AuditConfig
   321  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   322  }
   323  
   324  // AuditLogConfig: Provides the configuration for logging a type of
   325  // permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ",
   326  // "exempted_members": [ "user:jose@example.com" ] }, { "log_type":
   327  // "DATA_WRITE" } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while
   328  // exempting jose@example.com from DATA_READ logging.
   329  type AuditLogConfig struct {
   330  	// ExemptedMembers: Specifies the identities that do not cause logging for this
   331  	// type of permission. Follows the same format of Binding.members.
   332  	ExemptedMembers []string `json:"exemptedMembers,omitempty"`
   333  	// LogType: The log type that this config enables.
   334  	//
   335  	// Possible values:
   336  	//   "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this.
   337  	//   "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy
   338  	//   "DATA_WRITE" - Data writes. Example: CloudSQL Users create
   339  	//   "DATA_READ" - Data reads. Example: CloudSQL Users list
   340  	LogType string `json:"logType,omitempty"`
   341  	// ForceSendFields is a list of field names (e.g. "ExemptedMembers") to
   342  	// unconditionally include in API requests. By default, fields with empty or
   343  	// default values are omitted from API requests. See
   344  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   345  	// details.
   346  	ForceSendFields []string `json:"-"`
   347  	// NullFields is a list of field names (e.g. "ExemptedMembers") to include in
   348  	// API requests with the JSON null value. By default, fields with empty values
   349  	// are omitted from API requests. See
   350  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   351  	NullFields []string `json:"-"`
   352  }
   353  
   354  func (s *AuditLogConfig) MarshalJSON() ([]byte, error) {
   355  	type NoMethod AuditLogConfig
   356  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   357  }
   358  
   359  // Binding: Associates `members`, or principals, with a `role`.
   360  type Binding struct {
   361  	// Condition: The condition that is associated with this binding. If the
   362  	// condition evaluates to `true`, then this binding applies to the current
   363  	// request. If the condition evaluates to `false`, then this binding does not
   364  	// apply to the current request. However, a different role binding might grant
   365  	// the same role to one or more of the principals in this binding. To learn
   366  	// which resources support conditions in their IAM policies, see the IAM
   367  	// documentation
   368  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
   369  	Condition *Expr `json:"condition,omitempty"`
   370  	// Members: Specifies the principals requesting access for a Google Cloud
   371  	// resource. `members` can have the following values: * `allUsers`: A special
   372  	// identifier that represents anyone who is on the internet; with or without a
   373  	// Google account. * `allAuthenticatedUsers`: A special identifier that
   374  	// represents anyone who is authenticated with a Google account or a service
   375  	// account. Does not include identities that come from external identity
   376  	// providers (IdPs) through identity federation. * `user:{emailid}`: An email
   377  	// address that represents a specific Google account. For example,
   378  	// `alice@example.com` . * `serviceAccount:{emailid}`: An email address that
   379  	// represents a Google service account. For example,
   380  	// `my-other-app@appspot.gserviceaccount.com`. *
   381  	// `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`: An
   382  	// identifier for a Kubernetes service account
   383  	// (https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts).
   384  	// For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`. *
   385  	// `group:{emailid}`: An email address that represents a Google group. For
   386  	// example, `admins@example.com`. * `domain:{domain}`: The G Suite domain
   387  	// (primary) that represents all the users of that domain. For example,
   388  	// `google.com` or `example.com`. *
   389  	// `principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/sub
   390  	// ject/{subject_attribute_value}`: A single identity in a workforce identity
   391  	// pool. *
   392  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   393  	// group/{group_id}`: All workforce identities in a group. *
   394  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   395  	// attribute.{attribute_name}/{attribute_value}`: All workforce identities with
   396  	// a specific attribute value. *
   397  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   398  	// *`: All identities in a workforce identity pool. *
   399  	// `principal://iam.googleapis.com/projects/{project_number}/locations/global/wo
   400  	// rkloadIdentityPools/{pool_id}/subject/{subject_attribute_value}`: A single
   401  	// identity in a workload identity pool. *
   402  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   403  	// /workloadIdentityPools/{pool_id}/group/{group_id}`: A workload identity pool
   404  	// group. *
   405  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   406  	// /workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{attribute_value}
   407  	// `: All identities in a workload identity pool with a certain attribute. *
   408  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   409  	// /workloadIdentityPools/{pool_id}/*`: All identities in a workload identity
   410  	// pool. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus
   411  	// unique identifier) representing a user that has been recently deleted. For
   412  	// example, `alice@example.com?uid=123456789012345678901`. If the user is
   413  	// recovered, this value reverts to `user:{emailid}` and the recovered user
   414  	// retains the role in the binding. *
   415  	// `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
   416  	// unique identifier) representing a service account that has been recently
   417  	// deleted. For example,
   418  	// `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the
   419  	// service account is undeleted, this value reverts to
   420  	// `serviceAccount:{emailid}` and the undeleted service account retains the
   421  	// role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email
   422  	// address (plus unique identifier) representing a Google group that has been
   423  	// recently deleted. For example,
   424  	// `admins@example.com?uid=123456789012345678901`. If the group is recovered,
   425  	// this value reverts to `group:{emailid}` and the recovered group retains the
   426  	// role in the binding. *
   427  	// `deleted:principal://iam.googleapis.com/locations/global/workforcePools/{pool
   428  	// _id}/subject/{subject_attribute_value}`: Deleted single identity in a
   429  	// workforce identity pool. For example,
   430  	// `deleted:principal://iam.googleapis.com/locations/global/workforcePools/my-po
   431  	// ol-id/subject/my-subject-attribute-value`.
   432  	Members []string `json:"members,omitempty"`
   433  	// Role: Role that is assigned to the list of `members`, or principals. For
   434  	// example, `roles/viewer`, `roles/editor`, or `roles/owner`.
   435  	Role string `json:"role,omitempty"`
   436  	// ForceSendFields is a list of field names (e.g. "Condition") to
   437  	// unconditionally include in API requests. By default, fields with empty or
   438  	// default values are omitted from API requests. See
   439  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   440  	// details.
   441  	ForceSendFields []string `json:"-"`
   442  	// NullFields is a list of field names (e.g. "Condition") to include in API
   443  	// requests with the JSON null value. By default, fields with empty values are
   444  	// omitted from API requests. See
   445  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   446  	NullFields []string `json:"-"`
   447  }
   448  
   449  func (s *Binding) MarshalJSON() ([]byte, error) {
   450  	type NoMethod Binding
   451  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   452  }
   453  
   454  // CancelOperationRequest: The request message for Operations.CancelOperation.
   455  type CancelOperationRequest struct {
   456  }
   457  
   458  // CryptoKeyConfig: The crypto key configuration. This field is used by the
   459  // Customer-managed encryption keys (CMEK) feature.
   460  type CryptoKeyConfig struct {
   461  	// KeyReference: The name of the key which is used to encrypt/decrypt customer
   462  	// data. For key in Cloud KMS, the key should be in the format of
   463  	// `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
   464  	KeyReference string `json:"keyReference,omitempty"`
   465  	// ForceSendFields is a list of field names (e.g. "KeyReference") to
   466  	// unconditionally include in API requests. By default, fields with empty or
   467  	// default values are omitted from API requests. See
   468  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   469  	// details.
   470  	ForceSendFields []string `json:"-"`
   471  	// NullFields is a list of field names (e.g. "KeyReference") to include in API
   472  	// requests with the JSON null value. By default, fields with empty values are
   473  	// omitted from API requests. See
   474  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   475  	NullFields []string `json:"-"`
   476  }
   477  
   478  func (s *CryptoKeyConfig) MarshalJSON() ([]byte, error) {
   479  	type NoMethod CryptoKeyConfig
   480  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   481  }
   482  
   483  // DataResidencyAugmentedView: Next tag: 7
   484  type DataResidencyAugmentedView struct {
   485  	// CrGopoGuris: Cloud resource to Google owned production object mapping in the
   486  	// form of GURIs. The GURIs should be available in DG KB storage/cns tables.
   487  	// This is the preferred way of providing cloud resource mappings. For further
   488  	// details please read go/cloud-resource-monitoring_sig
   489  	CrGopoGuris []string `json:"crGopoGuris,omitempty"`
   490  	// CrGopoPrefixes: Cloud resource to Google owned production object mapping in
   491  	// the form of prefixes. These should be available in DG KB storage/cns tables.
   492  	// The entity type, which is the part of the string before the first colon in
   493  	// the GURI, must be completely specified in prefix. For details about GURI
   494  	// please read go/guri. For further details about the field please read
   495  	// go/cloud-resource-monitoring_sig.
   496  	CrGopoPrefixes []string `json:"crGopoPrefixes,omitempty"`
   497  	// ServiceData: Service-specific data. Only required for pre-determined
   498  	// services. Generally used to bind a Cloud Resource to some a TI container
   499  	// that uniquely specifies a customer. See milestone 2 of DRZ KR8 SIG for more
   500  	// information.
   501  	ServiceData *ServiceData `json:"serviceData,omitempty"`
   502  	// TpIds: The list of project_id's of the tenant projects in the 'google.com'
   503  	// org which serve the Cloud Resource. See go/drz-mst-sig for more details.
   504  	TpIds []string `json:"tpIds,omitempty"`
   505  	// ForceSendFields is a list of field names (e.g. "CrGopoGuris") to
   506  	// unconditionally include in API requests. By default, fields with empty or
   507  	// default values are omitted from API requests. See
   508  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   509  	// details.
   510  	ForceSendFields []string `json:"-"`
   511  	// NullFields is a list of field names (e.g. "CrGopoGuris") to include in API
   512  	// requests with the JSON null value. By default, fields with empty values are
   513  	// omitted from API requests. See
   514  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   515  	NullFields []string `json:"-"`
   516  }
   517  
   518  func (s *DataResidencyAugmentedView) MarshalJSON() ([]byte, error) {
   519  	type NoMethod DataResidencyAugmentedView
   520  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   521  }
   522  
   523  // DnsPeering: DNS peering configuration. These configurations are used to
   524  // create DNS peering with the customer Cloud DNS.
   525  type DnsPeering struct {
   526  	// Description: Optional. Optional description of the dns zone.
   527  	Description string `json:"description,omitempty"`
   528  	// Domain: Required. The dns name suffix of the zone.
   529  	Domain string `json:"domain,omitempty"`
   530  	// Name: Required. The resource name of the dns peering zone. Format:
   531  	// projects/{project}/locations/{location}/instances/{instance}/dnsPeerings/{dns
   532  	// _peering}
   533  	Name string `json:"name,omitempty"`
   534  	// TargetNetwork: Optional. Optional target network to which dns peering should
   535  	// happen.
   536  	TargetNetwork string `json:"targetNetwork,omitempty"`
   537  	// TargetProject: Optional. Optional target project to which dns peering should
   538  	// happen.
   539  	TargetProject string `json:"targetProject,omitempty"`
   540  
   541  	// ServerResponse contains the HTTP response code and headers from the server.
   542  	googleapi.ServerResponse `json:"-"`
   543  	// ForceSendFields is a list of field names (e.g. "Description") to
   544  	// unconditionally include in API requests. By default, fields with empty or
   545  	// default values are omitted from API requests. See
   546  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   547  	// details.
   548  	ForceSendFields []string `json:"-"`
   549  	// NullFields is a list of field names (e.g. "Description") to include in API
   550  	// requests with the JSON null value. By default, fields with empty values are
   551  	// omitted from API requests. See
   552  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   553  	NullFields []string `json:"-"`
   554  }
   555  
   556  func (s *DnsPeering) MarshalJSON() ([]byte, error) {
   557  	type NoMethod DnsPeering
   558  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   559  }
   560  
   561  // Empty: A generic empty message that you can re-use to avoid defining
   562  // duplicated empty messages in your APIs. A typical example is to use it as
   563  // the request or the response type of an API method. For instance: service Foo
   564  // { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
   565  type Empty struct {
   566  	// ServerResponse contains the HTTP response code and headers from the server.
   567  	googleapi.ServerResponse `json:"-"`
   568  }
   569  
   570  // EventPublishConfig: Confirguration of PubSubEventWriter.
   571  type EventPublishConfig struct {
   572  	// Enabled: Required. Option to enable Event Publishing.
   573  	Enabled bool `json:"enabled,omitempty"`
   574  	// Topic: Required. The resource name of the Pub/Sub topic. Format:
   575  	// projects/{project_id}/topics/{topic_id}
   576  	Topic string `json:"topic,omitempty"`
   577  	// ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally
   578  	// include in API requests. By default, fields with empty or default values are
   579  	// omitted from API requests. See
   580  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   581  	// details.
   582  	ForceSendFields []string `json:"-"`
   583  	// NullFields is a list of field names (e.g. "Enabled") to include in API
   584  	// requests with the JSON null value. By default, fields with empty values are
   585  	// omitted from API requests. See
   586  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   587  	NullFields []string `json:"-"`
   588  }
   589  
   590  func (s *EventPublishConfig) MarshalJSON() ([]byte, error) {
   591  	type NoMethod EventPublishConfig
   592  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   593  }
   594  
   595  // Expr: Represents a textual expression in the Common Expression Language
   596  // (CEL) syntax. CEL is a C-like expression language. The syntax and semantics
   597  // of CEL are documented at https://github.com/google/cel-spec. Example
   598  // (Comparison): title: "Summary size limit" description: "Determines if a
   599  // summary is less than 100 chars" expression: "document.summary.size() < 100"
   600  // Example (Equality): title: "Requestor is owner" description: "Determines if
   601  // requestor is the document owner" expression: "document.owner ==
   602  // request.auth.claims.email" Example (Logic): title: "Public documents"
   603  // description: "Determine whether the document should be publicly visible"
   604  // expression: "document.type != 'private' && document.type != 'internal'"
   605  // Example (Data Manipulation): title: "Notification string" description:
   606  // "Create a notification string with a timestamp." expression: "'New message
   607  // received at ' + string(document.create_time)" The exact variables and
   608  // functions that may be referenced within an expression are determined by the
   609  // service that evaluates it. See the service documentation for additional
   610  // information.
   611  type Expr struct {
   612  	// Description: Optional. Description of the expression. This is a longer text
   613  	// which describes the expression, e.g. when hovered over it in a UI.
   614  	Description string `json:"description,omitempty"`
   615  	// Expression: Textual representation of an expression in Common Expression
   616  	// Language syntax.
   617  	Expression string `json:"expression,omitempty"`
   618  	// Location: Optional. String indicating the location of the expression for
   619  	// error reporting, e.g. a file name and a position in the file.
   620  	Location string `json:"location,omitempty"`
   621  	// Title: Optional. Title for the expression, i.e. a short string describing
   622  	// its purpose. This can be used e.g. in UIs which allow to enter the
   623  	// expression.
   624  	Title string `json:"title,omitempty"`
   625  	// ForceSendFields is a list of field names (e.g. "Description") to
   626  	// unconditionally include in API requests. By default, fields with empty or
   627  	// default values are omitted from API requests. See
   628  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   629  	// details.
   630  	ForceSendFields []string `json:"-"`
   631  	// NullFields is a list of field names (e.g. "Description") to include in API
   632  	// requests with the JSON null value. By default, fields with empty values are
   633  	// omitted from API requests. See
   634  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   635  	NullFields []string `json:"-"`
   636  }
   637  
   638  func (s *Expr) MarshalJSON() ([]byte, error) {
   639  	type NoMethod Expr
   640  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   641  }
   642  
   643  // IAMPolicy: IAMPolicy encapsulates the IAM policy name, definition and status
   644  // of policy fetching.
   645  type IAMPolicy struct {
   646  	// Policy: Policy definition if IAM policy fetching is successful, otherwise
   647  	// empty.
   648  	Policy *Policy `json:"policy,omitempty"`
   649  	// Status: Status of iam policy fetching.
   650  	Status *Status `json:"status,omitempty"`
   651  	// ForceSendFields is a list of field names (e.g. "Policy") to unconditionally
   652  	// include in API requests. By default, fields with empty or default values are
   653  	// omitted from API requests. See
   654  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   655  	// details.
   656  	ForceSendFields []string `json:"-"`
   657  	// NullFields is a list of field names (e.g. "Policy") to include in API
   658  	// requests with the JSON null value. By default, fields with empty values are
   659  	// omitted from API requests. See
   660  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   661  	NullFields []string `json:"-"`
   662  }
   663  
   664  func (s *IAMPolicy) MarshalJSON() ([]byte, error) {
   665  	type NoMethod IAMPolicy
   666  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   667  }
   668  
   669  // Instance: Represents a Data Fusion instance.
   670  type Instance struct {
   671  	// Accelerators: Output only. List of accelerators enabled for this CDF
   672  	// instance.
   673  	Accelerators []*Accelerator `json:"accelerators,omitempty"`
   674  	// ApiEndpoint: Output only. Endpoint on which the REST APIs is accessible.
   675  	ApiEndpoint string `json:"apiEndpoint,omitempty"`
   676  	// AvailableVersion: Output only. Available versions that the instance can be
   677  	// upgraded to using UpdateInstanceRequest.
   678  	AvailableVersion []*Version `json:"availableVersion,omitempty"`
   679  	// CreateTime: Output only. The time the instance was created.
   680  	CreateTime string `json:"createTime,omitempty"`
   681  	// CryptoKeyConfig: The crypto key configuration. This field is used by the
   682  	// Customer-Managed Encryption Keys (CMEK) feature.
   683  	CryptoKeyConfig *CryptoKeyConfig `json:"cryptoKeyConfig,omitempty"`
   684  	// DataplexDataLineageIntegrationEnabled: Optional. Option to enable the
   685  	// Dataplex Lineage Integration feature.
   686  	DataplexDataLineageIntegrationEnabled bool `json:"dataplexDataLineageIntegrationEnabled,omitempty"`
   687  	// DataprocServiceAccount: User-managed service account to set on Dataproc when
   688  	// Cloud Data Fusion creates Dataproc to run data processing pipelines. This
   689  	// allows users to have fine-grained access control on Dataproc's accesses to
   690  	// cloud resources.
   691  	DataprocServiceAccount string `json:"dataprocServiceAccount,omitempty"`
   692  	// Description: A description of this instance.
   693  	Description string `json:"description,omitempty"`
   694  	// DisabledReason: Output only. If the instance state is DISABLED, the reason
   695  	// for disabling the instance.
   696  	//
   697  	// Possible values:
   698  	//   "DISABLED_REASON_UNSPECIFIED" - This is an unknown reason for disabling.
   699  	//   "KMS_KEY_ISSUE" - The KMS key used by the instance is either revoked or
   700  	// denied access to
   701  	DisabledReason []string `json:"disabledReason,omitempty"`
   702  	// DisplayName: Display name for an instance.
   703  	DisplayName string `json:"displayName,omitempty"`
   704  	// EnableRbac: Option to enable granular role-based access control.
   705  	EnableRbac bool `json:"enableRbac,omitempty"`
   706  	// EnableStackdriverLogging: Option to enable Stackdriver Logging.
   707  	EnableStackdriverLogging bool `json:"enableStackdriverLogging,omitempty"`
   708  	// EnableStackdriverMonitoring: Option to enable Stackdriver Monitoring.
   709  	EnableStackdriverMonitoring bool `json:"enableStackdriverMonitoring,omitempty"`
   710  	// EnableZoneSeparation: Option to enable zone separation.
   711  	EnableZoneSeparation bool `json:"enableZoneSeparation,omitempty"`
   712  	// EventPublishConfig: Option to enable and pass metadata for event publishing.
   713  	EventPublishConfig *EventPublishConfig `json:"eventPublishConfig,omitempty"`
   714  	// GcsBucket: Output only. Cloud Storage bucket generated by Data Fusion in the
   715  	// customer project.
   716  	GcsBucket string `json:"gcsBucket,omitempty"`
   717  	// Labels: The resource labels for instance to use to annotate any related
   718  	// underlying resources such as Compute Engine VMs. The character '=' is not
   719  	// allowed to be used within the labels.
   720  	Labels map[string]string `json:"labels,omitempty"`
   721  	// Name: Output only. The name of this instance is in the form of
   722  	// projects/{project}/locations/{location}/instances/{instance}.
   723  	Name string `json:"name,omitempty"`
   724  	// NetworkConfig: Network configuration options. These are required when a
   725  	// private Data Fusion instance is to be created.
   726  	NetworkConfig *NetworkConfig `json:"networkConfig,omitempty"`
   727  	// Options: Map of additional options used to configure the behavior of Data
   728  	// Fusion instance.
   729  	Options map[string]string `json:"options,omitempty"`
   730  	// P4ServiceAccount: Output only. P4 service account for the customer project.
   731  	P4ServiceAccount string `json:"p4ServiceAccount,omitempty"`
   732  	// PatchRevision: Optional. Current patch revision of the Data Fusion.
   733  	PatchRevision string `json:"patchRevision,omitempty"`
   734  	// PrivateInstance: Specifies whether the Data Fusion instance should be
   735  	// private. If set to true, all Data Fusion nodes will have private IP
   736  	// addresses and will not be able to access the public internet.
   737  	PrivateInstance bool `json:"privateInstance,omitempty"`
   738  	// SatisfiesPzs: Output only. Reserved for future use.
   739  	SatisfiesPzs bool `json:"satisfiesPzs,omitempty"`
   740  	// ServiceAccount: Output only. Deprecated. Use tenant_project_id instead to
   741  	// extract the tenant project ID.
   742  	ServiceAccount string `json:"serviceAccount,omitempty"`
   743  	// ServiceEndpoint: Output only. Endpoint on which the Data Fusion UI is
   744  	// accessible.
   745  	ServiceEndpoint string `json:"serviceEndpoint,omitempty"`
   746  	// State: Output only. The current state of this Data Fusion instance.
   747  	//
   748  	// Possible values:
   749  	//   "STATE_UNSPECIFIED" - Instance does not have a state yet
   750  	//   "CREATING" - Instance is being created
   751  	//   "RUNNING" - Instance is running and ready for requests
   752  	//   "FAILED" - Instance creation failed
   753  	//   "DELETING" - Instance is being deleted
   754  	//   "UPGRADING" - Instance is being upgraded
   755  	//   "RESTARTING" - Instance is being restarted
   756  	//   "UPDATING" - Instance is being updated on customer request
   757  	//   "AUTO_UPDATING" - Instance is being auto-updated
   758  	//   "AUTO_UPGRADING" - Instance is being auto-upgraded
   759  	//   "DISABLED" - Instance is disabled
   760  	State string `json:"state,omitempty"`
   761  	// StateMessage: Output only. Additional information about the current state of
   762  	// this Data Fusion instance if available.
   763  	StateMessage string `json:"stateMessage,omitempty"`
   764  	// TenantProjectId: Output only. The name of the tenant project.
   765  	TenantProjectId string `json:"tenantProjectId,omitempty"`
   766  	// Type: Required. Instance type.
   767  	//
   768  	// Possible values:
   769  	//   "TYPE_UNSPECIFIED" - No type specified. The instance creation will fail.
   770  	//   "BASIC" - Basic Data Fusion instance. In Basic type, the user will be able
   771  	// to create data pipelines using point and click UI. However, there are
   772  	// certain limitations, such as fewer number of concurrent pipelines, no
   773  	// support for streaming pipelines, etc.
   774  	//   "ENTERPRISE" - Enterprise Data Fusion instance. In Enterprise type, the
   775  	// user will have all features available, such as support for streaming
   776  	// pipelines, unlimited number of concurrent pipelines, etc.
   777  	//   "DEVELOPER" - Developer Data Fusion instance. In Developer type, the user
   778  	// will have all features available but with restrictive capabilities. This is
   779  	// to help enterprises design and develop their data ingestion and integration
   780  	// pipelines at low cost.
   781  	Type string `json:"type,omitempty"`
   782  	// UpdateTime: Output only. The time the instance was last updated.
   783  	UpdateTime string `json:"updateTime,omitempty"`
   784  	// Version: Current version of Data Fusion.
   785  	Version string `json:"version,omitempty"`
   786  	// WorkforceIdentityServiceEndpoint: Output only. Endpoint on which the Data
   787  	// Fusion UI is accessible to third-party users.
   788  	WorkforceIdentityServiceEndpoint string `json:"workforceIdentityServiceEndpoint,omitempty"`
   789  	// Zone: Name of the zone in which the Data Fusion instance will be created.
   790  	// Only DEVELOPER instances use this field.
   791  	Zone string `json:"zone,omitempty"`
   792  
   793  	// ServerResponse contains the HTTP response code and headers from the server.
   794  	googleapi.ServerResponse `json:"-"`
   795  	// ForceSendFields is a list of field names (e.g. "Accelerators") to
   796  	// unconditionally include in API requests. By default, fields with empty or
   797  	// default values are omitted from API requests. See
   798  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   799  	// details.
   800  	ForceSendFields []string `json:"-"`
   801  	// NullFields is a list of field names (e.g. "Accelerators") to include in API
   802  	// requests with the JSON null value. By default, fields with empty values are
   803  	// omitted from API requests. See
   804  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   805  	NullFields []string `json:"-"`
   806  }
   807  
   808  func (s *Instance) MarshalJSON() ([]byte, error) {
   809  	type NoMethod Instance
   810  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   811  }
   812  
   813  // ListAvailableVersionsResponse: Response message for the list available
   814  // versions request.
   815  type ListAvailableVersionsResponse struct {
   816  	// AvailableVersions: Represents a list of versions that are supported.
   817  	AvailableVersions []*Version `json:"availableVersions,omitempty"`
   818  	// NextPageToken: Token to retrieve the next page of results or empty if there
   819  	// are no more results in the list.
   820  	NextPageToken string `json:"nextPageToken,omitempty"`
   821  
   822  	// ServerResponse contains the HTTP response code and headers from the server.
   823  	googleapi.ServerResponse `json:"-"`
   824  	// ForceSendFields is a list of field names (e.g. "AvailableVersions") to
   825  	// unconditionally include in API requests. By default, fields with empty or
   826  	// default values are omitted from API requests. See
   827  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   828  	// details.
   829  	ForceSendFields []string `json:"-"`
   830  	// NullFields is a list of field names (e.g. "AvailableVersions") to include in
   831  	// API requests with the JSON null value. By default, fields with empty values
   832  	// are omitted from API requests. See
   833  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   834  	NullFields []string `json:"-"`
   835  }
   836  
   837  func (s *ListAvailableVersionsResponse) MarshalJSON() ([]byte, error) {
   838  	type NoMethod ListAvailableVersionsResponse
   839  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   840  }
   841  
   842  // ListDnsPeeringsResponse: Response message for list DNS peerings.
   843  type ListDnsPeeringsResponse struct {
   844  	// DnsPeerings: List of dns peering.
   845  	DnsPeerings []*DnsPeering `json:"dnsPeerings,omitempty"`
   846  	// NextPageToken: A token, which can be sent as `page_token` to retrieve the
   847  	// next page. If this field is omitted, there are no subsequent pages.
   848  	NextPageToken string `json:"nextPageToken,omitempty"`
   849  
   850  	// ServerResponse contains the HTTP response code and headers from the server.
   851  	googleapi.ServerResponse `json:"-"`
   852  	// ForceSendFields is a list of field names (e.g. "DnsPeerings") to
   853  	// unconditionally include in API requests. By default, fields with empty or
   854  	// default values are omitted from API requests. See
   855  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   856  	// details.
   857  	ForceSendFields []string `json:"-"`
   858  	// NullFields is a list of field names (e.g. "DnsPeerings") to include in API
   859  	// requests with the JSON null value. By default, fields with empty values are
   860  	// omitted from API requests. See
   861  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   862  	NullFields []string `json:"-"`
   863  }
   864  
   865  func (s *ListDnsPeeringsResponse) MarshalJSON() ([]byte, error) {
   866  	type NoMethod ListDnsPeeringsResponse
   867  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   868  }
   869  
   870  // ListInstancesResponse: Response message for the list instance request.
   871  type ListInstancesResponse struct {
   872  	// Instances: Represents a list of Data Fusion instances.
   873  	Instances []*Instance `json:"instances,omitempty"`
   874  	// NextPageToken: Token to retrieve the next page of results or empty if there
   875  	// are no more results in the list.
   876  	NextPageToken string `json:"nextPageToken,omitempty"`
   877  	// Unreachable: Locations that could not be reached.
   878  	Unreachable []string `json:"unreachable,omitempty"`
   879  
   880  	// ServerResponse contains the HTTP response code and headers from the server.
   881  	googleapi.ServerResponse `json:"-"`
   882  	// ForceSendFields is a list of field names (e.g. "Instances") to
   883  	// unconditionally include in API requests. By default, fields with empty or
   884  	// default values are omitted from API requests. See
   885  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   886  	// details.
   887  	ForceSendFields []string `json:"-"`
   888  	// NullFields is a list of field names (e.g. "Instances") to include in API
   889  	// requests with the JSON null value. By default, fields with empty values are
   890  	// omitted from API requests. See
   891  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   892  	NullFields []string `json:"-"`
   893  }
   894  
   895  func (s *ListInstancesResponse) MarshalJSON() ([]byte, error) {
   896  	type NoMethod ListInstancesResponse
   897  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   898  }
   899  
   900  // ListLocationsResponse: The response message for Locations.ListLocations.
   901  type ListLocationsResponse struct {
   902  	// Locations: A list of locations that matches the specified filter in the
   903  	// request.
   904  	Locations []*Location `json:"locations,omitempty"`
   905  	// NextPageToken: The standard List next-page token.
   906  	NextPageToken string `json:"nextPageToken,omitempty"`
   907  
   908  	// ServerResponse contains the HTTP response code and headers from the server.
   909  	googleapi.ServerResponse `json:"-"`
   910  	// ForceSendFields is a list of field names (e.g. "Locations") to
   911  	// unconditionally include in API requests. By default, fields with empty or
   912  	// default values are omitted from API requests. See
   913  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   914  	// details.
   915  	ForceSendFields []string `json:"-"`
   916  	// NullFields is a list of field names (e.g. "Locations") to include in API
   917  	// requests with the JSON null value. By default, fields with empty values are
   918  	// omitted from API requests. See
   919  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   920  	NullFields []string `json:"-"`
   921  }
   922  
   923  func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) {
   924  	type NoMethod ListLocationsResponse
   925  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   926  }
   927  
   928  // ListNamespacesResponse: List namespaces response.
   929  type ListNamespacesResponse struct {
   930  	// Namespaces: List of namespaces
   931  	Namespaces []*Namespace `json:"namespaces,omitempty"`
   932  	// NextPageToken: Token to retrieve the next page of results or empty if there
   933  	// are no more results in the list.
   934  	NextPageToken string `json:"nextPageToken,omitempty"`
   935  
   936  	// ServerResponse contains the HTTP response code and headers from the server.
   937  	googleapi.ServerResponse `json:"-"`
   938  	// ForceSendFields is a list of field names (e.g. "Namespaces") to
   939  	// unconditionally include in API requests. By default, fields with empty or
   940  	// default values are omitted from API requests. See
   941  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   942  	// details.
   943  	ForceSendFields []string `json:"-"`
   944  	// NullFields is a list of field names (e.g. "Namespaces") to include in API
   945  	// requests with the JSON null value. By default, fields with empty values are
   946  	// omitted from API requests. See
   947  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   948  	NullFields []string `json:"-"`
   949  }
   950  
   951  func (s *ListNamespacesResponse) MarshalJSON() ([]byte, error) {
   952  	type NoMethod ListNamespacesResponse
   953  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   954  }
   955  
   956  // ListOperationsResponse: The response message for Operations.ListOperations.
   957  type ListOperationsResponse struct {
   958  	// NextPageToken: The standard List next-page token.
   959  	NextPageToken string `json:"nextPageToken,omitempty"`
   960  	// Operations: A list of operations that matches the specified filter in the
   961  	// request.
   962  	Operations []*Operation `json:"operations,omitempty"`
   963  
   964  	// ServerResponse contains the HTTP response code and headers from the server.
   965  	googleapi.ServerResponse `json:"-"`
   966  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
   967  	// unconditionally include in API requests. By default, fields with empty or
   968  	// default values are omitted from API requests. See
   969  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   970  	// details.
   971  	ForceSendFields []string `json:"-"`
   972  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
   973  	// requests with the JSON null value. By default, fields with empty values are
   974  	// omitted from API requests. See
   975  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   976  	NullFields []string `json:"-"`
   977  }
   978  
   979  func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
   980  	type NoMethod ListOperationsResponse
   981  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   982  }
   983  
   984  // Location: A resource that represents a Google Cloud location.
   985  type Location struct {
   986  	// DisplayName: The friendly name for this location, typically a nearby city
   987  	// name. For example, "Tokyo".
   988  	DisplayName string `json:"displayName,omitempty"`
   989  	// Labels: Cross-service attributes for the location. For example
   990  	// {"cloud.googleapis.com/region": "us-east1"}
   991  	Labels map[string]string `json:"labels,omitempty"`
   992  	// LocationId: The canonical id for this location. For example: "us-east1".
   993  	LocationId string `json:"locationId,omitempty"`
   994  	// Metadata: Service-specific metadata. For example the available capacity at
   995  	// the given location.
   996  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
   997  	// Name: Resource name for the location, which may vary between
   998  	// implementations. For example:
   999  	// "projects/example-project/locations/us-east1"
  1000  	Name string `json:"name,omitempty"`
  1001  
  1002  	// ServerResponse contains the HTTP response code and headers from the server.
  1003  	googleapi.ServerResponse `json:"-"`
  1004  	// ForceSendFields is a list of field names (e.g. "DisplayName") to
  1005  	// unconditionally include in API requests. By default, fields with empty or
  1006  	// default values are omitted from API requests. See
  1007  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1008  	// details.
  1009  	ForceSendFields []string `json:"-"`
  1010  	// NullFields is a list of field names (e.g. "DisplayName") to include in API
  1011  	// requests with the JSON null value. By default, fields with empty values are
  1012  	// omitted from API requests. See
  1013  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1014  	NullFields []string `json:"-"`
  1015  }
  1016  
  1017  func (s *Location) MarshalJSON() ([]byte, error) {
  1018  	type NoMethod Location
  1019  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1020  }
  1021  
  1022  // Namespace: Represents the information of a namespace
  1023  type Namespace struct {
  1024  	// IamPolicy: IAM policy associated with this namespace.
  1025  	IamPolicy *IAMPolicy `json:"iamPolicy,omitempty"`
  1026  	// Name: Name of the given namespace.
  1027  	Name string `json:"name,omitempty"`
  1028  	// ForceSendFields is a list of field names (e.g. "IamPolicy") to
  1029  	// unconditionally include in API requests. By default, fields with empty or
  1030  	// default values are omitted from API requests. See
  1031  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1032  	// details.
  1033  	ForceSendFields []string `json:"-"`
  1034  	// NullFields is a list of field names (e.g. "IamPolicy") to include in API
  1035  	// requests with the JSON null value. By default, fields with empty values are
  1036  	// omitted from API requests. See
  1037  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1038  	NullFields []string `json:"-"`
  1039  }
  1040  
  1041  func (s *Namespace) MarshalJSON() ([]byte, error) {
  1042  	type NoMethod Namespace
  1043  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1044  }
  1045  
  1046  // NetworkConfig: Network configuration for a Data Fusion instance. These
  1047  // configurations are used for peering with the customer network.
  1048  // Configurations are optional when a public Data Fusion instance is to be
  1049  // created. However, providing these configurations allows several benefits,
  1050  // such as reduced network latency while accessing the customer resources from
  1051  // managed Data Fusion instance nodes, as well as access to the customer
  1052  // on-prem resources.
  1053  type NetworkConfig struct {
  1054  	// ConnectionType: Optional. Type of connection for establishing private IP
  1055  	// connectivity between the Data Fusion customer project VPC and the
  1056  	// corresponding tenant project from a predefined list of available connection
  1057  	// modes. If this field is unspecified for a private instance, VPC peering is
  1058  	// used.
  1059  	//
  1060  	// Possible values:
  1061  	//   "CONNECTION_TYPE_UNSPECIFIED" - No specific connection type was requested,
  1062  	// the default value of VPC_PEERING is chosen.
  1063  	//   "VPC_PEERING" - Requests the use of VPC peerings for connecting the
  1064  	// consumer and tenant projects.
  1065  	//   "PRIVATE_SERVICE_CONNECT_INTERFACES" - Requests the use of Private Service
  1066  	// Connect Interfaces for connecting the consumer and tenant projects.
  1067  	ConnectionType string `json:"connectionType,omitempty"`
  1068  	// IpAllocation: Optional. The IP range in CIDR notation to use for the managed
  1069  	// Data Fusion instance nodes. This range must not overlap with any other
  1070  	// ranges used in the Data Fusion instance network. This is required only when
  1071  	// using connection type VPC_PEERING. Format: a.b.c.d/22 Example:
  1072  	// 192.168.0.0/22
  1073  	IpAllocation string `json:"ipAllocation,omitempty"`
  1074  	// Network: Optional. Name of the network in the customer project with which
  1075  	// the Tenant Project will be peered for executing pipelines. This is required
  1076  	// only when using connection type VPC peering. In case of shared VPC where the
  1077  	// network resides in another host project the network should specified in the
  1078  	// form of projects/{host-project-id}/global/networks/{network}. This is only
  1079  	// required for connectivity type VPC_PEERING.
  1080  	Network string `json:"network,omitempty"`
  1081  	// PrivateServiceConnectConfig: Optional. Configuration for Private Service
  1082  	// Connect. This is required only when using connection type
  1083  	// PRIVATE_SERVICE_CONNECT_INTERFACES.
  1084  	PrivateServiceConnectConfig *PrivateServiceConnectConfig `json:"privateServiceConnectConfig,omitempty"`
  1085  	// ForceSendFields is a list of field names (e.g. "ConnectionType") to
  1086  	// unconditionally include in API requests. By default, fields with empty or
  1087  	// default values are omitted from API requests. See
  1088  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1089  	// details.
  1090  	ForceSendFields []string `json:"-"`
  1091  	// NullFields is a list of field names (e.g. "ConnectionType") to include in
  1092  	// API requests with the JSON null value. By default, fields with empty values
  1093  	// are omitted from API requests. See
  1094  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1095  	NullFields []string `json:"-"`
  1096  }
  1097  
  1098  func (s *NetworkConfig) MarshalJSON() ([]byte, error) {
  1099  	type NoMethod NetworkConfig
  1100  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1101  }
  1102  
  1103  // Operation: This resource represents a long-running operation that is the
  1104  // result of a network API call.
  1105  type Operation struct {
  1106  	// Done: If the value is `false`, it means the operation is still in progress.
  1107  	// If `true`, the operation is completed, and either `error` or `response` is
  1108  	// available.
  1109  	Done bool `json:"done,omitempty"`
  1110  	// Error: The error result of the operation in case of failure or cancellation.
  1111  	Error *Status `json:"error,omitempty"`
  1112  	// Metadata: Service-specific metadata associated with the operation. It
  1113  	// typically contains progress information and common metadata such as create
  1114  	// time. Some services might not provide such metadata. Any method that returns
  1115  	// a long-running operation should document the metadata type, if any.
  1116  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  1117  	// Name: The server-assigned name, which is only unique within the same service
  1118  	// that originally returns it. If you use the default HTTP mapping, the `name`
  1119  	// should be a resource name ending with `operations/{unique_id}`.
  1120  	Name string `json:"name,omitempty"`
  1121  	// Response: The normal, successful response of the operation. If the original
  1122  	// method returns no data on success, such as `Delete`, the response is
  1123  	// `google.protobuf.Empty`. If the original method is standard
  1124  	// `Get`/`Create`/`Update`, the response should be the resource. For other
  1125  	// methods, the response should have the type `XxxResponse`, where `Xxx` is the
  1126  	// original method name. For example, if the original method name is
  1127  	// `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
  1128  	Response googleapi.RawMessage `json:"response,omitempty"`
  1129  
  1130  	// ServerResponse contains the HTTP response code and headers from the server.
  1131  	googleapi.ServerResponse `json:"-"`
  1132  	// ForceSendFields is a list of field names (e.g. "Done") to unconditionally
  1133  	// include in API requests. By default, fields with empty or default values are
  1134  	// omitted from API requests. See
  1135  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1136  	// details.
  1137  	ForceSendFields []string `json:"-"`
  1138  	// NullFields is a list of field names (e.g. "Done") to include in API requests
  1139  	// with the JSON null value. By default, fields with empty values are omitted
  1140  	// from API requests. See
  1141  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1142  	NullFields []string `json:"-"`
  1143  }
  1144  
  1145  func (s *Operation) MarshalJSON() ([]byte, error) {
  1146  	type NoMethod Operation
  1147  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1148  }
  1149  
  1150  // OperationMetadata: Represents the metadata of a long-running operation.
  1151  type OperationMetadata struct {
  1152  	// AdditionalStatus: Map to hold any additional status info for the operation
  1153  	// If there is an accelerator being enabled/disabled/deleted, this will be
  1154  	// populated with accelerator name as key and status as ENABLING, DISABLING or
  1155  	// DELETING
  1156  	AdditionalStatus map[string]string `json:"additionalStatus,omitempty"`
  1157  	// ApiVersion: API version used to start the operation.
  1158  	ApiVersion string `json:"apiVersion,omitempty"`
  1159  	// CreateTime: The time the operation was created.
  1160  	CreateTime string `json:"createTime,omitempty"`
  1161  	// EndTime: The time the operation finished running.
  1162  	EndTime string `json:"endTime,omitempty"`
  1163  	// RequestedCancellation: Identifies whether the user has requested
  1164  	// cancellation of the operation. Operations that have successfully been
  1165  	// cancelled have Operation.error value with a google.rpc.Status.code of 1,
  1166  	// corresponding to `Code.CANCELLED`.
  1167  	RequestedCancellation bool `json:"requestedCancellation,omitempty"`
  1168  	// StatusDetail: Human-readable status of the operation if any.
  1169  	StatusDetail string `json:"statusDetail,omitempty"`
  1170  	// Target: Server-defined resource path for the target of the operation.
  1171  	Target string `json:"target,omitempty"`
  1172  	// Verb: Name of the verb executed by the operation.
  1173  	Verb string `json:"verb,omitempty"`
  1174  	// ForceSendFields is a list of field names (e.g. "AdditionalStatus") to
  1175  	// unconditionally include in API requests. By default, fields with empty or
  1176  	// default values are omitted from API requests. See
  1177  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1178  	// details.
  1179  	ForceSendFields []string `json:"-"`
  1180  	// NullFields is a list of field names (e.g. "AdditionalStatus") to include in
  1181  	// API requests with the JSON null value. By default, fields with empty values
  1182  	// are omitted from API requests. See
  1183  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1184  	NullFields []string `json:"-"`
  1185  }
  1186  
  1187  func (s *OperationMetadata) MarshalJSON() ([]byte, error) {
  1188  	type NoMethod OperationMetadata
  1189  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1190  }
  1191  
  1192  // PersistentDiskData: Persistent Disk service-specific Data. Contains
  1193  // information that may not be appropriate for the generic DRZ Augmented View.
  1194  // This currently includes LSV Colossus Roots and GCS Buckets.
  1195  type PersistentDiskData struct {
  1196  	// CfsRoots: Path to Colossus root for an LSV. NOTE: Unlike `cr_ti_guris` and
  1197  	// `cr_ti_prefixes`, the field `cfs_roots` below does not need to be a GUri or
  1198  	// GUri prefix. It can simply be any valid CFS or CFS2 Path. The DRZ KR8 SIG
  1199  	// has more details overall, but generally the `cfs_roots` provided here should
  1200  	// be scoped to an individual Persistent Disk. An example for a PD Disk with a
  1201  	// disk ID 3277719120423414466, follows: * `cr_ti_guris` could be
  1202  	// ‘/cfs2/pj/pd-cloud-prod’ as this is a valid GUri present in the DG KB
  1203  	// and contains enough information to perform location monitoring and scope
  1204  	// ownership of the Production Object. * `cfs_roots` would be:
  1205  	// ‘/cfs2/pj/pd-cloud-staging/lsv000001234@/
  1206  	// lsv/projects~773365403387~zones~2700~disks~3277719120423414466
  1207  	// ~bank-blue-careful-3526-lsv00054DB1B7254BA3/’ as this allows us to
  1208  	// enumerate the files on CFS2 that belong to an individual Disk.
  1209  	CfsRoots []string `json:"cfsRoots,omitempty"`
  1210  	// GcsBucketNames: The GCS Buckets that back this snapshot or image. This is
  1211  	// required as `cr_ti_prefixes` and `cr_ti_guris` only accept TI resources.
  1212  	// This should be the globally unique bucket name.
  1213  	GcsBucketNames []string `json:"gcsBucketNames,omitempty"`
  1214  	// ForceSendFields is a list of field names (e.g. "CfsRoots") to
  1215  	// unconditionally include in API requests. By default, fields with empty or
  1216  	// default values are omitted from API requests. See
  1217  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1218  	// details.
  1219  	ForceSendFields []string `json:"-"`
  1220  	// NullFields is a list of field names (e.g. "CfsRoots") to include in API
  1221  	// requests with the JSON null value. By default, fields with empty values are
  1222  	// omitted from API requests. See
  1223  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1224  	NullFields []string `json:"-"`
  1225  }
  1226  
  1227  func (s *PersistentDiskData) MarshalJSON() ([]byte, error) {
  1228  	type NoMethod PersistentDiskData
  1229  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1230  }
  1231  
  1232  // Policy: An Identity and Access Management (IAM) policy, which specifies
  1233  // access controls for Google Cloud resources. A `Policy` is a collection of
  1234  // `bindings`. A `binding` binds one or more `members`, or principals, to a
  1235  // single `role`. Principals can be user accounts, service accounts, Google
  1236  // groups, and domains (such as G Suite). A `role` is a named list of
  1237  // permissions; each `role` can be an IAM predefined role or a user-created
  1238  // custom role. For some types of Google Cloud resources, a `binding` can also
  1239  // specify a `condition`, which is a logical expression that allows access to a
  1240  // resource only if the expression evaluates to `true`. A condition can add
  1241  // constraints based on attributes of the request, the resource, or both. To
  1242  // learn which resources support conditions in their IAM policies, see the IAM
  1243  // documentation
  1244  // (https://cloud.google.com/iam/help/conditions/resource-policies). **JSON
  1245  // example:** ``` { "bindings": [ { "role":
  1246  // "roles/resourcemanager.organizationAdmin", "members": [
  1247  // "user:mike@example.com", "group:admins@example.com", "domain:google.com",
  1248  // "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role":
  1249  // "roles/resourcemanager.organizationViewer", "members": [
  1250  // "user:eve@example.com" ], "condition": { "title": "expirable access",
  1251  // "description": "Does not grant access after Sep 2020", "expression":
  1252  // "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag":
  1253  // "BwWWja0YfJA=", "version": 3 } ``` **YAML example:** ``` bindings: -
  1254  // members: - user:mike@example.com - group:admins@example.com -
  1255  // domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com
  1256  // role: roles/resourcemanager.organizationAdmin - members: -
  1257  // user:eve@example.com role: roles/resourcemanager.organizationViewer
  1258  // condition: title: expirable access description: Does not grant access after
  1259  // Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
  1260  // etag: BwWWja0YfJA= version: 3 ``` For a description of IAM and its features,
  1261  // see the IAM documentation (https://cloud.google.com/iam/docs/).
  1262  type Policy struct {
  1263  	// AuditConfigs: Specifies cloud audit logging configuration for this policy.
  1264  	AuditConfigs []*AuditConfig `json:"auditConfigs,omitempty"`
  1265  	// Bindings: Associates a list of `members`, or principals, with a `role`.
  1266  	// Optionally, may specify a `condition` that determines how and when the
  1267  	// `bindings` are applied. Each of the `bindings` must contain at least one
  1268  	// principal. The `bindings` in a `Policy` can refer to up to 1,500 principals;
  1269  	// up to 250 of these principals can be Google groups. Each occurrence of a
  1270  	// principal counts towards these limits. For example, if the `bindings` grant
  1271  	// 50 different roles to `user:alice@example.com`, and not to any other
  1272  	// principal, then you can add another 1,450 principals to the `bindings` in
  1273  	// the `Policy`.
  1274  	Bindings []*Binding `json:"bindings,omitempty"`
  1275  	// Etag: `etag` is used for optimistic concurrency control as a way to help
  1276  	// prevent simultaneous updates of a policy from overwriting each other. It is
  1277  	// strongly suggested that systems make use of the `etag` in the
  1278  	// read-modify-write cycle to perform policy updates in order to avoid race
  1279  	// conditions: An `etag` is returned in the response to `getIamPolicy`, and
  1280  	// systems are expected to put that etag in the request to `setIamPolicy` to
  1281  	// ensure that their change will be applied to the same version of the policy.
  1282  	// **Important:** If you use IAM Conditions, you must include the `etag` field
  1283  	// whenever you call `setIamPolicy`. If you omit this field, then IAM allows
  1284  	// you to overwrite a version `3` policy with a version `1` policy, and all of
  1285  	// the conditions in the version `3` policy are lost.
  1286  	Etag string `json:"etag,omitempty"`
  1287  	// Version: Specifies the format of the policy. Valid values are `0`, `1`, and
  1288  	// `3`. Requests that specify an invalid value are rejected. Any operation that
  1289  	// affects conditional role bindings must specify version `3`. This requirement
  1290  	// applies to the following operations: * Getting a policy that includes a
  1291  	// conditional role binding * Adding a conditional role binding to a policy *
  1292  	// Changing a conditional role binding in a policy * Removing any role binding,
  1293  	// with or without a condition, from a policy that includes conditions
  1294  	// **Important:** If you use IAM Conditions, you must include the `etag` field
  1295  	// whenever you call `setIamPolicy`. If you omit this field, then IAM allows
  1296  	// you to overwrite a version `3` policy with a version `1` policy, and all of
  1297  	// the conditions in the version `3` policy are lost. If a policy does not
  1298  	// include any conditions, operations on that policy may specify any valid
  1299  	// version or leave the field unset. To learn which resources support
  1300  	// conditions in their IAM policies, see the IAM documentation
  1301  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
  1302  	Version int64 `json:"version,omitempty"`
  1303  
  1304  	// ServerResponse contains the HTTP response code and headers from the server.
  1305  	googleapi.ServerResponse `json:"-"`
  1306  	// ForceSendFields is a list of field names (e.g. "AuditConfigs") to
  1307  	// unconditionally include in API requests. By default, fields with empty or
  1308  	// default values are omitted from API requests. See
  1309  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1310  	// details.
  1311  	ForceSendFields []string `json:"-"`
  1312  	// NullFields is a list of field names (e.g. "AuditConfigs") to include in API
  1313  	// requests with the JSON null value. By default, fields with empty values are
  1314  	// omitted from API requests. See
  1315  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1316  	NullFields []string `json:"-"`
  1317  }
  1318  
  1319  func (s *Policy) MarshalJSON() ([]byte, error) {
  1320  	type NoMethod Policy
  1321  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1322  }
  1323  
  1324  // PrivateServiceConnectConfig: Configuration for using Private Service Connect
  1325  // to establish connectivity between the Data Fusion consumer project and the
  1326  // corresponding tenant project.
  1327  type PrivateServiceConnectConfig struct {
  1328  	// EffectiveUnreachableCidrBlock: Output only. The CIDR block to which the CDF
  1329  	// instance can't route traffic to in the consumer project VPC. The size of
  1330  	// this block is /25. The format of this field is governed by RFC 4632.
  1331  	// Example: 240.0.0.0/25
  1332  	EffectiveUnreachableCidrBlock string `json:"effectiveUnreachableCidrBlock,omitempty"`
  1333  	// NetworkAttachment: Required. The reference to the network attachment used to
  1334  	// establish private connectivity. It will be of the form
  1335  	// projects/{project-id}/regions/{region}/networkAttachments/{network-attachment
  1336  	// -id}.
  1337  	NetworkAttachment string `json:"networkAttachment,omitempty"`
  1338  	// UnreachableCidrBlock: Optional. Input only. The CIDR block to which the CDF
  1339  	// instance can't route traffic to in the consumer project VPC. The size of
  1340  	// this block should be at least /25. This range should not overlap with the
  1341  	// primary address range of any subnetwork used by the network attachment. This
  1342  	// range can be used for other purposes in the consumer VPC as long as there is
  1343  	// no requirement for CDF to reach destinations using these addresses. If this
  1344  	// value is not provided, the server chooses a non RFC 1918 address range. The
  1345  	// format of this field is governed by RFC 4632. Example: 192.168.0.0/25
  1346  	UnreachableCidrBlock string `json:"unreachableCidrBlock,omitempty"`
  1347  	// ForceSendFields is a list of field names (e.g.
  1348  	// "EffectiveUnreachableCidrBlock") to unconditionally include in API requests.
  1349  	// By default, fields with empty or default values are omitted from API
  1350  	// requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields
  1351  	// for more details.
  1352  	ForceSendFields []string `json:"-"`
  1353  	// NullFields is a list of field names (e.g. "EffectiveUnreachableCidrBlock")
  1354  	// to include in API requests with the JSON null value. By default, fields with
  1355  	// empty values are omitted from API requests. See
  1356  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1357  	NullFields []string `json:"-"`
  1358  }
  1359  
  1360  func (s *PrivateServiceConnectConfig) MarshalJSON() ([]byte, error) {
  1361  	type NoMethod PrivateServiceConnectConfig
  1362  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1363  }
  1364  
  1365  // RemoveIamPolicyRequest: Request message for RemoveIamPolicy method.
  1366  type RemoveIamPolicyRequest struct {
  1367  }
  1368  
  1369  // RemoveIamPolicyResponse: Response message for RemoveIamPolicy method.
  1370  type RemoveIamPolicyResponse struct {
  1371  	// ServerResponse contains the HTTP response code and headers from the server.
  1372  	googleapi.ServerResponse `json:"-"`
  1373  }
  1374  
  1375  // RestartInstanceRequest: Request message for restarting a Data Fusion
  1376  // instance.
  1377  type RestartInstanceRequest struct {
  1378  }
  1379  
  1380  // ServiceData: This message defines service-specific data that certain service
  1381  // teams must provide as part of the Data Residency Augmented View for a
  1382  // resource. Next ID: 2
  1383  type ServiceData struct {
  1384  	// Pd: Auxiliary data for the persistent disk pipeline provided to provide the
  1385  	// LSV Colossus Roots and GCS Buckets.
  1386  	Pd *PersistentDiskData `json:"pd,omitempty"`
  1387  	// ForceSendFields is a list of field names (e.g. "Pd") to unconditionally
  1388  	// include in API requests. By default, fields with empty or default values are
  1389  	// omitted from API requests. See
  1390  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1391  	// details.
  1392  	ForceSendFields []string `json:"-"`
  1393  	// NullFields is a list of field names (e.g. "Pd") to include in API requests
  1394  	// with the JSON null value. By default, fields with empty values are omitted
  1395  	// from API requests. See
  1396  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1397  	NullFields []string `json:"-"`
  1398  }
  1399  
  1400  func (s *ServiceData) MarshalJSON() ([]byte, error) {
  1401  	type NoMethod ServiceData
  1402  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1403  }
  1404  
  1405  // SetIamPolicyRequest: Request message for `SetIamPolicy` method.
  1406  type SetIamPolicyRequest struct {
  1407  	// Policy: REQUIRED: The complete policy to be applied to the `resource`. The
  1408  	// size of the policy is limited to a few 10s of KB. An empty policy is a valid
  1409  	// policy but certain Google Cloud services (such as Projects) might reject
  1410  	// them.
  1411  	Policy *Policy `json:"policy,omitempty"`
  1412  	// UpdateMask: OPTIONAL: A FieldMask specifying which fields of the policy to
  1413  	// modify. Only the fields in the mask will be modified. If no mask is
  1414  	// provided, the following default mask is used: `paths: "bindings, etag"
  1415  	UpdateMask string `json:"updateMask,omitempty"`
  1416  	// ForceSendFields is a list of field names (e.g. "Policy") to unconditionally
  1417  	// include in API requests. By default, fields with empty or default values are
  1418  	// omitted from API requests. See
  1419  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1420  	// details.
  1421  	ForceSendFields []string `json:"-"`
  1422  	// NullFields is a list of field names (e.g. "Policy") to include in API
  1423  	// requests with the JSON null value. By default, fields with empty values are
  1424  	// omitted from API requests. See
  1425  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1426  	NullFields []string `json:"-"`
  1427  }
  1428  
  1429  func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
  1430  	type NoMethod SetIamPolicyRequest
  1431  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1432  }
  1433  
  1434  // Status: The `Status` type defines a logical error model that is suitable for
  1435  // different programming environments, including REST APIs and RPC APIs. It is
  1436  // used by gRPC (https://github.com/grpc). Each `Status` message contains three
  1437  // pieces of data: error code, error message, and error details. You can find
  1438  // out more about this error model and how to work with it in the API Design
  1439  // Guide (https://cloud.google.com/apis/design/errors).
  1440  type Status struct {
  1441  	// Code: The status code, which should be an enum value of google.rpc.Code.
  1442  	Code int64 `json:"code,omitempty"`
  1443  	// Details: A list of messages that carry the error details. There is a common
  1444  	// set of message types for APIs to use.
  1445  	Details []googleapi.RawMessage `json:"details,omitempty"`
  1446  	// Message: A developer-facing error message, which should be in English. Any
  1447  	// user-facing error message should be localized and sent in the
  1448  	// google.rpc.Status.details field, or localized by the client.
  1449  	Message string `json:"message,omitempty"`
  1450  	// ForceSendFields is a list of field names (e.g. "Code") to unconditionally
  1451  	// include in API requests. By default, fields with empty or default values are
  1452  	// omitted from API requests. See
  1453  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1454  	// details.
  1455  	ForceSendFields []string `json:"-"`
  1456  	// NullFields is a list of field names (e.g. "Code") to include in API requests
  1457  	// with the JSON null value. By default, fields with empty values are omitted
  1458  	// from API requests. See
  1459  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1460  	NullFields []string `json:"-"`
  1461  }
  1462  
  1463  func (s *Status) MarshalJSON() ([]byte, error) {
  1464  	type NoMethod Status
  1465  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1466  }
  1467  
  1468  // TestIamPermissionsRequest: Request message for `TestIamPermissions` method.
  1469  type TestIamPermissionsRequest struct {
  1470  	// Permissions: The set of permissions to check for the `resource`. Permissions
  1471  	// with wildcards (such as `*` or `storage.*`) are not allowed. For more
  1472  	// information see IAM Overview
  1473  	// (https://cloud.google.com/iam/docs/overview#permissions).
  1474  	Permissions []string `json:"permissions,omitempty"`
  1475  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  1476  	// unconditionally include in API requests. By default, fields with empty or
  1477  	// default values are omitted from API requests. See
  1478  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1479  	// details.
  1480  	ForceSendFields []string `json:"-"`
  1481  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  1482  	// requests with the JSON null value. By default, fields with empty values are
  1483  	// omitted from API requests. See
  1484  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1485  	NullFields []string `json:"-"`
  1486  }
  1487  
  1488  func (s *TestIamPermissionsRequest) MarshalJSON() ([]byte, error) {
  1489  	type NoMethod TestIamPermissionsRequest
  1490  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1491  }
  1492  
  1493  // TestIamPermissionsResponse: Response message for `TestIamPermissions`
  1494  // method.
  1495  type TestIamPermissionsResponse struct {
  1496  	// Permissions: A subset of `TestPermissionsRequest.permissions` that the
  1497  	// caller is allowed.
  1498  	Permissions []string `json:"permissions,omitempty"`
  1499  
  1500  	// ServerResponse contains the HTTP response code and headers from the server.
  1501  	googleapi.ServerResponse `json:"-"`
  1502  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  1503  	// unconditionally include in API requests. By default, fields with empty or
  1504  	// default values are omitted from API requests. See
  1505  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1506  	// details.
  1507  	ForceSendFields []string `json:"-"`
  1508  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  1509  	// requests with the JSON null value. By default, fields with empty values are
  1510  	// omitted from API requests. See
  1511  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1512  	NullFields []string `json:"-"`
  1513  }
  1514  
  1515  func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) {
  1516  	type NoMethod TestIamPermissionsResponse
  1517  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1518  }
  1519  
  1520  // UpgradeInstanceRequest: Request message for upgrading a Data Fusion
  1521  // instance. To change the instance properties, instance update should be used.
  1522  type UpgradeInstanceRequest struct {
  1523  }
  1524  
  1525  // Version: The Data Fusion version.
  1526  type Version struct {
  1527  	// AvailableFeatures: Represents a list of available feature names for a given
  1528  	// version.
  1529  	AvailableFeatures []string `json:"availableFeatures,omitempty"`
  1530  	// DefaultVersion: Whether this is currently the default version for Cloud Data
  1531  	// Fusion
  1532  	DefaultVersion bool `json:"defaultVersion,omitempty"`
  1533  	// Type: Type represents the release availability of the version
  1534  	//
  1535  	// Possible values:
  1536  	//   "TYPE_UNSPECIFIED" - Version does not have availability yet
  1537  	//   "TYPE_PREVIEW" - Version is under development and not considered stable
  1538  	//   "TYPE_GENERAL_AVAILABILITY" - Version is available for public use Version
  1539  	// is under development and not considered stable
  1540  	Type string `json:"type,omitempty"`
  1541  	// VersionNumber: The version number of the Data Fusion instance, such as
  1542  	// '6.0.1.0'.
  1543  	VersionNumber string `json:"versionNumber,omitempty"`
  1544  	// ForceSendFields is a list of field names (e.g. "AvailableFeatures") to
  1545  	// unconditionally include in API requests. By default, fields with empty or
  1546  	// default values are omitted from API requests. See
  1547  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1548  	// details.
  1549  	ForceSendFields []string `json:"-"`
  1550  	// NullFields is a list of field names (e.g. "AvailableFeatures") to include in
  1551  	// API requests with the JSON null value. By default, fields with empty values
  1552  	// are omitted from API requests. See
  1553  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1554  	NullFields []string `json:"-"`
  1555  }
  1556  
  1557  func (s *Version) MarshalJSON() ([]byte, error) {
  1558  	type NoMethod Version
  1559  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1560  }
  1561  
  1562  type ProjectsLocationsGetCall struct {
  1563  	s            *Service
  1564  	name         string
  1565  	urlParams_   gensupport.URLParams
  1566  	ifNoneMatch_ string
  1567  	ctx_         context.Context
  1568  	header_      http.Header
  1569  }
  1570  
  1571  // Get: Gets information about a location.
  1572  //
  1573  // - name: Resource name for the location.
  1574  func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall {
  1575  	c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1576  	c.name = name
  1577  	return c
  1578  }
  1579  
  1580  // Fields allows partial responses to be retrieved. See
  1581  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1582  // details.
  1583  func (c *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall {
  1584  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1585  	return c
  1586  }
  1587  
  1588  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  1589  // object's ETag matches the given value. This is useful for getting updates
  1590  // only after the object has changed since the last request.
  1591  func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall {
  1592  	c.ifNoneMatch_ = entityTag
  1593  	return c
  1594  }
  1595  
  1596  // Context sets the context to be used in this call's Do method.
  1597  func (c *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall {
  1598  	c.ctx_ = ctx
  1599  	return c
  1600  }
  1601  
  1602  // Header returns a http.Header that can be modified by the caller to add
  1603  // headers to the request.
  1604  func (c *ProjectsLocationsGetCall) Header() http.Header {
  1605  	if c.header_ == nil {
  1606  		c.header_ = make(http.Header)
  1607  	}
  1608  	return c.header_
  1609  }
  1610  
  1611  func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) {
  1612  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  1613  	if c.ifNoneMatch_ != "" {
  1614  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  1615  	}
  1616  	var body io.Reader = nil
  1617  	c.urlParams_.Set("alt", alt)
  1618  	c.urlParams_.Set("prettyPrint", "false")
  1619  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  1620  	urls += "?" + c.urlParams_.Encode()
  1621  	req, err := http.NewRequest("GET", urls, body)
  1622  	if err != nil {
  1623  		return nil, err
  1624  	}
  1625  	req.Header = reqHeaders
  1626  	googleapi.Expand(req.URL, map[string]string{
  1627  		"name": c.name,
  1628  	})
  1629  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1630  }
  1631  
  1632  // Do executes the "datafusion.projects.locations.get" call.
  1633  // Any non-2xx status code is an error. Response headers are in either
  1634  // *Location.ServerResponse.Header or (if a response was returned at all) in
  1635  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  1636  // whether the returned error was because http.StatusNotModified was returned.
  1637  func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) {
  1638  	gensupport.SetOptions(c.urlParams_, opts...)
  1639  	res, err := c.doRequest("json")
  1640  	if res != nil && res.StatusCode == http.StatusNotModified {
  1641  		if res.Body != nil {
  1642  			res.Body.Close()
  1643  		}
  1644  		return nil, gensupport.WrapError(&googleapi.Error{
  1645  			Code:   res.StatusCode,
  1646  			Header: res.Header,
  1647  		})
  1648  	}
  1649  	if err != nil {
  1650  		return nil, err
  1651  	}
  1652  	defer googleapi.CloseBody(res)
  1653  	if err := googleapi.CheckResponse(res); err != nil {
  1654  		return nil, gensupport.WrapError(err)
  1655  	}
  1656  	ret := &Location{
  1657  		ServerResponse: googleapi.ServerResponse{
  1658  			Header:         res.Header,
  1659  			HTTPStatusCode: res.StatusCode,
  1660  		},
  1661  	}
  1662  	target := &ret
  1663  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1664  		return nil, err
  1665  	}
  1666  	return ret, nil
  1667  }
  1668  
  1669  type ProjectsLocationsListCall struct {
  1670  	s            *Service
  1671  	name         string
  1672  	urlParams_   gensupport.URLParams
  1673  	ifNoneMatch_ string
  1674  	ctx_         context.Context
  1675  	header_      http.Header
  1676  }
  1677  
  1678  // List: Lists information about the supported locations for this service.
  1679  //
  1680  // - name: The resource that owns the locations collection, if applicable.
  1681  func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall {
  1682  	c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1683  	c.name = name
  1684  	return c
  1685  }
  1686  
  1687  // Filter sets the optional parameter "filter": A filter to narrow down results
  1688  // to a preferred subset. The filtering language accepts strings like
  1689  // "displayName=tokyo", and is documented in more detail in AIP-160
  1690  // (https://google.aip.dev/160).
  1691  func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall {
  1692  	c.urlParams_.Set("filter", filter)
  1693  	return c
  1694  }
  1695  
  1696  // IncludeUnrevealedLocations sets the optional parameter
  1697  // "includeUnrevealedLocations": If true, the returned list will include
  1698  // locations which are not yet revealed.
  1699  func (c *ProjectsLocationsListCall) IncludeUnrevealedLocations(includeUnrevealedLocations bool) *ProjectsLocationsListCall {
  1700  	c.urlParams_.Set("includeUnrevealedLocations", fmt.Sprint(includeUnrevealedLocations))
  1701  	return c
  1702  }
  1703  
  1704  // PageSize sets the optional parameter "pageSize": The maximum number of
  1705  // results to return. If not set, the service selects a default.
  1706  func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall {
  1707  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  1708  	return c
  1709  }
  1710  
  1711  // PageToken sets the optional parameter "pageToken": A page token received
  1712  // from the `next_page_token` field in the response. Send that page token to
  1713  // receive the subsequent page.
  1714  func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall {
  1715  	c.urlParams_.Set("pageToken", pageToken)
  1716  	return c
  1717  }
  1718  
  1719  // Fields allows partial responses to be retrieved. See
  1720  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1721  // details.
  1722  func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall {
  1723  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1724  	return c
  1725  }
  1726  
  1727  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  1728  // object's ETag matches the given value. This is useful for getting updates
  1729  // only after the object has changed since the last request.
  1730  func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall {
  1731  	c.ifNoneMatch_ = entityTag
  1732  	return c
  1733  }
  1734  
  1735  // Context sets the context to be used in this call's Do method.
  1736  func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall {
  1737  	c.ctx_ = ctx
  1738  	return c
  1739  }
  1740  
  1741  // Header returns a http.Header that can be modified by the caller to add
  1742  // headers to the request.
  1743  func (c *ProjectsLocationsListCall) Header() http.Header {
  1744  	if c.header_ == nil {
  1745  		c.header_ = make(http.Header)
  1746  	}
  1747  	return c.header_
  1748  }
  1749  
  1750  func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) {
  1751  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  1752  	if c.ifNoneMatch_ != "" {
  1753  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  1754  	}
  1755  	var body io.Reader = nil
  1756  	c.urlParams_.Set("alt", alt)
  1757  	c.urlParams_.Set("prettyPrint", "false")
  1758  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/locations")
  1759  	urls += "?" + c.urlParams_.Encode()
  1760  	req, err := http.NewRequest("GET", urls, body)
  1761  	if err != nil {
  1762  		return nil, err
  1763  	}
  1764  	req.Header = reqHeaders
  1765  	googleapi.Expand(req.URL, map[string]string{
  1766  		"name": c.name,
  1767  	})
  1768  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1769  }
  1770  
  1771  // Do executes the "datafusion.projects.locations.list" call.
  1772  // Any non-2xx status code is an error. Response headers are in either
  1773  // *ListLocationsResponse.ServerResponse.Header or (if a response was returned
  1774  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  1775  // check whether the returned error was because http.StatusNotModified was
  1776  // returned.
  1777  func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) {
  1778  	gensupport.SetOptions(c.urlParams_, opts...)
  1779  	res, err := c.doRequest("json")
  1780  	if res != nil && res.StatusCode == http.StatusNotModified {
  1781  		if res.Body != nil {
  1782  			res.Body.Close()
  1783  		}
  1784  		return nil, gensupport.WrapError(&googleapi.Error{
  1785  			Code:   res.StatusCode,
  1786  			Header: res.Header,
  1787  		})
  1788  	}
  1789  	if err != nil {
  1790  		return nil, err
  1791  	}
  1792  	defer googleapi.CloseBody(res)
  1793  	if err := googleapi.CheckResponse(res); err != nil {
  1794  		return nil, gensupport.WrapError(err)
  1795  	}
  1796  	ret := &ListLocationsResponse{
  1797  		ServerResponse: googleapi.ServerResponse{
  1798  			Header:         res.Header,
  1799  			HTTPStatusCode: res.StatusCode,
  1800  		},
  1801  	}
  1802  	target := &ret
  1803  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1804  		return nil, err
  1805  	}
  1806  	return ret, nil
  1807  }
  1808  
  1809  // Pages invokes f for each page of results.
  1810  // A non-nil error returned from f will halt the iteration.
  1811  // The provided context supersedes any context provided to the Context method.
  1812  func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) error) error {
  1813  	c.ctx_ = ctx
  1814  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  1815  	for {
  1816  		x, err := c.Do()
  1817  		if err != nil {
  1818  			return err
  1819  		}
  1820  		if err := f(x); err != nil {
  1821  			return err
  1822  		}
  1823  		if x.NextPageToken == "" {
  1824  			return nil
  1825  		}
  1826  		c.PageToken(x.NextPageToken)
  1827  	}
  1828  }
  1829  
  1830  type ProjectsLocationsRemoveIamPolicyCall struct {
  1831  	s                      *Service
  1832  	resource               string
  1833  	removeiampolicyrequest *RemoveIamPolicyRequest
  1834  	urlParams_             gensupport.URLParams
  1835  	ctx_                   context.Context
  1836  	header_                http.Header
  1837  }
  1838  
  1839  // RemoveIamPolicy: Remove IAM policy that is currently set on the given
  1840  // resource.
  1841  //
  1842  // - resource: The resource on which IAM policy to be removed is attached to.
  1843  func (r *ProjectsLocationsService) RemoveIamPolicy(resource string, removeiampolicyrequest *RemoveIamPolicyRequest) *ProjectsLocationsRemoveIamPolicyCall {
  1844  	c := &ProjectsLocationsRemoveIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1845  	c.resource = resource
  1846  	c.removeiampolicyrequest = removeiampolicyrequest
  1847  	return c
  1848  }
  1849  
  1850  // Fields allows partial responses to be retrieved. See
  1851  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1852  // details.
  1853  func (c *ProjectsLocationsRemoveIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsRemoveIamPolicyCall {
  1854  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1855  	return c
  1856  }
  1857  
  1858  // Context sets the context to be used in this call's Do method.
  1859  func (c *ProjectsLocationsRemoveIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsRemoveIamPolicyCall {
  1860  	c.ctx_ = ctx
  1861  	return c
  1862  }
  1863  
  1864  // Header returns a http.Header that can be modified by the caller to add
  1865  // headers to the request.
  1866  func (c *ProjectsLocationsRemoveIamPolicyCall) Header() http.Header {
  1867  	if c.header_ == nil {
  1868  		c.header_ = make(http.Header)
  1869  	}
  1870  	return c.header_
  1871  }
  1872  
  1873  func (c *ProjectsLocationsRemoveIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  1874  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  1875  	var body io.Reader = nil
  1876  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.removeiampolicyrequest)
  1877  	if err != nil {
  1878  		return nil, err
  1879  	}
  1880  	c.urlParams_.Set("alt", alt)
  1881  	c.urlParams_.Set("prettyPrint", "false")
  1882  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:removeIamPolicy")
  1883  	urls += "?" + c.urlParams_.Encode()
  1884  	req, err := http.NewRequest("POST", urls, body)
  1885  	if err != nil {
  1886  		return nil, err
  1887  	}
  1888  	req.Header = reqHeaders
  1889  	googleapi.Expand(req.URL, map[string]string{
  1890  		"resource": c.resource,
  1891  	})
  1892  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1893  }
  1894  
  1895  // Do executes the "datafusion.projects.locations.removeIamPolicy" call.
  1896  // Any non-2xx status code is an error. Response headers are in either
  1897  // *RemoveIamPolicyResponse.ServerResponse.Header or (if a response was
  1898  // returned at all) in error.(*googleapi.Error).Header. Use
  1899  // googleapi.IsNotModified to check whether the returned error was because
  1900  // http.StatusNotModified was returned.
  1901  func (c *ProjectsLocationsRemoveIamPolicyCall) Do(opts ...googleapi.CallOption) (*RemoveIamPolicyResponse, error) {
  1902  	gensupport.SetOptions(c.urlParams_, opts...)
  1903  	res, err := c.doRequest("json")
  1904  	if res != nil && res.StatusCode == http.StatusNotModified {
  1905  		if res.Body != nil {
  1906  			res.Body.Close()
  1907  		}
  1908  		return nil, gensupport.WrapError(&googleapi.Error{
  1909  			Code:   res.StatusCode,
  1910  			Header: res.Header,
  1911  		})
  1912  	}
  1913  	if err != nil {
  1914  		return nil, err
  1915  	}
  1916  	defer googleapi.CloseBody(res)
  1917  	if err := googleapi.CheckResponse(res); err != nil {
  1918  		return nil, gensupport.WrapError(err)
  1919  	}
  1920  	ret := &RemoveIamPolicyResponse{
  1921  		ServerResponse: googleapi.ServerResponse{
  1922  			Header:         res.Header,
  1923  			HTTPStatusCode: res.StatusCode,
  1924  		},
  1925  	}
  1926  	target := &ret
  1927  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1928  		return nil, err
  1929  	}
  1930  	return ret, nil
  1931  }
  1932  
  1933  type ProjectsLocationsInstancesCreateCall struct {
  1934  	s          *Service
  1935  	parent     string
  1936  	instance   *Instance
  1937  	urlParams_ gensupport.URLParams
  1938  	ctx_       context.Context
  1939  	header_    http.Header
  1940  }
  1941  
  1942  // Create: Creates a new Data Fusion instance in the specified project and
  1943  // location.
  1944  //
  1945  //   - parent: The instance's project and location in the format
  1946  //     projects/{project}/locations/{location}.
  1947  func (r *ProjectsLocationsInstancesService) Create(parent string, instance *Instance) *ProjectsLocationsInstancesCreateCall {
  1948  	c := &ProjectsLocationsInstancesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1949  	c.parent = parent
  1950  	c.instance = instance
  1951  	return c
  1952  }
  1953  
  1954  // InstanceId sets the optional parameter "instanceId": Required. The name of
  1955  // the instance to create. Instance name can only contain lowercase
  1956  // alphanumeric characters and hyphens. It must start with a letter and must
  1957  // not end with a hyphen. It can have a maximum of 30 characters.
  1958  func (c *ProjectsLocationsInstancesCreateCall) InstanceId(instanceId string) *ProjectsLocationsInstancesCreateCall {
  1959  	c.urlParams_.Set("instanceId", instanceId)
  1960  	return c
  1961  }
  1962  
  1963  // Fields allows partial responses to be retrieved. See
  1964  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1965  // details.
  1966  func (c *ProjectsLocationsInstancesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesCreateCall {
  1967  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1968  	return c
  1969  }
  1970  
  1971  // Context sets the context to be used in this call's Do method.
  1972  func (c *ProjectsLocationsInstancesCreateCall) Context(ctx context.Context) *ProjectsLocationsInstancesCreateCall {
  1973  	c.ctx_ = ctx
  1974  	return c
  1975  }
  1976  
  1977  // Header returns a http.Header that can be modified by the caller to add
  1978  // headers to the request.
  1979  func (c *ProjectsLocationsInstancesCreateCall) Header() http.Header {
  1980  	if c.header_ == nil {
  1981  		c.header_ = make(http.Header)
  1982  	}
  1983  	return c.header_
  1984  }
  1985  
  1986  func (c *ProjectsLocationsInstancesCreateCall) doRequest(alt string) (*http.Response, error) {
  1987  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  1988  	var body io.Reader = nil
  1989  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.instance)
  1990  	if err != nil {
  1991  		return nil, err
  1992  	}
  1993  	c.urlParams_.Set("alt", alt)
  1994  	c.urlParams_.Set("prettyPrint", "false")
  1995  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/instances")
  1996  	urls += "?" + c.urlParams_.Encode()
  1997  	req, err := http.NewRequest("POST", urls, body)
  1998  	if err != nil {
  1999  		return nil, err
  2000  	}
  2001  	req.Header = reqHeaders
  2002  	googleapi.Expand(req.URL, map[string]string{
  2003  		"parent": c.parent,
  2004  	})
  2005  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2006  }
  2007  
  2008  // Do executes the "datafusion.projects.locations.instances.create" call.
  2009  // Any non-2xx status code is an error. Response headers are in either
  2010  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2011  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2012  // whether the returned error was because http.StatusNotModified was returned.
  2013  func (c *ProjectsLocationsInstancesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2014  	gensupport.SetOptions(c.urlParams_, opts...)
  2015  	res, err := c.doRequest("json")
  2016  	if res != nil && res.StatusCode == http.StatusNotModified {
  2017  		if res.Body != nil {
  2018  			res.Body.Close()
  2019  		}
  2020  		return nil, gensupport.WrapError(&googleapi.Error{
  2021  			Code:   res.StatusCode,
  2022  			Header: res.Header,
  2023  		})
  2024  	}
  2025  	if err != nil {
  2026  		return nil, err
  2027  	}
  2028  	defer googleapi.CloseBody(res)
  2029  	if err := googleapi.CheckResponse(res); err != nil {
  2030  		return nil, gensupport.WrapError(err)
  2031  	}
  2032  	ret := &Operation{
  2033  		ServerResponse: googleapi.ServerResponse{
  2034  			Header:         res.Header,
  2035  			HTTPStatusCode: res.StatusCode,
  2036  		},
  2037  	}
  2038  	target := &ret
  2039  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2040  		return nil, err
  2041  	}
  2042  	return ret, nil
  2043  }
  2044  
  2045  type ProjectsLocationsInstancesDeleteCall struct {
  2046  	s          *Service
  2047  	name       string
  2048  	urlParams_ gensupport.URLParams
  2049  	ctx_       context.Context
  2050  	header_    http.Header
  2051  }
  2052  
  2053  // Delete: Deletes a single Data Fusion instance.
  2054  //
  2055  //   - name: The instance resource name in the format
  2056  //     projects/{project}/locations/{location}/instances/{instance}.
  2057  func (r *ProjectsLocationsInstancesService) Delete(name string) *ProjectsLocationsInstancesDeleteCall {
  2058  	c := &ProjectsLocationsInstancesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2059  	c.name = name
  2060  	return c
  2061  }
  2062  
  2063  // Fields allows partial responses to be retrieved. See
  2064  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2065  // details.
  2066  func (c *ProjectsLocationsInstancesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDeleteCall {
  2067  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2068  	return c
  2069  }
  2070  
  2071  // Context sets the context to be used in this call's Do method.
  2072  func (c *ProjectsLocationsInstancesDeleteCall) Context(ctx context.Context) *ProjectsLocationsInstancesDeleteCall {
  2073  	c.ctx_ = ctx
  2074  	return c
  2075  }
  2076  
  2077  // Header returns a http.Header that can be modified by the caller to add
  2078  // headers to the request.
  2079  func (c *ProjectsLocationsInstancesDeleteCall) Header() http.Header {
  2080  	if c.header_ == nil {
  2081  		c.header_ = make(http.Header)
  2082  	}
  2083  	return c.header_
  2084  }
  2085  
  2086  func (c *ProjectsLocationsInstancesDeleteCall) doRequest(alt string) (*http.Response, error) {
  2087  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2088  	var body io.Reader = nil
  2089  	c.urlParams_.Set("alt", alt)
  2090  	c.urlParams_.Set("prettyPrint", "false")
  2091  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  2092  	urls += "?" + c.urlParams_.Encode()
  2093  	req, err := http.NewRequest("DELETE", urls, body)
  2094  	if err != nil {
  2095  		return nil, err
  2096  	}
  2097  	req.Header = reqHeaders
  2098  	googleapi.Expand(req.URL, map[string]string{
  2099  		"name": c.name,
  2100  	})
  2101  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2102  }
  2103  
  2104  // Do executes the "datafusion.projects.locations.instances.delete" call.
  2105  // Any non-2xx status code is an error. Response headers are in either
  2106  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2107  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2108  // whether the returned error was because http.StatusNotModified was returned.
  2109  func (c *ProjectsLocationsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2110  	gensupport.SetOptions(c.urlParams_, opts...)
  2111  	res, err := c.doRequest("json")
  2112  	if res != nil && res.StatusCode == http.StatusNotModified {
  2113  		if res.Body != nil {
  2114  			res.Body.Close()
  2115  		}
  2116  		return nil, gensupport.WrapError(&googleapi.Error{
  2117  			Code:   res.StatusCode,
  2118  			Header: res.Header,
  2119  		})
  2120  	}
  2121  	if err != nil {
  2122  		return nil, err
  2123  	}
  2124  	defer googleapi.CloseBody(res)
  2125  	if err := googleapi.CheckResponse(res); err != nil {
  2126  		return nil, gensupport.WrapError(err)
  2127  	}
  2128  	ret := &Operation{
  2129  		ServerResponse: googleapi.ServerResponse{
  2130  			Header:         res.Header,
  2131  			HTTPStatusCode: res.StatusCode,
  2132  		},
  2133  	}
  2134  	target := &ret
  2135  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2136  		return nil, err
  2137  	}
  2138  	return ret, nil
  2139  }
  2140  
  2141  type ProjectsLocationsInstancesGetCall struct {
  2142  	s            *Service
  2143  	name         string
  2144  	urlParams_   gensupport.URLParams
  2145  	ifNoneMatch_ string
  2146  	ctx_         context.Context
  2147  	header_      http.Header
  2148  }
  2149  
  2150  // Get: Gets details of a single Data Fusion instance.
  2151  //
  2152  //   - name: The instance resource name in the format
  2153  //     projects/{project}/locations/{location}/instances/{instance}.
  2154  func (r *ProjectsLocationsInstancesService) Get(name string) *ProjectsLocationsInstancesGetCall {
  2155  	c := &ProjectsLocationsInstancesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2156  	c.name = name
  2157  	return c
  2158  }
  2159  
  2160  // Fields allows partial responses to be retrieved. See
  2161  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2162  // details.
  2163  func (c *ProjectsLocationsInstancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetCall {
  2164  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2165  	return c
  2166  }
  2167  
  2168  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2169  // object's ETag matches the given value. This is useful for getting updates
  2170  // only after the object has changed since the last request.
  2171  func (c *ProjectsLocationsInstancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetCall {
  2172  	c.ifNoneMatch_ = entityTag
  2173  	return c
  2174  }
  2175  
  2176  // Context sets the context to be used in this call's Do method.
  2177  func (c *ProjectsLocationsInstancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetCall {
  2178  	c.ctx_ = ctx
  2179  	return c
  2180  }
  2181  
  2182  // Header returns a http.Header that can be modified by the caller to add
  2183  // headers to the request.
  2184  func (c *ProjectsLocationsInstancesGetCall) Header() http.Header {
  2185  	if c.header_ == nil {
  2186  		c.header_ = make(http.Header)
  2187  	}
  2188  	return c.header_
  2189  }
  2190  
  2191  func (c *ProjectsLocationsInstancesGetCall) doRequest(alt string) (*http.Response, error) {
  2192  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2193  	if c.ifNoneMatch_ != "" {
  2194  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2195  	}
  2196  	var body io.Reader = nil
  2197  	c.urlParams_.Set("alt", alt)
  2198  	c.urlParams_.Set("prettyPrint", "false")
  2199  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  2200  	urls += "?" + c.urlParams_.Encode()
  2201  	req, err := http.NewRequest("GET", urls, body)
  2202  	if err != nil {
  2203  		return nil, err
  2204  	}
  2205  	req.Header = reqHeaders
  2206  	googleapi.Expand(req.URL, map[string]string{
  2207  		"name": c.name,
  2208  	})
  2209  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2210  }
  2211  
  2212  // Do executes the "datafusion.projects.locations.instances.get" call.
  2213  // Any non-2xx status code is an error. Response headers are in either
  2214  // *Instance.ServerResponse.Header or (if a response was returned at all) in
  2215  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2216  // whether the returned error was because http.StatusNotModified was returned.
  2217  func (c *ProjectsLocationsInstancesGetCall) Do(opts ...googleapi.CallOption) (*Instance, error) {
  2218  	gensupport.SetOptions(c.urlParams_, opts...)
  2219  	res, err := c.doRequest("json")
  2220  	if res != nil && res.StatusCode == http.StatusNotModified {
  2221  		if res.Body != nil {
  2222  			res.Body.Close()
  2223  		}
  2224  		return nil, gensupport.WrapError(&googleapi.Error{
  2225  			Code:   res.StatusCode,
  2226  			Header: res.Header,
  2227  		})
  2228  	}
  2229  	if err != nil {
  2230  		return nil, err
  2231  	}
  2232  	defer googleapi.CloseBody(res)
  2233  	if err := googleapi.CheckResponse(res); err != nil {
  2234  		return nil, gensupport.WrapError(err)
  2235  	}
  2236  	ret := &Instance{
  2237  		ServerResponse: googleapi.ServerResponse{
  2238  			Header:         res.Header,
  2239  			HTTPStatusCode: res.StatusCode,
  2240  		},
  2241  	}
  2242  	target := &ret
  2243  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2244  		return nil, err
  2245  	}
  2246  	return ret, nil
  2247  }
  2248  
  2249  type ProjectsLocationsInstancesGetIamPolicyCall struct {
  2250  	s            *Service
  2251  	resource     string
  2252  	urlParams_   gensupport.URLParams
  2253  	ifNoneMatch_ string
  2254  	ctx_         context.Context
  2255  	header_      http.Header
  2256  }
  2257  
  2258  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  2259  // empty policy if the resource exists and does not have a policy set.
  2260  //
  2261  //   - resource: REQUIRED: The resource for which the policy is being requested.
  2262  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  2263  //     for the appropriate value for this field.
  2264  func (r *ProjectsLocationsInstancesService) GetIamPolicy(resource string) *ProjectsLocationsInstancesGetIamPolicyCall {
  2265  	c := &ProjectsLocationsInstancesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2266  	c.resource = resource
  2267  	return c
  2268  }
  2269  
  2270  // OptionsRequestedPolicyVersion sets the optional parameter
  2271  // "options.requestedPolicyVersion": The maximum policy version that will be
  2272  // used to format the policy. Valid values are 0, 1, and 3. Requests specifying
  2273  // an invalid value will be rejected. Requests for policies with any
  2274  // conditional role bindings must specify version 3. Policies with no
  2275  // conditional role bindings may specify any valid value or leave the field
  2276  // unset. The policy in the response might use the policy version that you
  2277  // specified, or it might use a lower policy version. For example, if you
  2278  // specify version 3, but the policy has no conditional role bindings, the
  2279  // response uses version 1. To learn which resources support conditions in
  2280  // their IAM policies, see the IAM documentation
  2281  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  2282  func (c *ProjectsLocationsInstancesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsInstancesGetIamPolicyCall {
  2283  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  2284  	return c
  2285  }
  2286  
  2287  // Fields allows partial responses to be retrieved. See
  2288  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2289  // details.
  2290  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetIamPolicyCall {
  2291  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2292  	return c
  2293  }
  2294  
  2295  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2296  // object's ETag matches the given value. This is useful for getting updates
  2297  // only after the object has changed since the last request.
  2298  func (c *ProjectsLocationsInstancesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetIamPolicyCall {
  2299  	c.ifNoneMatch_ = entityTag
  2300  	return c
  2301  }
  2302  
  2303  // Context sets the context to be used in this call's Do method.
  2304  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetIamPolicyCall {
  2305  	c.ctx_ = ctx
  2306  	return c
  2307  }
  2308  
  2309  // Header returns a http.Header that can be modified by the caller to add
  2310  // headers to the request.
  2311  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Header() http.Header {
  2312  	if c.header_ == nil {
  2313  		c.header_ = make(http.Header)
  2314  	}
  2315  	return c.header_
  2316  }
  2317  
  2318  func (c *ProjectsLocationsInstancesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  2319  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2320  	if c.ifNoneMatch_ != "" {
  2321  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2322  	}
  2323  	var body io.Reader = nil
  2324  	c.urlParams_.Set("alt", alt)
  2325  	c.urlParams_.Set("prettyPrint", "false")
  2326  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:getIamPolicy")
  2327  	urls += "?" + c.urlParams_.Encode()
  2328  	req, err := http.NewRequest("GET", urls, body)
  2329  	if err != nil {
  2330  		return nil, err
  2331  	}
  2332  	req.Header = reqHeaders
  2333  	googleapi.Expand(req.URL, map[string]string{
  2334  		"resource": c.resource,
  2335  	})
  2336  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2337  }
  2338  
  2339  // Do executes the "datafusion.projects.locations.instances.getIamPolicy" call.
  2340  // Any non-2xx status code is an error. Response headers are in either
  2341  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  2342  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2343  // whether the returned error was because http.StatusNotModified was returned.
  2344  func (c *ProjectsLocationsInstancesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  2345  	gensupport.SetOptions(c.urlParams_, opts...)
  2346  	res, err := c.doRequest("json")
  2347  	if res != nil && res.StatusCode == http.StatusNotModified {
  2348  		if res.Body != nil {
  2349  			res.Body.Close()
  2350  		}
  2351  		return nil, gensupport.WrapError(&googleapi.Error{
  2352  			Code:   res.StatusCode,
  2353  			Header: res.Header,
  2354  		})
  2355  	}
  2356  	if err != nil {
  2357  		return nil, err
  2358  	}
  2359  	defer googleapi.CloseBody(res)
  2360  	if err := googleapi.CheckResponse(res); err != nil {
  2361  		return nil, gensupport.WrapError(err)
  2362  	}
  2363  	ret := &Policy{
  2364  		ServerResponse: googleapi.ServerResponse{
  2365  			Header:         res.Header,
  2366  			HTTPStatusCode: res.StatusCode,
  2367  		},
  2368  	}
  2369  	target := &ret
  2370  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2371  		return nil, err
  2372  	}
  2373  	return ret, nil
  2374  }
  2375  
  2376  type ProjectsLocationsInstancesListCall struct {
  2377  	s            *Service
  2378  	parent       string
  2379  	urlParams_   gensupport.URLParams
  2380  	ifNoneMatch_ string
  2381  	ctx_         context.Context
  2382  	header_      http.Header
  2383  }
  2384  
  2385  // List: Lists Data Fusion instances in the specified project and location.
  2386  //
  2387  //   - parent: The project and location for which to retrieve instance
  2388  //     information in the format projects/{project}/locations/{location}. If the
  2389  //     location is specified as '-' (wildcard), then all regions available to the
  2390  //     project are queried, and the results are aggregated.
  2391  func (r *ProjectsLocationsInstancesService) List(parent string) *ProjectsLocationsInstancesListCall {
  2392  	c := &ProjectsLocationsInstancesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2393  	c.parent = parent
  2394  	return c
  2395  }
  2396  
  2397  // Filter sets the optional parameter "filter": List filter.
  2398  func (c *ProjectsLocationsInstancesListCall) Filter(filter string) *ProjectsLocationsInstancesListCall {
  2399  	c.urlParams_.Set("filter", filter)
  2400  	return c
  2401  }
  2402  
  2403  // OrderBy sets the optional parameter "orderBy": Sort results. Supported
  2404  // values are "name", "name desc", or "" (unsorted).
  2405  func (c *ProjectsLocationsInstancesListCall) OrderBy(orderBy string) *ProjectsLocationsInstancesListCall {
  2406  	c.urlParams_.Set("orderBy", orderBy)
  2407  	return c
  2408  }
  2409  
  2410  // PageSize sets the optional parameter "pageSize": The maximum number of items
  2411  // to return.
  2412  func (c *ProjectsLocationsInstancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesListCall {
  2413  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  2414  	return c
  2415  }
  2416  
  2417  // PageToken sets the optional parameter "pageToken": The next_page_token value
  2418  // to use if there are additional results to retrieve for this list request.
  2419  func (c *ProjectsLocationsInstancesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesListCall {
  2420  	c.urlParams_.Set("pageToken", pageToken)
  2421  	return c
  2422  }
  2423  
  2424  // Fields allows partial responses to be retrieved. See
  2425  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2426  // details.
  2427  func (c *ProjectsLocationsInstancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesListCall {
  2428  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2429  	return c
  2430  }
  2431  
  2432  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2433  // object's ETag matches the given value. This is useful for getting updates
  2434  // only after the object has changed since the last request.
  2435  func (c *ProjectsLocationsInstancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesListCall {
  2436  	c.ifNoneMatch_ = entityTag
  2437  	return c
  2438  }
  2439  
  2440  // Context sets the context to be used in this call's Do method.
  2441  func (c *ProjectsLocationsInstancesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesListCall {
  2442  	c.ctx_ = ctx
  2443  	return c
  2444  }
  2445  
  2446  // Header returns a http.Header that can be modified by the caller to add
  2447  // headers to the request.
  2448  func (c *ProjectsLocationsInstancesListCall) Header() http.Header {
  2449  	if c.header_ == nil {
  2450  		c.header_ = make(http.Header)
  2451  	}
  2452  	return c.header_
  2453  }
  2454  
  2455  func (c *ProjectsLocationsInstancesListCall) doRequest(alt string) (*http.Response, error) {
  2456  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2457  	if c.ifNoneMatch_ != "" {
  2458  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2459  	}
  2460  	var body io.Reader = nil
  2461  	c.urlParams_.Set("alt", alt)
  2462  	c.urlParams_.Set("prettyPrint", "false")
  2463  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/instances")
  2464  	urls += "?" + c.urlParams_.Encode()
  2465  	req, err := http.NewRequest("GET", urls, body)
  2466  	if err != nil {
  2467  		return nil, err
  2468  	}
  2469  	req.Header = reqHeaders
  2470  	googleapi.Expand(req.URL, map[string]string{
  2471  		"parent": c.parent,
  2472  	})
  2473  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2474  }
  2475  
  2476  // Do executes the "datafusion.projects.locations.instances.list" call.
  2477  // Any non-2xx status code is an error. Response headers are in either
  2478  // *ListInstancesResponse.ServerResponse.Header or (if a response was returned
  2479  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  2480  // check whether the returned error was because http.StatusNotModified was
  2481  // returned.
  2482  func (c *ProjectsLocationsInstancesListCall) Do(opts ...googleapi.CallOption) (*ListInstancesResponse, error) {
  2483  	gensupport.SetOptions(c.urlParams_, opts...)
  2484  	res, err := c.doRequest("json")
  2485  	if res != nil && res.StatusCode == http.StatusNotModified {
  2486  		if res.Body != nil {
  2487  			res.Body.Close()
  2488  		}
  2489  		return nil, gensupport.WrapError(&googleapi.Error{
  2490  			Code:   res.StatusCode,
  2491  			Header: res.Header,
  2492  		})
  2493  	}
  2494  	if err != nil {
  2495  		return nil, err
  2496  	}
  2497  	defer googleapi.CloseBody(res)
  2498  	if err := googleapi.CheckResponse(res); err != nil {
  2499  		return nil, gensupport.WrapError(err)
  2500  	}
  2501  	ret := &ListInstancesResponse{
  2502  		ServerResponse: googleapi.ServerResponse{
  2503  			Header:         res.Header,
  2504  			HTTPStatusCode: res.StatusCode,
  2505  		},
  2506  	}
  2507  	target := &ret
  2508  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2509  		return nil, err
  2510  	}
  2511  	return ret, nil
  2512  }
  2513  
  2514  // Pages invokes f for each page of results.
  2515  // A non-nil error returned from f will halt the iteration.
  2516  // The provided context supersedes any context provided to the Context method.
  2517  func (c *ProjectsLocationsInstancesListCall) Pages(ctx context.Context, f func(*ListInstancesResponse) error) error {
  2518  	c.ctx_ = ctx
  2519  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  2520  	for {
  2521  		x, err := c.Do()
  2522  		if err != nil {
  2523  			return err
  2524  		}
  2525  		if err := f(x); err != nil {
  2526  			return err
  2527  		}
  2528  		if x.NextPageToken == "" {
  2529  			return nil
  2530  		}
  2531  		c.PageToken(x.NextPageToken)
  2532  	}
  2533  }
  2534  
  2535  type ProjectsLocationsInstancesPatchCall struct {
  2536  	s          *Service
  2537  	name       string
  2538  	instance   *Instance
  2539  	urlParams_ gensupport.URLParams
  2540  	ctx_       context.Context
  2541  	header_    http.Header
  2542  }
  2543  
  2544  // Patch: Updates a single Data Fusion instance.
  2545  //
  2546  //   - name: Output only. The name of this instance is in the form of
  2547  //     projects/{project}/locations/{location}/instances/{instance}.
  2548  func (r *ProjectsLocationsInstancesService) Patch(name string, instance *Instance) *ProjectsLocationsInstancesPatchCall {
  2549  	c := &ProjectsLocationsInstancesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2550  	c.name = name
  2551  	c.instance = instance
  2552  	return c
  2553  }
  2554  
  2555  // UpdateMask sets the optional parameter "updateMask": Field mask is used to
  2556  // specify the fields that the update will overwrite in an instance resource.
  2557  // The fields specified in the update_mask are relative to the resource, not
  2558  // the full request. A field will be overwritten if it is in the mask. If the
  2559  // user does not provide a mask, all the supported fields (labels and options
  2560  // currently) will be overwritten.
  2561  func (c *ProjectsLocationsInstancesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsInstancesPatchCall {
  2562  	c.urlParams_.Set("updateMask", updateMask)
  2563  	return c
  2564  }
  2565  
  2566  // Fields allows partial responses to be retrieved. See
  2567  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2568  // details.
  2569  func (c *ProjectsLocationsInstancesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesPatchCall {
  2570  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2571  	return c
  2572  }
  2573  
  2574  // Context sets the context to be used in this call's Do method.
  2575  func (c *ProjectsLocationsInstancesPatchCall) Context(ctx context.Context) *ProjectsLocationsInstancesPatchCall {
  2576  	c.ctx_ = ctx
  2577  	return c
  2578  }
  2579  
  2580  // Header returns a http.Header that can be modified by the caller to add
  2581  // headers to the request.
  2582  func (c *ProjectsLocationsInstancesPatchCall) Header() http.Header {
  2583  	if c.header_ == nil {
  2584  		c.header_ = make(http.Header)
  2585  	}
  2586  	return c.header_
  2587  }
  2588  
  2589  func (c *ProjectsLocationsInstancesPatchCall) doRequest(alt string) (*http.Response, error) {
  2590  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2591  	var body io.Reader = nil
  2592  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.instance)
  2593  	if err != nil {
  2594  		return nil, err
  2595  	}
  2596  	c.urlParams_.Set("alt", alt)
  2597  	c.urlParams_.Set("prettyPrint", "false")
  2598  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  2599  	urls += "?" + c.urlParams_.Encode()
  2600  	req, err := http.NewRequest("PATCH", urls, body)
  2601  	if err != nil {
  2602  		return nil, err
  2603  	}
  2604  	req.Header = reqHeaders
  2605  	googleapi.Expand(req.URL, map[string]string{
  2606  		"name": c.name,
  2607  	})
  2608  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2609  }
  2610  
  2611  // Do executes the "datafusion.projects.locations.instances.patch" call.
  2612  // Any non-2xx status code is an error. Response headers are in either
  2613  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2614  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2615  // whether the returned error was because http.StatusNotModified was returned.
  2616  func (c *ProjectsLocationsInstancesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2617  	gensupport.SetOptions(c.urlParams_, opts...)
  2618  	res, err := c.doRequest("json")
  2619  	if res != nil && res.StatusCode == http.StatusNotModified {
  2620  		if res.Body != nil {
  2621  			res.Body.Close()
  2622  		}
  2623  		return nil, gensupport.WrapError(&googleapi.Error{
  2624  			Code:   res.StatusCode,
  2625  			Header: res.Header,
  2626  		})
  2627  	}
  2628  	if err != nil {
  2629  		return nil, err
  2630  	}
  2631  	defer googleapi.CloseBody(res)
  2632  	if err := googleapi.CheckResponse(res); err != nil {
  2633  		return nil, gensupport.WrapError(err)
  2634  	}
  2635  	ret := &Operation{
  2636  		ServerResponse: googleapi.ServerResponse{
  2637  			Header:         res.Header,
  2638  			HTTPStatusCode: res.StatusCode,
  2639  		},
  2640  	}
  2641  	target := &ret
  2642  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2643  		return nil, err
  2644  	}
  2645  	return ret, nil
  2646  }
  2647  
  2648  type ProjectsLocationsInstancesRestartCall struct {
  2649  	s                      *Service
  2650  	name                   string
  2651  	restartinstancerequest *RestartInstanceRequest
  2652  	urlParams_             gensupport.URLParams
  2653  	ctx_                   context.Context
  2654  	header_                http.Header
  2655  }
  2656  
  2657  // Restart: Restart a single Data Fusion instance. At the end of an operation
  2658  // instance is fully restarted.
  2659  //
  2660  //   - name: Name of the Data Fusion instance which need to be restarted in the
  2661  //     form of projects/{project}/locations/{location}/instances/{instance}.
  2662  func (r *ProjectsLocationsInstancesService) Restart(name string, restartinstancerequest *RestartInstanceRequest) *ProjectsLocationsInstancesRestartCall {
  2663  	c := &ProjectsLocationsInstancesRestartCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2664  	c.name = name
  2665  	c.restartinstancerequest = restartinstancerequest
  2666  	return c
  2667  }
  2668  
  2669  // Fields allows partial responses to be retrieved. See
  2670  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2671  // details.
  2672  func (c *ProjectsLocationsInstancesRestartCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesRestartCall {
  2673  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2674  	return c
  2675  }
  2676  
  2677  // Context sets the context to be used in this call's Do method.
  2678  func (c *ProjectsLocationsInstancesRestartCall) Context(ctx context.Context) *ProjectsLocationsInstancesRestartCall {
  2679  	c.ctx_ = ctx
  2680  	return c
  2681  }
  2682  
  2683  // Header returns a http.Header that can be modified by the caller to add
  2684  // headers to the request.
  2685  func (c *ProjectsLocationsInstancesRestartCall) Header() http.Header {
  2686  	if c.header_ == nil {
  2687  		c.header_ = make(http.Header)
  2688  	}
  2689  	return c.header_
  2690  }
  2691  
  2692  func (c *ProjectsLocationsInstancesRestartCall) doRequest(alt string) (*http.Response, error) {
  2693  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2694  	var body io.Reader = nil
  2695  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.restartinstancerequest)
  2696  	if err != nil {
  2697  		return nil, err
  2698  	}
  2699  	c.urlParams_.Set("alt", alt)
  2700  	c.urlParams_.Set("prettyPrint", "false")
  2701  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:restart")
  2702  	urls += "?" + c.urlParams_.Encode()
  2703  	req, err := http.NewRequest("POST", urls, body)
  2704  	if err != nil {
  2705  		return nil, err
  2706  	}
  2707  	req.Header = reqHeaders
  2708  	googleapi.Expand(req.URL, map[string]string{
  2709  		"name": c.name,
  2710  	})
  2711  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2712  }
  2713  
  2714  // Do executes the "datafusion.projects.locations.instances.restart" call.
  2715  // Any non-2xx status code is an error. Response headers are in either
  2716  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2717  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2718  // whether the returned error was because http.StatusNotModified was returned.
  2719  func (c *ProjectsLocationsInstancesRestartCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2720  	gensupport.SetOptions(c.urlParams_, opts...)
  2721  	res, err := c.doRequest("json")
  2722  	if res != nil && res.StatusCode == http.StatusNotModified {
  2723  		if res.Body != nil {
  2724  			res.Body.Close()
  2725  		}
  2726  		return nil, gensupport.WrapError(&googleapi.Error{
  2727  			Code:   res.StatusCode,
  2728  			Header: res.Header,
  2729  		})
  2730  	}
  2731  	if err != nil {
  2732  		return nil, err
  2733  	}
  2734  	defer googleapi.CloseBody(res)
  2735  	if err := googleapi.CheckResponse(res); err != nil {
  2736  		return nil, gensupport.WrapError(err)
  2737  	}
  2738  	ret := &Operation{
  2739  		ServerResponse: googleapi.ServerResponse{
  2740  			Header:         res.Header,
  2741  			HTTPStatusCode: res.StatusCode,
  2742  		},
  2743  	}
  2744  	target := &ret
  2745  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2746  		return nil, err
  2747  	}
  2748  	return ret, nil
  2749  }
  2750  
  2751  type ProjectsLocationsInstancesSetIamPolicyCall struct {
  2752  	s                   *Service
  2753  	resource            string
  2754  	setiampolicyrequest *SetIamPolicyRequest
  2755  	urlParams_          gensupport.URLParams
  2756  	ctx_                context.Context
  2757  	header_             http.Header
  2758  }
  2759  
  2760  // SetIamPolicy: Sets the access control policy on the specified resource.
  2761  // Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`,
  2762  // and `PERMISSION_DENIED` errors.
  2763  //
  2764  //   - resource: REQUIRED: The resource for which the policy is being specified.
  2765  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  2766  //     for the appropriate value for this field.
  2767  func (r *ProjectsLocationsInstancesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsInstancesSetIamPolicyCall {
  2768  	c := &ProjectsLocationsInstancesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2769  	c.resource = resource
  2770  	c.setiampolicyrequest = setiampolicyrequest
  2771  	return c
  2772  }
  2773  
  2774  // Fields allows partial responses to be retrieved. See
  2775  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2776  // details.
  2777  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesSetIamPolicyCall {
  2778  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2779  	return c
  2780  }
  2781  
  2782  // Context sets the context to be used in this call's Do method.
  2783  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesSetIamPolicyCall {
  2784  	c.ctx_ = ctx
  2785  	return c
  2786  }
  2787  
  2788  // Header returns a http.Header that can be modified by the caller to add
  2789  // headers to the request.
  2790  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Header() http.Header {
  2791  	if c.header_ == nil {
  2792  		c.header_ = make(http.Header)
  2793  	}
  2794  	return c.header_
  2795  }
  2796  
  2797  func (c *ProjectsLocationsInstancesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  2798  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2799  	var body io.Reader = nil
  2800  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  2801  	if err != nil {
  2802  		return nil, err
  2803  	}
  2804  	c.urlParams_.Set("alt", alt)
  2805  	c.urlParams_.Set("prettyPrint", "false")
  2806  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:setIamPolicy")
  2807  	urls += "?" + c.urlParams_.Encode()
  2808  	req, err := http.NewRequest("POST", urls, body)
  2809  	if err != nil {
  2810  		return nil, err
  2811  	}
  2812  	req.Header = reqHeaders
  2813  	googleapi.Expand(req.URL, map[string]string{
  2814  		"resource": c.resource,
  2815  	})
  2816  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2817  }
  2818  
  2819  // Do executes the "datafusion.projects.locations.instances.setIamPolicy" call.
  2820  // Any non-2xx status code is an error. Response headers are in either
  2821  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  2822  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2823  // whether the returned error was because http.StatusNotModified was returned.
  2824  func (c *ProjectsLocationsInstancesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  2825  	gensupport.SetOptions(c.urlParams_, opts...)
  2826  	res, err := c.doRequest("json")
  2827  	if res != nil && res.StatusCode == http.StatusNotModified {
  2828  		if res.Body != nil {
  2829  			res.Body.Close()
  2830  		}
  2831  		return nil, gensupport.WrapError(&googleapi.Error{
  2832  			Code:   res.StatusCode,
  2833  			Header: res.Header,
  2834  		})
  2835  	}
  2836  	if err != nil {
  2837  		return nil, err
  2838  	}
  2839  	defer googleapi.CloseBody(res)
  2840  	if err := googleapi.CheckResponse(res); err != nil {
  2841  		return nil, gensupport.WrapError(err)
  2842  	}
  2843  	ret := &Policy{
  2844  		ServerResponse: googleapi.ServerResponse{
  2845  			Header:         res.Header,
  2846  			HTTPStatusCode: res.StatusCode,
  2847  		},
  2848  	}
  2849  	target := &ret
  2850  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2851  		return nil, err
  2852  	}
  2853  	return ret, nil
  2854  }
  2855  
  2856  type ProjectsLocationsInstancesTestIamPermissionsCall struct {
  2857  	s                         *Service
  2858  	resource                  string
  2859  	testiampermissionsrequest *TestIamPermissionsRequest
  2860  	urlParams_                gensupport.URLParams
  2861  	ctx_                      context.Context
  2862  	header_                   http.Header
  2863  }
  2864  
  2865  // TestIamPermissions: Returns permissions that a caller has on the specified
  2866  // resource. If the resource does not exist, this will return an empty set of
  2867  // permissions, not a `NOT_FOUND` error. Note: This operation is designed to be
  2868  // used for building permission-aware UIs and command-line tools, not for
  2869  // authorization checking. This operation may "fail open" without warning.
  2870  //
  2871  //   - resource: REQUIRED: The resource for which the policy detail is being
  2872  //     requested. See Resource names
  2873  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  2874  //     value for this field.
  2875  func (r *ProjectsLocationsInstancesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsInstancesTestIamPermissionsCall {
  2876  	c := &ProjectsLocationsInstancesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2877  	c.resource = resource
  2878  	c.testiampermissionsrequest = testiampermissionsrequest
  2879  	return c
  2880  }
  2881  
  2882  // Fields allows partial responses to be retrieved. See
  2883  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2884  // details.
  2885  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesTestIamPermissionsCall {
  2886  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2887  	return c
  2888  }
  2889  
  2890  // Context sets the context to be used in this call's Do method.
  2891  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsInstancesTestIamPermissionsCall {
  2892  	c.ctx_ = ctx
  2893  	return c
  2894  }
  2895  
  2896  // Header returns a http.Header that can be modified by the caller to add
  2897  // headers to the request.
  2898  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Header() http.Header {
  2899  	if c.header_ == nil {
  2900  		c.header_ = make(http.Header)
  2901  	}
  2902  	return c.header_
  2903  }
  2904  
  2905  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  2906  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2907  	var body io.Reader = nil
  2908  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  2909  	if err != nil {
  2910  		return nil, err
  2911  	}
  2912  	c.urlParams_.Set("alt", alt)
  2913  	c.urlParams_.Set("prettyPrint", "false")
  2914  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:testIamPermissions")
  2915  	urls += "?" + c.urlParams_.Encode()
  2916  	req, err := http.NewRequest("POST", urls, body)
  2917  	if err != nil {
  2918  		return nil, err
  2919  	}
  2920  	req.Header = reqHeaders
  2921  	googleapi.Expand(req.URL, map[string]string{
  2922  		"resource": c.resource,
  2923  	})
  2924  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2925  }
  2926  
  2927  // Do executes the "datafusion.projects.locations.instances.testIamPermissions" call.
  2928  // Any non-2xx status code is an error. Response headers are in either
  2929  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  2930  // returned at all) in error.(*googleapi.Error).Header. Use
  2931  // googleapi.IsNotModified to check whether the returned error was because
  2932  // http.StatusNotModified was returned.
  2933  func (c *ProjectsLocationsInstancesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  2934  	gensupport.SetOptions(c.urlParams_, opts...)
  2935  	res, err := c.doRequest("json")
  2936  	if res != nil && res.StatusCode == http.StatusNotModified {
  2937  		if res.Body != nil {
  2938  			res.Body.Close()
  2939  		}
  2940  		return nil, gensupport.WrapError(&googleapi.Error{
  2941  			Code:   res.StatusCode,
  2942  			Header: res.Header,
  2943  		})
  2944  	}
  2945  	if err != nil {
  2946  		return nil, err
  2947  	}
  2948  	defer googleapi.CloseBody(res)
  2949  	if err := googleapi.CheckResponse(res); err != nil {
  2950  		return nil, gensupport.WrapError(err)
  2951  	}
  2952  	ret := &TestIamPermissionsResponse{
  2953  		ServerResponse: googleapi.ServerResponse{
  2954  			Header:         res.Header,
  2955  			HTTPStatusCode: res.StatusCode,
  2956  		},
  2957  	}
  2958  	target := &ret
  2959  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2960  		return nil, err
  2961  	}
  2962  	return ret, nil
  2963  }
  2964  
  2965  type ProjectsLocationsInstancesUpgradeCall struct {
  2966  	s                      *Service
  2967  	name                   string
  2968  	upgradeinstancerequest *UpgradeInstanceRequest
  2969  	urlParams_             gensupport.URLParams
  2970  	ctx_                   context.Context
  2971  	header_                http.Header
  2972  }
  2973  
  2974  // Upgrade: Upgrade a single Data Fusion instance. At the end of an operation
  2975  // instance is fully upgraded.
  2976  //
  2977  //   - name: Name of the Data Fusion instance which need to be upgraded in the
  2978  //     form of projects/{project}/locations/{location}/instances/{instance}
  2979  //     Instance will be upgraded with the latest stable version of the Data
  2980  //     Fusion.
  2981  func (r *ProjectsLocationsInstancesService) Upgrade(name string, upgradeinstancerequest *UpgradeInstanceRequest) *ProjectsLocationsInstancesUpgradeCall {
  2982  	c := &ProjectsLocationsInstancesUpgradeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2983  	c.name = name
  2984  	c.upgradeinstancerequest = upgradeinstancerequest
  2985  	return c
  2986  }
  2987  
  2988  // Fields allows partial responses to be retrieved. See
  2989  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2990  // details.
  2991  func (c *ProjectsLocationsInstancesUpgradeCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesUpgradeCall {
  2992  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2993  	return c
  2994  }
  2995  
  2996  // Context sets the context to be used in this call's Do method.
  2997  func (c *ProjectsLocationsInstancesUpgradeCall) Context(ctx context.Context) *ProjectsLocationsInstancesUpgradeCall {
  2998  	c.ctx_ = ctx
  2999  	return c
  3000  }
  3001  
  3002  // Header returns a http.Header that can be modified by the caller to add
  3003  // headers to the request.
  3004  func (c *ProjectsLocationsInstancesUpgradeCall) Header() http.Header {
  3005  	if c.header_ == nil {
  3006  		c.header_ = make(http.Header)
  3007  	}
  3008  	return c.header_
  3009  }
  3010  
  3011  func (c *ProjectsLocationsInstancesUpgradeCall) doRequest(alt string) (*http.Response, error) {
  3012  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3013  	var body io.Reader = nil
  3014  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.upgradeinstancerequest)
  3015  	if err != nil {
  3016  		return nil, err
  3017  	}
  3018  	c.urlParams_.Set("alt", alt)
  3019  	c.urlParams_.Set("prettyPrint", "false")
  3020  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:upgrade")
  3021  	urls += "?" + c.urlParams_.Encode()
  3022  	req, err := http.NewRequest("POST", urls, body)
  3023  	if err != nil {
  3024  		return nil, err
  3025  	}
  3026  	req.Header = reqHeaders
  3027  	googleapi.Expand(req.URL, map[string]string{
  3028  		"name": c.name,
  3029  	})
  3030  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3031  }
  3032  
  3033  // Do executes the "datafusion.projects.locations.instances.upgrade" call.
  3034  // Any non-2xx status code is an error. Response headers are in either
  3035  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3036  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3037  // whether the returned error was because http.StatusNotModified was returned.
  3038  func (c *ProjectsLocationsInstancesUpgradeCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3039  	gensupport.SetOptions(c.urlParams_, opts...)
  3040  	res, err := c.doRequest("json")
  3041  	if res != nil && res.StatusCode == http.StatusNotModified {
  3042  		if res.Body != nil {
  3043  			res.Body.Close()
  3044  		}
  3045  		return nil, gensupport.WrapError(&googleapi.Error{
  3046  			Code:   res.StatusCode,
  3047  			Header: res.Header,
  3048  		})
  3049  	}
  3050  	if err != nil {
  3051  		return nil, err
  3052  	}
  3053  	defer googleapi.CloseBody(res)
  3054  	if err := googleapi.CheckResponse(res); err != nil {
  3055  		return nil, gensupport.WrapError(err)
  3056  	}
  3057  	ret := &Operation{
  3058  		ServerResponse: googleapi.ServerResponse{
  3059  			Header:         res.Header,
  3060  			HTTPStatusCode: res.StatusCode,
  3061  		},
  3062  	}
  3063  	target := &ret
  3064  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3065  		return nil, err
  3066  	}
  3067  	return ret, nil
  3068  }
  3069  
  3070  type ProjectsLocationsInstancesDnsPeeringsCreateCall struct {
  3071  	s          *Service
  3072  	parent     string
  3073  	dnspeering *DnsPeering
  3074  	urlParams_ gensupport.URLParams
  3075  	ctx_       context.Context
  3076  	header_    http.Header
  3077  }
  3078  
  3079  // Create: Creates DNS peering on the given resource.
  3080  //
  3081  // - parent: The resource on which DNS peering will be created.
  3082  func (r *ProjectsLocationsInstancesDnsPeeringsService) Create(parent string, dnspeering *DnsPeering) *ProjectsLocationsInstancesDnsPeeringsCreateCall {
  3083  	c := &ProjectsLocationsInstancesDnsPeeringsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3084  	c.parent = parent
  3085  	c.dnspeering = dnspeering
  3086  	return c
  3087  }
  3088  
  3089  // DnsPeeringId sets the optional parameter "dnsPeeringId": Required. The name
  3090  // of the peering to create.
  3091  func (c *ProjectsLocationsInstancesDnsPeeringsCreateCall) DnsPeeringId(dnsPeeringId string) *ProjectsLocationsInstancesDnsPeeringsCreateCall {
  3092  	c.urlParams_.Set("dnsPeeringId", dnsPeeringId)
  3093  	return c
  3094  }
  3095  
  3096  // Fields allows partial responses to be retrieved. See
  3097  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3098  // details.
  3099  func (c *ProjectsLocationsInstancesDnsPeeringsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDnsPeeringsCreateCall {
  3100  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3101  	return c
  3102  }
  3103  
  3104  // Context sets the context to be used in this call's Do method.
  3105  func (c *ProjectsLocationsInstancesDnsPeeringsCreateCall) Context(ctx context.Context) *ProjectsLocationsInstancesDnsPeeringsCreateCall {
  3106  	c.ctx_ = ctx
  3107  	return c
  3108  }
  3109  
  3110  // Header returns a http.Header that can be modified by the caller to add
  3111  // headers to the request.
  3112  func (c *ProjectsLocationsInstancesDnsPeeringsCreateCall) Header() http.Header {
  3113  	if c.header_ == nil {
  3114  		c.header_ = make(http.Header)
  3115  	}
  3116  	return c.header_
  3117  }
  3118  
  3119  func (c *ProjectsLocationsInstancesDnsPeeringsCreateCall) doRequest(alt string) (*http.Response, error) {
  3120  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3121  	var body io.Reader = nil
  3122  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.dnspeering)
  3123  	if err != nil {
  3124  		return nil, err
  3125  	}
  3126  	c.urlParams_.Set("alt", alt)
  3127  	c.urlParams_.Set("prettyPrint", "false")
  3128  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/dnsPeerings")
  3129  	urls += "?" + c.urlParams_.Encode()
  3130  	req, err := http.NewRequest("POST", urls, body)
  3131  	if err != nil {
  3132  		return nil, err
  3133  	}
  3134  	req.Header = reqHeaders
  3135  	googleapi.Expand(req.URL, map[string]string{
  3136  		"parent": c.parent,
  3137  	})
  3138  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3139  }
  3140  
  3141  // Do executes the "datafusion.projects.locations.instances.dnsPeerings.create" call.
  3142  // Any non-2xx status code is an error. Response headers are in either
  3143  // *DnsPeering.ServerResponse.Header or (if a response was returned at all) in
  3144  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3145  // whether the returned error was because http.StatusNotModified was returned.
  3146  func (c *ProjectsLocationsInstancesDnsPeeringsCreateCall) Do(opts ...googleapi.CallOption) (*DnsPeering, error) {
  3147  	gensupport.SetOptions(c.urlParams_, opts...)
  3148  	res, err := c.doRequest("json")
  3149  	if res != nil && res.StatusCode == http.StatusNotModified {
  3150  		if res.Body != nil {
  3151  			res.Body.Close()
  3152  		}
  3153  		return nil, gensupport.WrapError(&googleapi.Error{
  3154  			Code:   res.StatusCode,
  3155  			Header: res.Header,
  3156  		})
  3157  	}
  3158  	if err != nil {
  3159  		return nil, err
  3160  	}
  3161  	defer googleapi.CloseBody(res)
  3162  	if err := googleapi.CheckResponse(res); err != nil {
  3163  		return nil, gensupport.WrapError(err)
  3164  	}
  3165  	ret := &DnsPeering{
  3166  		ServerResponse: googleapi.ServerResponse{
  3167  			Header:         res.Header,
  3168  			HTTPStatusCode: res.StatusCode,
  3169  		},
  3170  	}
  3171  	target := &ret
  3172  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3173  		return nil, err
  3174  	}
  3175  	return ret, nil
  3176  }
  3177  
  3178  type ProjectsLocationsInstancesDnsPeeringsDeleteCall struct {
  3179  	s          *Service
  3180  	name       string
  3181  	urlParams_ gensupport.URLParams
  3182  	ctx_       context.Context
  3183  	header_    http.Header
  3184  }
  3185  
  3186  // Delete: Deletes DNS peering on the given resource.
  3187  //
  3188  //   - name: The name of the DNS peering zone to delete. Format:
  3189  //     projects/{project}/locations/{location}/instances/{instance}/dnsPeerings/{d
  3190  //     ns_peering}.
  3191  func (r *ProjectsLocationsInstancesDnsPeeringsService) Delete(name string) *ProjectsLocationsInstancesDnsPeeringsDeleteCall {
  3192  	c := &ProjectsLocationsInstancesDnsPeeringsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3193  	c.name = name
  3194  	return c
  3195  }
  3196  
  3197  // Fields allows partial responses to be retrieved. See
  3198  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3199  // details.
  3200  func (c *ProjectsLocationsInstancesDnsPeeringsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDnsPeeringsDeleteCall {
  3201  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3202  	return c
  3203  }
  3204  
  3205  // Context sets the context to be used in this call's Do method.
  3206  func (c *ProjectsLocationsInstancesDnsPeeringsDeleteCall) Context(ctx context.Context) *ProjectsLocationsInstancesDnsPeeringsDeleteCall {
  3207  	c.ctx_ = ctx
  3208  	return c
  3209  }
  3210  
  3211  // Header returns a http.Header that can be modified by the caller to add
  3212  // headers to the request.
  3213  func (c *ProjectsLocationsInstancesDnsPeeringsDeleteCall) Header() http.Header {
  3214  	if c.header_ == nil {
  3215  		c.header_ = make(http.Header)
  3216  	}
  3217  	return c.header_
  3218  }
  3219  
  3220  func (c *ProjectsLocationsInstancesDnsPeeringsDeleteCall) doRequest(alt string) (*http.Response, error) {
  3221  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3222  	var body io.Reader = nil
  3223  	c.urlParams_.Set("alt", alt)
  3224  	c.urlParams_.Set("prettyPrint", "false")
  3225  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  3226  	urls += "?" + c.urlParams_.Encode()
  3227  	req, err := http.NewRequest("DELETE", urls, body)
  3228  	if err != nil {
  3229  		return nil, err
  3230  	}
  3231  	req.Header = reqHeaders
  3232  	googleapi.Expand(req.URL, map[string]string{
  3233  		"name": c.name,
  3234  	})
  3235  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3236  }
  3237  
  3238  // Do executes the "datafusion.projects.locations.instances.dnsPeerings.delete" call.
  3239  // Any non-2xx status code is an error. Response headers are in either
  3240  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  3241  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3242  // whether the returned error was because http.StatusNotModified was returned.
  3243  func (c *ProjectsLocationsInstancesDnsPeeringsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  3244  	gensupport.SetOptions(c.urlParams_, opts...)
  3245  	res, err := c.doRequest("json")
  3246  	if res != nil && res.StatusCode == http.StatusNotModified {
  3247  		if res.Body != nil {
  3248  			res.Body.Close()
  3249  		}
  3250  		return nil, gensupport.WrapError(&googleapi.Error{
  3251  			Code:   res.StatusCode,
  3252  			Header: res.Header,
  3253  		})
  3254  	}
  3255  	if err != nil {
  3256  		return nil, err
  3257  	}
  3258  	defer googleapi.CloseBody(res)
  3259  	if err := googleapi.CheckResponse(res); err != nil {
  3260  		return nil, gensupport.WrapError(err)
  3261  	}
  3262  	ret := &Empty{
  3263  		ServerResponse: googleapi.ServerResponse{
  3264  			Header:         res.Header,
  3265  			HTTPStatusCode: res.StatusCode,
  3266  		},
  3267  	}
  3268  	target := &ret
  3269  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3270  		return nil, err
  3271  	}
  3272  	return ret, nil
  3273  }
  3274  
  3275  type ProjectsLocationsInstancesDnsPeeringsListCall struct {
  3276  	s            *Service
  3277  	parent       string
  3278  	urlParams_   gensupport.URLParams
  3279  	ifNoneMatch_ string
  3280  	ctx_         context.Context
  3281  	header_      http.Header
  3282  }
  3283  
  3284  // List: Lists DNS peerings for a given resource.
  3285  //
  3286  //   - parent: The parent, which owns this collection of dns peerings. Format:
  3287  //     projects/{project}/locations/{location}/instances/{instance}.
  3288  func (r *ProjectsLocationsInstancesDnsPeeringsService) List(parent string) *ProjectsLocationsInstancesDnsPeeringsListCall {
  3289  	c := &ProjectsLocationsInstancesDnsPeeringsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3290  	c.parent = parent
  3291  	return c
  3292  }
  3293  
  3294  // PageSize sets the optional parameter "pageSize": The maximum number of dns
  3295  // peerings to return. The service may return fewer than this value. If
  3296  // unspecified, at most 50 dns peerings will be returned. The maximum value is
  3297  // 200; values above 200 will be coerced to 200.
  3298  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesDnsPeeringsListCall {
  3299  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3300  	return c
  3301  }
  3302  
  3303  // PageToken sets the optional parameter "pageToken": A page token, received
  3304  // from a previous `ListDnsPeerings` call. Provide this to retrieve the
  3305  // subsequent page. When paginating, all other parameters provided to
  3306  // `ListDnsPeerings` must match the call that provided the page token.
  3307  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) PageToken(pageToken string) *ProjectsLocationsInstancesDnsPeeringsListCall {
  3308  	c.urlParams_.Set("pageToken", pageToken)
  3309  	return c
  3310  }
  3311  
  3312  // Fields allows partial responses to be retrieved. See
  3313  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3314  // details.
  3315  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDnsPeeringsListCall {
  3316  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3317  	return c
  3318  }
  3319  
  3320  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3321  // object's ETag matches the given value. This is useful for getting updates
  3322  // only after the object has changed since the last request.
  3323  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesDnsPeeringsListCall {
  3324  	c.ifNoneMatch_ = entityTag
  3325  	return c
  3326  }
  3327  
  3328  // Context sets the context to be used in this call's Do method.
  3329  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) Context(ctx context.Context) *ProjectsLocationsInstancesDnsPeeringsListCall {
  3330  	c.ctx_ = ctx
  3331  	return c
  3332  }
  3333  
  3334  // Header returns a http.Header that can be modified by the caller to add
  3335  // headers to the request.
  3336  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) Header() http.Header {
  3337  	if c.header_ == nil {
  3338  		c.header_ = make(http.Header)
  3339  	}
  3340  	return c.header_
  3341  }
  3342  
  3343  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) doRequest(alt string) (*http.Response, error) {
  3344  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3345  	if c.ifNoneMatch_ != "" {
  3346  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3347  	}
  3348  	var body io.Reader = nil
  3349  	c.urlParams_.Set("alt", alt)
  3350  	c.urlParams_.Set("prettyPrint", "false")
  3351  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/dnsPeerings")
  3352  	urls += "?" + c.urlParams_.Encode()
  3353  	req, err := http.NewRequest("GET", urls, body)
  3354  	if err != nil {
  3355  		return nil, err
  3356  	}
  3357  	req.Header = reqHeaders
  3358  	googleapi.Expand(req.URL, map[string]string{
  3359  		"parent": c.parent,
  3360  	})
  3361  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3362  }
  3363  
  3364  // Do executes the "datafusion.projects.locations.instances.dnsPeerings.list" call.
  3365  // Any non-2xx status code is an error. Response headers are in either
  3366  // *ListDnsPeeringsResponse.ServerResponse.Header or (if a response was
  3367  // returned at all) in error.(*googleapi.Error).Header. Use
  3368  // googleapi.IsNotModified to check whether the returned error was because
  3369  // http.StatusNotModified was returned.
  3370  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) Do(opts ...googleapi.CallOption) (*ListDnsPeeringsResponse, error) {
  3371  	gensupport.SetOptions(c.urlParams_, opts...)
  3372  	res, err := c.doRequest("json")
  3373  	if res != nil && res.StatusCode == http.StatusNotModified {
  3374  		if res.Body != nil {
  3375  			res.Body.Close()
  3376  		}
  3377  		return nil, gensupport.WrapError(&googleapi.Error{
  3378  			Code:   res.StatusCode,
  3379  			Header: res.Header,
  3380  		})
  3381  	}
  3382  	if err != nil {
  3383  		return nil, err
  3384  	}
  3385  	defer googleapi.CloseBody(res)
  3386  	if err := googleapi.CheckResponse(res); err != nil {
  3387  		return nil, gensupport.WrapError(err)
  3388  	}
  3389  	ret := &ListDnsPeeringsResponse{
  3390  		ServerResponse: googleapi.ServerResponse{
  3391  			Header:         res.Header,
  3392  			HTTPStatusCode: res.StatusCode,
  3393  		},
  3394  	}
  3395  	target := &ret
  3396  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3397  		return nil, err
  3398  	}
  3399  	return ret, nil
  3400  }
  3401  
  3402  // Pages invokes f for each page of results.
  3403  // A non-nil error returned from f will halt the iteration.
  3404  // The provided context supersedes any context provided to the Context method.
  3405  func (c *ProjectsLocationsInstancesDnsPeeringsListCall) Pages(ctx context.Context, f func(*ListDnsPeeringsResponse) error) error {
  3406  	c.ctx_ = ctx
  3407  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3408  	for {
  3409  		x, err := c.Do()
  3410  		if err != nil {
  3411  			return err
  3412  		}
  3413  		if err := f(x); err != nil {
  3414  			return err
  3415  		}
  3416  		if x.NextPageToken == "" {
  3417  			return nil
  3418  		}
  3419  		c.PageToken(x.NextPageToken)
  3420  	}
  3421  }
  3422  
  3423  type ProjectsLocationsInstancesNamespacesGetIamPolicyCall struct {
  3424  	s            *Service
  3425  	resource     string
  3426  	urlParams_   gensupport.URLParams
  3427  	ifNoneMatch_ string
  3428  	ctx_         context.Context
  3429  	header_      http.Header
  3430  }
  3431  
  3432  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  3433  // empty policy if the resource exists and does not have a policy set.
  3434  //
  3435  //   - resource: REQUIRED: The resource for which the policy is being requested.
  3436  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3437  //     for the appropriate value for this field.
  3438  func (r *ProjectsLocationsInstancesNamespacesService) GetIamPolicy(resource string) *ProjectsLocationsInstancesNamespacesGetIamPolicyCall {
  3439  	c := &ProjectsLocationsInstancesNamespacesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3440  	c.resource = resource
  3441  	return c
  3442  }
  3443  
  3444  // OptionsRequestedPolicyVersion sets the optional parameter
  3445  // "options.requestedPolicyVersion": The maximum policy version that will be
  3446  // used to format the policy. Valid values are 0, 1, and 3. Requests specifying
  3447  // an invalid value will be rejected. Requests for policies with any
  3448  // conditional role bindings must specify version 3. Policies with no
  3449  // conditional role bindings may specify any valid value or leave the field
  3450  // unset. The policy in the response might use the policy version that you
  3451  // specified, or it might use a lower policy version. For example, if you
  3452  // specify version 3, but the policy has no conditional role bindings, the
  3453  // response uses version 1. To learn which resources support conditions in
  3454  // their IAM policies, see the IAM documentation
  3455  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  3456  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsInstancesNamespacesGetIamPolicyCall {
  3457  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  3458  	return c
  3459  }
  3460  
  3461  // Fields allows partial responses to be retrieved. See
  3462  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3463  // details.
  3464  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesNamespacesGetIamPolicyCall {
  3465  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3466  	return c
  3467  }
  3468  
  3469  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3470  // object's ETag matches the given value. This is useful for getting updates
  3471  // only after the object has changed since the last request.
  3472  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesNamespacesGetIamPolicyCall {
  3473  	c.ifNoneMatch_ = entityTag
  3474  	return c
  3475  }
  3476  
  3477  // Context sets the context to be used in this call's Do method.
  3478  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesNamespacesGetIamPolicyCall {
  3479  	c.ctx_ = ctx
  3480  	return c
  3481  }
  3482  
  3483  // Header returns a http.Header that can be modified by the caller to add
  3484  // headers to the request.
  3485  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) Header() http.Header {
  3486  	if c.header_ == nil {
  3487  		c.header_ = make(http.Header)
  3488  	}
  3489  	return c.header_
  3490  }
  3491  
  3492  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3493  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3494  	if c.ifNoneMatch_ != "" {
  3495  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3496  	}
  3497  	var body io.Reader = nil
  3498  	c.urlParams_.Set("alt", alt)
  3499  	c.urlParams_.Set("prettyPrint", "false")
  3500  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:getIamPolicy")
  3501  	urls += "?" + c.urlParams_.Encode()
  3502  	req, err := http.NewRequest("GET", urls, body)
  3503  	if err != nil {
  3504  		return nil, err
  3505  	}
  3506  	req.Header = reqHeaders
  3507  	googleapi.Expand(req.URL, map[string]string{
  3508  		"resource": c.resource,
  3509  	})
  3510  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3511  }
  3512  
  3513  // Do executes the "datafusion.projects.locations.instances.namespaces.getIamPolicy" call.
  3514  // Any non-2xx status code is an error. Response headers are in either
  3515  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3516  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3517  // whether the returned error was because http.StatusNotModified was returned.
  3518  func (c *ProjectsLocationsInstancesNamespacesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3519  	gensupport.SetOptions(c.urlParams_, opts...)
  3520  	res, err := c.doRequest("json")
  3521  	if res != nil && res.StatusCode == http.StatusNotModified {
  3522  		if res.Body != nil {
  3523  			res.Body.Close()
  3524  		}
  3525  		return nil, gensupport.WrapError(&googleapi.Error{
  3526  			Code:   res.StatusCode,
  3527  			Header: res.Header,
  3528  		})
  3529  	}
  3530  	if err != nil {
  3531  		return nil, err
  3532  	}
  3533  	defer googleapi.CloseBody(res)
  3534  	if err := googleapi.CheckResponse(res); err != nil {
  3535  		return nil, gensupport.WrapError(err)
  3536  	}
  3537  	ret := &Policy{
  3538  		ServerResponse: googleapi.ServerResponse{
  3539  			Header:         res.Header,
  3540  			HTTPStatusCode: res.StatusCode,
  3541  		},
  3542  	}
  3543  	target := &ret
  3544  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3545  		return nil, err
  3546  	}
  3547  	return ret, nil
  3548  }
  3549  
  3550  type ProjectsLocationsInstancesNamespacesListCall struct {
  3551  	s            *Service
  3552  	parent       string
  3553  	urlParams_   gensupport.URLParams
  3554  	ifNoneMatch_ string
  3555  	ctx_         context.Context
  3556  	header_      http.Header
  3557  }
  3558  
  3559  // List: List namespaces in a given instance
  3560  //
  3561  // - parent: The instance to list its namespaces.
  3562  func (r *ProjectsLocationsInstancesNamespacesService) List(parent string) *ProjectsLocationsInstancesNamespacesListCall {
  3563  	c := &ProjectsLocationsInstancesNamespacesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3564  	c.parent = parent
  3565  	return c
  3566  }
  3567  
  3568  // PageSize sets the optional parameter "pageSize": The maximum number of items
  3569  // to return.
  3570  func (c *ProjectsLocationsInstancesNamespacesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesNamespacesListCall {
  3571  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3572  	return c
  3573  }
  3574  
  3575  // PageToken sets the optional parameter "pageToken": The next_page_token value
  3576  // to use if there are additional results to retrieve for this list request.
  3577  func (c *ProjectsLocationsInstancesNamespacesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesNamespacesListCall {
  3578  	c.urlParams_.Set("pageToken", pageToken)
  3579  	return c
  3580  }
  3581  
  3582  // View sets the optional parameter "view": By default, only basic information
  3583  // about a namespace is returned (e.g. name). When `NAMESPACE_VIEW_FULL` is
  3584  // specified, additional information associated with a namespace gets returned
  3585  // (e.g. IAM policy set on the namespace)
  3586  //
  3587  // Possible values:
  3588  //
  3589  //	"NAMESPACE_VIEW_UNSPECIFIED" - Default/unset value, which will use BASIC
  3590  //
  3591  // view.
  3592  //
  3593  //	"NAMESPACE_VIEW_BASIC" - Show the most basic metadata of a namespace
  3594  //	"NAMESPACE_VIEW_FULL" - Returns all metadata of a namespace
  3595  func (c *ProjectsLocationsInstancesNamespacesListCall) View(view string) *ProjectsLocationsInstancesNamespacesListCall {
  3596  	c.urlParams_.Set("view", view)
  3597  	return c
  3598  }
  3599  
  3600  // Fields allows partial responses to be retrieved. See
  3601  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3602  // details.
  3603  func (c *ProjectsLocationsInstancesNamespacesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesNamespacesListCall {
  3604  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3605  	return c
  3606  }
  3607  
  3608  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3609  // object's ETag matches the given value. This is useful for getting updates
  3610  // only after the object has changed since the last request.
  3611  func (c *ProjectsLocationsInstancesNamespacesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesNamespacesListCall {
  3612  	c.ifNoneMatch_ = entityTag
  3613  	return c
  3614  }
  3615  
  3616  // Context sets the context to be used in this call's Do method.
  3617  func (c *ProjectsLocationsInstancesNamespacesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesNamespacesListCall {
  3618  	c.ctx_ = ctx
  3619  	return c
  3620  }
  3621  
  3622  // Header returns a http.Header that can be modified by the caller to add
  3623  // headers to the request.
  3624  func (c *ProjectsLocationsInstancesNamespacesListCall) Header() http.Header {
  3625  	if c.header_ == nil {
  3626  		c.header_ = make(http.Header)
  3627  	}
  3628  	return c.header_
  3629  }
  3630  
  3631  func (c *ProjectsLocationsInstancesNamespacesListCall) doRequest(alt string) (*http.Response, error) {
  3632  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3633  	if c.ifNoneMatch_ != "" {
  3634  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3635  	}
  3636  	var body io.Reader = nil
  3637  	c.urlParams_.Set("alt", alt)
  3638  	c.urlParams_.Set("prettyPrint", "false")
  3639  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/namespaces")
  3640  	urls += "?" + c.urlParams_.Encode()
  3641  	req, err := http.NewRequest("GET", urls, body)
  3642  	if err != nil {
  3643  		return nil, err
  3644  	}
  3645  	req.Header = reqHeaders
  3646  	googleapi.Expand(req.URL, map[string]string{
  3647  		"parent": c.parent,
  3648  	})
  3649  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3650  }
  3651  
  3652  // Do executes the "datafusion.projects.locations.instances.namespaces.list" call.
  3653  // Any non-2xx status code is an error. Response headers are in either
  3654  // *ListNamespacesResponse.ServerResponse.Header or (if a response was returned
  3655  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3656  // check whether the returned error was because http.StatusNotModified was
  3657  // returned.
  3658  func (c *ProjectsLocationsInstancesNamespacesListCall) Do(opts ...googleapi.CallOption) (*ListNamespacesResponse, error) {
  3659  	gensupport.SetOptions(c.urlParams_, opts...)
  3660  	res, err := c.doRequest("json")
  3661  	if res != nil && res.StatusCode == http.StatusNotModified {
  3662  		if res.Body != nil {
  3663  			res.Body.Close()
  3664  		}
  3665  		return nil, gensupport.WrapError(&googleapi.Error{
  3666  			Code:   res.StatusCode,
  3667  			Header: res.Header,
  3668  		})
  3669  	}
  3670  	if err != nil {
  3671  		return nil, err
  3672  	}
  3673  	defer googleapi.CloseBody(res)
  3674  	if err := googleapi.CheckResponse(res); err != nil {
  3675  		return nil, gensupport.WrapError(err)
  3676  	}
  3677  	ret := &ListNamespacesResponse{
  3678  		ServerResponse: googleapi.ServerResponse{
  3679  			Header:         res.Header,
  3680  			HTTPStatusCode: res.StatusCode,
  3681  		},
  3682  	}
  3683  	target := &ret
  3684  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3685  		return nil, err
  3686  	}
  3687  	return ret, nil
  3688  }
  3689  
  3690  // Pages invokes f for each page of results.
  3691  // A non-nil error returned from f will halt the iteration.
  3692  // The provided context supersedes any context provided to the Context method.
  3693  func (c *ProjectsLocationsInstancesNamespacesListCall) Pages(ctx context.Context, f func(*ListNamespacesResponse) error) error {
  3694  	c.ctx_ = ctx
  3695  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3696  	for {
  3697  		x, err := c.Do()
  3698  		if err != nil {
  3699  			return err
  3700  		}
  3701  		if err := f(x); err != nil {
  3702  			return err
  3703  		}
  3704  		if x.NextPageToken == "" {
  3705  			return nil
  3706  		}
  3707  		c.PageToken(x.NextPageToken)
  3708  	}
  3709  }
  3710  
  3711  type ProjectsLocationsInstancesNamespacesSetIamPolicyCall struct {
  3712  	s                   *Service
  3713  	resource            string
  3714  	setiampolicyrequest *SetIamPolicyRequest
  3715  	urlParams_          gensupport.URLParams
  3716  	ctx_                context.Context
  3717  	header_             http.Header
  3718  }
  3719  
  3720  // SetIamPolicy: Sets the access control policy on the specified resource.
  3721  // Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`,
  3722  // and `PERMISSION_DENIED` errors.
  3723  //
  3724  //   - resource: REQUIRED: The resource for which the policy is being specified.
  3725  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3726  //     for the appropriate value for this field.
  3727  func (r *ProjectsLocationsInstancesNamespacesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsInstancesNamespacesSetIamPolicyCall {
  3728  	c := &ProjectsLocationsInstancesNamespacesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3729  	c.resource = resource
  3730  	c.setiampolicyrequest = setiampolicyrequest
  3731  	return c
  3732  }
  3733  
  3734  // Fields allows partial responses to be retrieved. See
  3735  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3736  // details.
  3737  func (c *ProjectsLocationsInstancesNamespacesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesNamespacesSetIamPolicyCall {
  3738  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3739  	return c
  3740  }
  3741  
  3742  // Context sets the context to be used in this call's Do method.
  3743  func (c *ProjectsLocationsInstancesNamespacesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsInstancesNamespacesSetIamPolicyCall {
  3744  	c.ctx_ = ctx
  3745  	return c
  3746  }
  3747  
  3748  // Header returns a http.Header that can be modified by the caller to add
  3749  // headers to the request.
  3750  func (c *ProjectsLocationsInstancesNamespacesSetIamPolicyCall) Header() http.Header {
  3751  	if c.header_ == nil {
  3752  		c.header_ = make(http.Header)
  3753  	}
  3754  	return c.header_
  3755  }
  3756  
  3757  func (c *ProjectsLocationsInstancesNamespacesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3758  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3759  	var body io.Reader = nil
  3760  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  3761  	if err != nil {
  3762  		return nil, err
  3763  	}
  3764  	c.urlParams_.Set("alt", alt)
  3765  	c.urlParams_.Set("prettyPrint", "false")
  3766  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:setIamPolicy")
  3767  	urls += "?" + c.urlParams_.Encode()
  3768  	req, err := http.NewRequest("POST", urls, body)
  3769  	if err != nil {
  3770  		return nil, err
  3771  	}
  3772  	req.Header = reqHeaders
  3773  	googleapi.Expand(req.URL, map[string]string{
  3774  		"resource": c.resource,
  3775  	})
  3776  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3777  }
  3778  
  3779  // Do executes the "datafusion.projects.locations.instances.namespaces.setIamPolicy" call.
  3780  // Any non-2xx status code is an error. Response headers are in either
  3781  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3782  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3783  // whether the returned error was because http.StatusNotModified was returned.
  3784  func (c *ProjectsLocationsInstancesNamespacesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3785  	gensupport.SetOptions(c.urlParams_, opts...)
  3786  	res, err := c.doRequest("json")
  3787  	if res != nil && res.StatusCode == http.StatusNotModified {
  3788  		if res.Body != nil {
  3789  			res.Body.Close()
  3790  		}
  3791  		return nil, gensupport.WrapError(&googleapi.Error{
  3792  			Code:   res.StatusCode,
  3793  			Header: res.Header,
  3794  		})
  3795  	}
  3796  	if err != nil {
  3797  		return nil, err
  3798  	}
  3799  	defer googleapi.CloseBody(res)
  3800  	if err := googleapi.CheckResponse(res); err != nil {
  3801  		return nil, gensupport.WrapError(err)
  3802  	}
  3803  	ret := &Policy{
  3804  		ServerResponse: googleapi.ServerResponse{
  3805  			Header:         res.Header,
  3806  			HTTPStatusCode: res.StatusCode,
  3807  		},
  3808  	}
  3809  	target := &ret
  3810  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3811  		return nil, err
  3812  	}
  3813  	return ret, nil
  3814  }
  3815  
  3816  type ProjectsLocationsInstancesNamespacesTestIamPermissionsCall struct {
  3817  	s                         *Service
  3818  	resource                  string
  3819  	testiampermissionsrequest *TestIamPermissionsRequest
  3820  	urlParams_                gensupport.URLParams
  3821  	ctx_                      context.Context
  3822  	header_                   http.Header
  3823  }
  3824  
  3825  // TestIamPermissions: Returns permissions that a caller has on the specified
  3826  // resource. If the resource does not exist, this will return an empty set of
  3827  // permissions, not a `NOT_FOUND` error. Note: This operation is designed to be
  3828  // used for building permission-aware UIs and command-line tools, not for
  3829  // authorization checking. This operation may "fail open" without warning.
  3830  //
  3831  //   - resource: REQUIRED: The resource for which the policy detail is being
  3832  //     requested. See Resource names
  3833  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  3834  //     value for this field.
  3835  func (r *ProjectsLocationsInstancesNamespacesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall {
  3836  	c := &ProjectsLocationsInstancesNamespacesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3837  	c.resource = resource
  3838  	c.testiampermissionsrequest = testiampermissionsrequest
  3839  	return c
  3840  }
  3841  
  3842  // Fields allows partial responses to be retrieved. See
  3843  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3844  // details.
  3845  func (c *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall {
  3846  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3847  	return c
  3848  }
  3849  
  3850  // Context sets the context to be used in this call's Do method.
  3851  func (c *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall {
  3852  	c.ctx_ = ctx
  3853  	return c
  3854  }
  3855  
  3856  // Header returns a http.Header that can be modified by the caller to add
  3857  // headers to the request.
  3858  func (c *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall) Header() http.Header {
  3859  	if c.header_ == nil {
  3860  		c.header_ = make(http.Header)
  3861  	}
  3862  	return c.header_
  3863  }
  3864  
  3865  func (c *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  3866  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3867  	var body io.Reader = nil
  3868  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  3869  	if err != nil {
  3870  		return nil, err
  3871  	}
  3872  	c.urlParams_.Set("alt", alt)
  3873  	c.urlParams_.Set("prettyPrint", "false")
  3874  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:testIamPermissions")
  3875  	urls += "?" + c.urlParams_.Encode()
  3876  	req, err := http.NewRequest("POST", urls, body)
  3877  	if err != nil {
  3878  		return nil, err
  3879  	}
  3880  	req.Header = reqHeaders
  3881  	googleapi.Expand(req.URL, map[string]string{
  3882  		"resource": c.resource,
  3883  	})
  3884  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3885  }
  3886  
  3887  // Do executes the "datafusion.projects.locations.instances.namespaces.testIamPermissions" call.
  3888  // Any non-2xx status code is an error. Response headers are in either
  3889  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  3890  // returned at all) in error.(*googleapi.Error).Header. Use
  3891  // googleapi.IsNotModified to check whether the returned error was because
  3892  // http.StatusNotModified was returned.
  3893  func (c *ProjectsLocationsInstancesNamespacesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  3894  	gensupport.SetOptions(c.urlParams_, opts...)
  3895  	res, err := c.doRequest("json")
  3896  	if res != nil && res.StatusCode == http.StatusNotModified {
  3897  		if res.Body != nil {
  3898  			res.Body.Close()
  3899  		}
  3900  		return nil, gensupport.WrapError(&googleapi.Error{
  3901  			Code:   res.StatusCode,
  3902  			Header: res.Header,
  3903  		})
  3904  	}
  3905  	if err != nil {
  3906  		return nil, err
  3907  	}
  3908  	defer googleapi.CloseBody(res)
  3909  	if err := googleapi.CheckResponse(res); err != nil {
  3910  		return nil, gensupport.WrapError(err)
  3911  	}
  3912  	ret := &TestIamPermissionsResponse{
  3913  		ServerResponse: googleapi.ServerResponse{
  3914  			Header:         res.Header,
  3915  			HTTPStatusCode: res.StatusCode,
  3916  		},
  3917  	}
  3918  	target := &ret
  3919  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3920  		return nil, err
  3921  	}
  3922  	return ret, nil
  3923  }
  3924  
  3925  type ProjectsLocationsOperationsCancelCall struct {
  3926  	s                      *Service
  3927  	name                   string
  3928  	canceloperationrequest *CancelOperationRequest
  3929  	urlParams_             gensupport.URLParams
  3930  	ctx_                   context.Context
  3931  	header_                http.Header
  3932  }
  3933  
  3934  // Cancel: Starts asynchronous cancellation on a long-running operation. The
  3935  // server makes a best effort to cancel the operation, but success is not
  3936  // guaranteed. If the server doesn't support this method, it returns
  3937  // `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or
  3938  // other methods to check whether the cancellation succeeded or whether the
  3939  // operation completed despite cancellation. On successful cancellation, the
  3940  // operation is not deleted; instead, it becomes an operation with an
  3941  // Operation.error value with a google.rpc.Status.code of 1, corresponding to
  3942  // `Code.CANCELLED`.
  3943  //
  3944  // - name: The name of the operation resource to be cancelled.
  3945  func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall {
  3946  	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3947  	c.name = name
  3948  	c.canceloperationrequest = canceloperationrequest
  3949  	return c
  3950  }
  3951  
  3952  // Fields allows partial responses to be retrieved. See
  3953  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3954  // details.
  3955  func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
  3956  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3957  	return c
  3958  }
  3959  
  3960  // Context sets the context to be used in this call's Do method.
  3961  func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
  3962  	c.ctx_ = ctx
  3963  	return c
  3964  }
  3965  
  3966  // Header returns a http.Header that can be modified by the caller to add
  3967  // headers to the request.
  3968  func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
  3969  	if c.header_ == nil {
  3970  		c.header_ = make(http.Header)
  3971  	}
  3972  	return c.header_
  3973  }
  3974  
  3975  func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
  3976  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3977  	var body io.Reader = nil
  3978  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest)
  3979  	if err != nil {
  3980  		return nil, err
  3981  	}
  3982  	c.urlParams_.Set("alt", alt)
  3983  	c.urlParams_.Set("prettyPrint", "false")
  3984  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:cancel")
  3985  	urls += "?" + c.urlParams_.Encode()
  3986  	req, err := http.NewRequest("POST", urls, body)
  3987  	if err != nil {
  3988  		return nil, err
  3989  	}
  3990  	req.Header = reqHeaders
  3991  	googleapi.Expand(req.URL, map[string]string{
  3992  		"name": c.name,
  3993  	})
  3994  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3995  }
  3996  
  3997  // Do executes the "datafusion.projects.locations.operations.cancel" call.
  3998  // Any non-2xx status code is an error. Response headers are in either
  3999  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  4000  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4001  // whether the returned error was because http.StatusNotModified was returned.
  4002  func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  4003  	gensupport.SetOptions(c.urlParams_, opts...)
  4004  	res, err := c.doRequest("json")
  4005  	if res != nil && res.StatusCode == http.StatusNotModified {
  4006  		if res.Body != nil {
  4007  			res.Body.Close()
  4008  		}
  4009  		return nil, gensupport.WrapError(&googleapi.Error{
  4010  			Code:   res.StatusCode,
  4011  			Header: res.Header,
  4012  		})
  4013  	}
  4014  	if err != nil {
  4015  		return nil, err
  4016  	}
  4017  	defer googleapi.CloseBody(res)
  4018  	if err := googleapi.CheckResponse(res); err != nil {
  4019  		return nil, gensupport.WrapError(err)
  4020  	}
  4021  	ret := &Empty{
  4022  		ServerResponse: googleapi.ServerResponse{
  4023  			Header:         res.Header,
  4024  			HTTPStatusCode: res.StatusCode,
  4025  		},
  4026  	}
  4027  	target := &ret
  4028  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4029  		return nil, err
  4030  	}
  4031  	return ret, nil
  4032  }
  4033  
  4034  type ProjectsLocationsOperationsDeleteCall struct {
  4035  	s          *Service
  4036  	name       string
  4037  	urlParams_ gensupport.URLParams
  4038  	ctx_       context.Context
  4039  	header_    http.Header
  4040  }
  4041  
  4042  // Delete: Deletes a long-running operation. This method indicates that the
  4043  // client is no longer interested in the operation result. It does not cancel
  4044  // the operation. If the server doesn't support this method, it returns
  4045  // `google.rpc.Code.UNIMPLEMENTED`.
  4046  //
  4047  // - name: The name of the operation resource to be deleted.
  4048  func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall {
  4049  	c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4050  	c.name = name
  4051  	return c
  4052  }
  4053  
  4054  // Fields allows partial responses to be retrieved. See
  4055  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4056  // details.
  4057  func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall {
  4058  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4059  	return c
  4060  }
  4061  
  4062  // Context sets the context to be used in this call's Do method.
  4063  func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall {
  4064  	c.ctx_ = ctx
  4065  	return c
  4066  }
  4067  
  4068  // Header returns a http.Header that can be modified by the caller to add
  4069  // headers to the request.
  4070  func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header {
  4071  	if c.header_ == nil {
  4072  		c.header_ = make(http.Header)
  4073  	}
  4074  	return c.header_
  4075  }
  4076  
  4077  func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) {
  4078  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4079  	var body io.Reader = nil
  4080  	c.urlParams_.Set("alt", alt)
  4081  	c.urlParams_.Set("prettyPrint", "false")
  4082  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  4083  	urls += "?" + c.urlParams_.Encode()
  4084  	req, err := http.NewRequest("DELETE", urls, body)
  4085  	if err != nil {
  4086  		return nil, err
  4087  	}
  4088  	req.Header = reqHeaders
  4089  	googleapi.Expand(req.URL, map[string]string{
  4090  		"name": c.name,
  4091  	})
  4092  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4093  }
  4094  
  4095  // Do executes the "datafusion.projects.locations.operations.delete" call.
  4096  // Any non-2xx status code is an error. Response headers are in either
  4097  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  4098  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4099  // whether the returned error was because http.StatusNotModified was returned.
  4100  func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  4101  	gensupport.SetOptions(c.urlParams_, opts...)
  4102  	res, err := c.doRequest("json")
  4103  	if res != nil && res.StatusCode == http.StatusNotModified {
  4104  		if res.Body != nil {
  4105  			res.Body.Close()
  4106  		}
  4107  		return nil, gensupport.WrapError(&googleapi.Error{
  4108  			Code:   res.StatusCode,
  4109  			Header: res.Header,
  4110  		})
  4111  	}
  4112  	if err != nil {
  4113  		return nil, err
  4114  	}
  4115  	defer googleapi.CloseBody(res)
  4116  	if err := googleapi.CheckResponse(res); err != nil {
  4117  		return nil, gensupport.WrapError(err)
  4118  	}
  4119  	ret := &Empty{
  4120  		ServerResponse: googleapi.ServerResponse{
  4121  			Header:         res.Header,
  4122  			HTTPStatusCode: res.StatusCode,
  4123  		},
  4124  	}
  4125  	target := &ret
  4126  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4127  		return nil, err
  4128  	}
  4129  	return ret, nil
  4130  }
  4131  
  4132  type ProjectsLocationsOperationsGetCall struct {
  4133  	s            *Service
  4134  	name         string
  4135  	urlParams_   gensupport.URLParams
  4136  	ifNoneMatch_ string
  4137  	ctx_         context.Context
  4138  	header_      http.Header
  4139  }
  4140  
  4141  // Get: Gets the latest state of a long-running operation. Clients can use this
  4142  // method to poll the operation result at intervals as recommended by the API
  4143  // service.
  4144  //
  4145  // - name: The name of the operation resource.
  4146  func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
  4147  	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4148  	c.name = name
  4149  	return c
  4150  }
  4151  
  4152  // Fields allows partial responses to be retrieved. See
  4153  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4154  // details.
  4155  func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
  4156  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4157  	return c
  4158  }
  4159  
  4160  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4161  // object's ETag matches the given value. This is useful for getting updates
  4162  // only after the object has changed since the last request.
  4163  func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
  4164  	c.ifNoneMatch_ = entityTag
  4165  	return c
  4166  }
  4167  
  4168  // Context sets the context to be used in this call's Do method.
  4169  func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
  4170  	c.ctx_ = ctx
  4171  	return c
  4172  }
  4173  
  4174  // Header returns a http.Header that can be modified by the caller to add
  4175  // headers to the request.
  4176  func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
  4177  	if c.header_ == nil {
  4178  		c.header_ = make(http.Header)
  4179  	}
  4180  	return c.header_
  4181  }
  4182  
  4183  func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
  4184  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4185  	if c.ifNoneMatch_ != "" {
  4186  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4187  	}
  4188  	var body io.Reader = nil
  4189  	c.urlParams_.Set("alt", alt)
  4190  	c.urlParams_.Set("prettyPrint", "false")
  4191  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
  4192  	urls += "?" + c.urlParams_.Encode()
  4193  	req, err := http.NewRequest("GET", urls, body)
  4194  	if err != nil {
  4195  		return nil, err
  4196  	}
  4197  	req.Header = reqHeaders
  4198  	googleapi.Expand(req.URL, map[string]string{
  4199  		"name": c.name,
  4200  	})
  4201  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4202  }
  4203  
  4204  // Do executes the "datafusion.projects.locations.operations.get" call.
  4205  // Any non-2xx status code is an error. Response headers are in either
  4206  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4207  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4208  // whether the returned error was because http.StatusNotModified was returned.
  4209  func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4210  	gensupport.SetOptions(c.urlParams_, opts...)
  4211  	res, err := c.doRequest("json")
  4212  	if res != nil && res.StatusCode == http.StatusNotModified {
  4213  		if res.Body != nil {
  4214  			res.Body.Close()
  4215  		}
  4216  		return nil, gensupport.WrapError(&googleapi.Error{
  4217  			Code:   res.StatusCode,
  4218  			Header: res.Header,
  4219  		})
  4220  	}
  4221  	if err != nil {
  4222  		return nil, err
  4223  	}
  4224  	defer googleapi.CloseBody(res)
  4225  	if err := googleapi.CheckResponse(res); err != nil {
  4226  		return nil, gensupport.WrapError(err)
  4227  	}
  4228  	ret := &Operation{
  4229  		ServerResponse: googleapi.ServerResponse{
  4230  			Header:         res.Header,
  4231  			HTTPStatusCode: res.StatusCode,
  4232  		},
  4233  	}
  4234  	target := &ret
  4235  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4236  		return nil, err
  4237  	}
  4238  	return ret, nil
  4239  }
  4240  
  4241  type ProjectsLocationsOperationsListCall struct {
  4242  	s            *Service
  4243  	name         string
  4244  	urlParams_   gensupport.URLParams
  4245  	ifNoneMatch_ string
  4246  	ctx_         context.Context
  4247  	header_      http.Header
  4248  }
  4249  
  4250  // List: Lists operations that match the specified filter in the request. If
  4251  // the server doesn't support this method, it returns `UNIMPLEMENTED`.
  4252  //
  4253  // - name: The name of the operation's parent resource.
  4254  func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
  4255  	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4256  	c.name = name
  4257  	return c
  4258  }
  4259  
  4260  // Filter sets the optional parameter "filter": The standard list filter.
  4261  func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
  4262  	c.urlParams_.Set("filter", filter)
  4263  	return c
  4264  }
  4265  
  4266  // PageSize sets the optional parameter "pageSize": The standard list page
  4267  // size.
  4268  func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
  4269  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4270  	return c
  4271  }
  4272  
  4273  // PageToken sets the optional parameter "pageToken": The standard list page
  4274  // token.
  4275  func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
  4276  	c.urlParams_.Set("pageToken", pageToken)
  4277  	return c
  4278  }
  4279  
  4280  // Fields allows partial responses to be retrieved. See
  4281  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4282  // details.
  4283  func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
  4284  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4285  	return c
  4286  }
  4287  
  4288  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4289  // object's ETag matches the given value. This is useful for getting updates
  4290  // only after the object has changed since the last request.
  4291  func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
  4292  	c.ifNoneMatch_ = entityTag
  4293  	return c
  4294  }
  4295  
  4296  // Context sets the context to be used in this call's Do method.
  4297  func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
  4298  	c.ctx_ = ctx
  4299  	return c
  4300  }
  4301  
  4302  // Header returns a http.Header that can be modified by the caller to add
  4303  // headers to the request.
  4304  func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
  4305  	if c.header_ == nil {
  4306  		c.header_ = make(http.Header)
  4307  	}
  4308  	return c.header_
  4309  }
  4310  
  4311  func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
  4312  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4313  	if c.ifNoneMatch_ != "" {
  4314  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4315  	}
  4316  	var body io.Reader = nil
  4317  	c.urlParams_.Set("alt", alt)
  4318  	c.urlParams_.Set("prettyPrint", "false")
  4319  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/operations")
  4320  	urls += "?" + c.urlParams_.Encode()
  4321  	req, err := http.NewRequest("GET", urls, body)
  4322  	if err != nil {
  4323  		return nil, err
  4324  	}
  4325  	req.Header = reqHeaders
  4326  	googleapi.Expand(req.URL, map[string]string{
  4327  		"name": c.name,
  4328  	})
  4329  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4330  }
  4331  
  4332  // Do executes the "datafusion.projects.locations.operations.list" call.
  4333  // Any non-2xx status code is an error. Response headers are in either
  4334  // *ListOperationsResponse.ServerResponse.Header or (if a response was returned
  4335  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  4336  // check whether the returned error was because http.StatusNotModified was
  4337  // returned.
  4338  func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
  4339  	gensupport.SetOptions(c.urlParams_, opts...)
  4340  	res, err := c.doRequest("json")
  4341  	if res != nil && res.StatusCode == http.StatusNotModified {
  4342  		if res.Body != nil {
  4343  			res.Body.Close()
  4344  		}
  4345  		return nil, gensupport.WrapError(&googleapi.Error{
  4346  			Code:   res.StatusCode,
  4347  			Header: res.Header,
  4348  		})
  4349  	}
  4350  	if err != nil {
  4351  		return nil, err
  4352  	}
  4353  	defer googleapi.CloseBody(res)
  4354  	if err := googleapi.CheckResponse(res); err != nil {
  4355  		return nil, gensupport.WrapError(err)
  4356  	}
  4357  	ret := &ListOperationsResponse{
  4358  		ServerResponse: googleapi.ServerResponse{
  4359  			Header:         res.Header,
  4360  			HTTPStatusCode: res.StatusCode,
  4361  		},
  4362  	}
  4363  	target := &ret
  4364  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4365  		return nil, err
  4366  	}
  4367  	return ret, nil
  4368  }
  4369  
  4370  // Pages invokes f for each page of results.
  4371  // A non-nil error returned from f will halt the iteration.
  4372  // The provided context supersedes any context provided to the Context method.
  4373  func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
  4374  	c.ctx_ = ctx
  4375  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4376  	for {
  4377  		x, err := c.Do()
  4378  		if err != nil {
  4379  			return err
  4380  		}
  4381  		if err := f(x); err != nil {
  4382  			return err
  4383  		}
  4384  		if x.NextPageToken == "" {
  4385  			return nil
  4386  		}
  4387  		c.PageToken(x.NextPageToken)
  4388  	}
  4389  }
  4390  
  4391  type ProjectsLocationsVersionsListCall struct {
  4392  	s            *Service
  4393  	parent       string
  4394  	urlParams_   gensupport.URLParams
  4395  	ifNoneMatch_ string
  4396  	ctx_         context.Context
  4397  	header_      http.Header
  4398  }
  4399  
  4400  // List: Lists possible versions for Data Fusion instances in the specified
  4401  // project and location.
  4402  //
  4403  //   - parent: The project and location for which to retrieve instance
  4404  //     information in the format projects/{project}/locations/{location}.
  4405  func (r *ProjectsLocationsVersionsService) List(parent string) *ProjectsLocationsVersionsListCall {
  4406  	c := &ProjectsLocationsVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4407  	c.parent = parent
  4408  	return c
  4409  }
  4410  
  4411  // LatestPatchOnly sets the optional parameter "latestPatchOnly": Whether or
  4412  // not to return the latest patch of every available minor version. If true,
  4413  // only the latest patch will be returned. Ex. if allowed versions is [6.1.1,
  4414  // 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0]
  4415  func (c *ProjectsLocationsVersionsListCall) LatestPatchOnly(latestPatchOnly bool) *ProjectsLocationsVersionsListCall {
  4416  	c.urlParams_.Set("latestPatchOnly", fmt.Sprint(latestPatchOnly))
  4417  	return c
  4418  }
  4419  
  4420  // PageSize sets the optional parameter "pageSize": The maximum number of items
  4421  // to return.
  4422  func (c *ProjectsLocationsVersionsListCall) PageSize(pageSize int64) *ProjectsLocationsVersionsListCall {
  4423  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4424  	return c
  4425  }
  4426  
  4427  // PageToken sets the optional parameter "pageToken": The next_page_token value
  4428  // to use if there are additional results to retrieve for this list request.
  4429  func (c *ProjectsLocationsVersionsListCall) PageToken(pageToken string) *ProjectsLocationsVersionsListCall {
  4430  	c.urlParams_.Set("pageToken", pageToken)
  4431  	return c
  4432  }
  4433  
  4434  // Fields allows partial responses to be retrieved. See
  4435  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4436  // details.
  4437  func (c *ProjectsLocationsVersionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsVersionsListCall {
  4438  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4439  	return c
  4440  }
  4441  
  4442  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4443  // object's ETag matches the given value. This is useful for getting updates
  4444  // only after the object has changed since the last request.
  4445  func (c *ProjectsLocationsVersionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsVersionsListCall {
  4446  	c.ifNoneMatch_ = entityTag
  4447  	return c
  4448  }
  4449  
  4450  // Context sets the context to be used in this call's Do method.
  4451  func (c *ProjectsLocationsVersionsListCall) Context(ctx context.Context) *ProjectsLocationsVersionsListCall {
  4452  	c.ctx_ = ctx
  4453  	return c
  4454  }
  4455  
  4456  // Header returns a http.Header that can be modified by the caller to add
  4457  // headers to the request.
  4458  func (c *ProjectsLocationsVersionsListCall) Header() http.Header {
  4459  	if c.header_ == nil {
  4460  		c.header_ = make(http.Header)
  4461  	}
  4462  	return c.header_
  4463  }
  4464  
  4465  func (c *ProjectsLocationsVersionsListCall) doRequest(alt string) (*http.Response, error) {
  4466  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4467  	if c.ifNoneMatch_ != "" {
  4468  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4469  	}
  4470  	var body io.Reader = nil
  4471  	c.urlParams_.Set("alt", alt)
  4472  	c.urlParams_.Set("prettyPrint", "false")
  4473  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/versions")
  4474  	urls += "?" + c.urlParams_.Encode()
  4475  	req, err := http.NewRequest("GET", urls, body)
  4476  	if err != nil {
  4477  		return nil, err
  4478  	}
  4479  	req.Header = reqHeaders
  4480  	googleapi.Expand(req.URL, map[string]string{
  4481  		"parent": c.parent,
  4482  	})
  4483  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4484  }
  4485  
  4486  // Do executes the "datafusion.projects.locations.versions.list" call.
  4487  // Any non-2xx status code is an error. Response headers are in either
  4488  // *ListAvailableVersionsResponse.ServerResponse.Header or (if a response was
  4489  // returned at all) in error.(*googleapi.Error).Header. Use
  4490  // googleapi.IsNotModified to check whether the returned error was because
  4491  // http.StatusNotModified was returned.
  4492  func (c *ProjectsLocationsVersionsListCall) Do(opts ...googleapi.CallOption) (*ListAvailableVersionsResponse, error) {
  4493  	gensupport.SetOptions(c.urlParams_, opts...)
  4494  	res, err := c.doRequest("json")
  4495  	if res != nil && res.StatusCode == http.StatusNotModified {
  4496  		if res.Body != nil {
  4497  			res.Body.Close()
  4498  		}
  4499  		return nil, gensupport.WrapError(&googleapi.Error{
  4500  			Code:   res.StatusCode,
  4501  			Header: res.Header,
  4502  		})
  4503  	}
  4504  	if err != nil {
  4505  		return nil, err
  4506  	}
  4507  	defer googleapi.CloseBody(res)
  4508  	if err := googleapi.CheckResponse(res); err != nil {
  4509  		return nil, gensupport.WrapError(err)
  4510  	}
  4511  	ret := &ListAvailableVersionsResponse{
  4512  		ServerResponse: googleapi.ServerResponse{
  4513  			Header:         res.Header,
  4514  			HTTPStatusCode: res.StatusCode,
  4515  		},
  4516  	}
  4517  	target := &ret
  4518  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4519  		return nil, err
  4520  	}
  4521  	return ret, nil
  4522  }
  4523  
  4524  // Pages invokes f for each page of results.
  4525  // A non-nil error returned from f will halt the iteration.
  4526  // The provided context supersedes any context provided to the Context method.
  4527  func (c *ProjectsLocationsVersionsListCall) Pages(ctx context.Context, f func(*ListAvailableVersionsResponse) error) error {
  4528  	c.ctx_ = ctx
  4529  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4530  	for {
  4531  		x, err := c.Do()
  4532  		if err != nil {
  4533  			return err
  4534  		}
  4535  		if err := f(x); err != nil {
  4536  			return err
  4537  		}
  4538  		if x.NextPageToken == "" {
  4539  			return nil
  4540  		}
  4541  		c.PageToken(x.NextPageToken)
  4542  	}
  4543  }
  4544  

View as plain text