...

Source file src/google.golang.org/api/metastore/v1alpha/metastore-gen.go

Documentation: google.golang.org/api/metastore/v1alpha

     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 metastore provides access to the Dataproc Metastore API.
     8  //
     9  // For product documentation, see: https://cloud.google.com/dataproc-metastore/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/metastore/v1alpha"
    27  //	...
    28  //	ctx := context.Background()
    29  //	metastoreService, err := metastore.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  //	metastoreService, err := metastore.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  //	metastoreService, err := metastore.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
    49  //
    50  // See [google.golang.org/api/option.ClientOption] for details on options.
    51  package metastore // import "google.golang.org/api/metastore/v1alpha"
    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 = "metastore:v1alpha"
    90  const apiName = "metastore"
    91  const apiVersion = "v1alpha"
    92  const basePath = "https://metastore.googleapis.com/"
    93  const basePathTemplate = "https://metastore.UNIVERSE_DOMAIN/"
    94  const mtlsBasePath = "https://metastore.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 APIService.
   104  func NewService(ctx context.Context, opts ...option.ClientOption) (*APIService, 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 APIService. 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) (*APIService, error) {
   134  	if client == nil {
   135  		return nil, errors.New("client is nil")
   136  	}
   137  	s := &APIService{client: client, BasePath: basePath}
   138  	s.Projects = NewProjectsService(s)
   139  	return s, nil
   140  }
   141  
   142  type APIService 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 *APIService) userAgent() string {
   151  	if s.UserAgent == "" {
   152  		return googleapi.UserAgent
   153  	}
   154  	return googleapi.UserAgent + " " + s.UserAgent
   155  }
   156  
   157  func NewProjectsService(s *APIService) *ProjectsService {
   158  	rs := &ProjectsService{s: s}
   159  	rs.Locations = NewProjectsLocationsService(s)
   160  	return rs
   161  }
   162  
   163  type ProjectsService struct {
   164  	s *APIService
   165  
   166  	Locations *ProjectsLocationsService
   167  }
   168  
   169  func NewProjectsLocationsService(s *APIService) *ProjectsLocationsService {
   170  	rs := &ProjectsLocationsService{s: s}
   171  	rs.Federations = NewProjectsLocationsFederationsService(s)
   172  	rs.Operations = NewProjectsLocationsOperationsService(s)
   173  	rs.Services = NewProjectsLocationsServicesService(s)
   174  	return rs
   175  }
   176  
   177  type ProjectsLocationsService struct {
   178  	s *APIService
   179  
   180  	Federations *ProjectsLocationsFederationsService
   181  
   182  	Operations *ProjectsLocationsOperationsService
   183  
   184  	Services *ProjectsLocationsServicesService
   185  }
   186  
   187  func NewProjectsLocationsFederationsService(s *APIService) *ProjectsLocationsFederationsService {
   188  	rs := &ProjectsLocationsFederationsService{s: s}
   189  	return rs
   190  }
   191  
   192  type ProjectsLocationsFederationsService struct {
   193  	s *APIService
   194  }
   195  
   196  func NewProjectsLocationsOperationsService(s *APIService) *ProjectsLocationsOperationsService {
   197  	rs := &ProjectsLocationsOperationsService{s: s}
   198  	return rs
   199  }
   200  
   201  type ProjectsLocationsOperationsService struct {
   202  	s *APIService
   203  }
   204  
   205  func NewProjectsLocationsServicesService(s *APIService) *ProjectsLocationsServicesService {
   206  	rs := &ProjectsLocationsServicesService{s: s}
   207  	rs.Backups = NewProjectsLocationsServicesBackupsService(s)
   208  	rs.Databases = NewProjectsLocationsServicesDatabasesService(s)
   209  	rs.MetadataImports = NewProjectsLocationsServicesMetadataImportsService(s)
   210  	rs.MigrationExecutions = NewProjectsLocationsServicesMigrationExecutionsService(s)
   211  	return rs
   212  }
   213  
   214  type ProjectsLocationsServicesService struct {
   215  	s *APIService
   216  
   217  	Backups *ProjectsLocationsServicesBackupsService
   218  
   219  	Databases *ProjectsLocationsServicesDatabasesService
   220  
   221  	MetadataImports *ProjectsLocationsServicesMetadataImportsService
   222  
   223  	MigrationExecutions *ProjectsLocationsServicesMigrationExecutionsService
   224  }
   225  
   226  func NewProjectsLocationsServicesBackupsService(s *APIService) *ProjectsLocationsServicesBackupsService {
   227  	rs := &ProjectsLocationsServicesBackupsService{s: s}
   228  	return rs
   229  }
   230  
   231  type ProjectsLocationsServicesBackupsService struct {
   232  	s *APIService
   233  }
   234  
   235  func NewProjectsLocationsServicesDatabasesService(s *APIService) *ProjectsLocationsServicesDatabasesService {
   236  	rs := &ProjectsLocationsServicesDatabasesService{s: s}
   237  	rs.Tables = NewProjectsLocationsServicesDatabasesTablesService(s)
   238  	return rs
   239  }
   240  
   241  type ProjectsLocationsServicesDatabasesService struct {
   242  	s *APIService
   243  
   244  	Tables *ProjectsLocationsServicesDatabasesTablesService
   245  }
   246  
   247  func NewProjectsLocationsServicesDatabasesTablesService(s *APIService) *ProjectsLocationsServicesDatabasesTablesService {
   248  	rs := &ProjectsLocationsServicesDatabasesTablesService{s: s}
   249  	return rs
   250  }
   251  
   252  type ProjectsLocationsServicesDatabasesTablesService struct {
   253  	s *APIService
   254  }
   255  
   256  func NewProjectsLocationsServicesMetadataImportsService(s *APIService) *ProjectsLocationsServicesMetadataImportsService {
   257  	rs := &ProjectsLocationsServicesMetadataImportsService{s: s}
   258  	return rs
   259  }
   260  
   261  type ProjectsLocationsServicesMetadataImportsService struct {
   262  	s *APIService
   263  }
   264  
   265  func NewProjectsLocationsServicesMigrationExecutionsService(s *APIService) *ProjectsLocationsServicesMigrationExecutionsService {
   266  	rs := &ProjectsLocationsServicesMigrationExecutionsService{s: s}
   267  	return rs
   268  }
   269  
   270  type ProjectsLocationsServicesMigrationExecutionsService struct {
   271  	s *APIService
   272  }
   273  
   274  // AlterMetadataResourceLocationRequest: Request message for
   275  // DataprocMetastore.AlterMetadataResourceLocation.
   276  type AlterMetadataResourceLocationRequest struct {
   277  	// LocationUri: Required. The new location URI for the metadata resource.
   278  	LocationUri string `json:"locationUri,omitempty"`
   279  	// ResourceName: Required. The relative metadata resource name in the following
   280  	// format.databases/{database_id} or databases/{database_id}/tables/{table_id}
   281  	// or databases/{database_id}/tables/{table_id}/partitions/{partition_id}
   282  	ResourceName string `json:"resourceName,omitempty"`
   283  	// ForceSendFields is a list of field names (e.g. "LocationUri") to
   284  	// unconditionally include in API requests. By default, fields with empty or
   285  	// default values are omitted from API requests. See
   286  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   287  	// details.
   288  	ForceSendFields []string `json:"-"`
   289  	// NullFields is a list of field names (e.g. "LocationUri") to include in API
   290  	// requests with the JSON null value. By default, fields with empty values are
   291  	// omitted from API requests. See
   292  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   293  	NullFields []string `json:"-"`
   294  }
   295  
   296  func (s *AlterMetadataResourceLocationRequest) MarshalJSON() ([]byte, error) {
   297  	type NoMethod AlterMetadataResourceLocationRequest
   298  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   299  }
   300  
   301  // AlterMetadataResourceLocationResponse: Response message for
   302  // DataprocMetastore.AlterMetadataResourceLocation.
   303  type AlterMetadataResourceLocationResponse struct {
   304  }
   305  
   306  // AlterTablePropertiesRequest: Request message for
   307  // DataprocMetastore.AlterTableProperties.
   308  type AlterTablePropertiesRequest struct {
   309  	// Properties: A map that describes the desired values to mutate. If
   310  	// update_mask is empty, the properties will not update. Otherwise, the
   311  	// properties only alters the value whose associated paths exist in the update
   312  	// mask
   313  	Properties map[string]string `json:"properties,omitempty"`
   314  	// TableName: Required. The name of the table containing the properties you're
   315  	// altering in the following format.databases/{database_id}/tables/{table_id}
   316  	TableName string `json:"tableName,omitempty"`
   317  	// UpdateMask: A field mask that specifies the metadata table properties that
   318  	// are overwritten by the update. Fields specified in the update_mask are
   319  	// relative to the resource (not to the full request). A field is overwritten
   320  	// if it is in the mask.For example, given the target properties: properties {
   321  	// a: 1 b: 2 } And an update properties: properties { a: 2 b: 3 c: 4 } then if
   322  	// the field mask is:paths: "properties.b", "properties.c"then the result will
   323  	// be: properties { a: 1 b: 3 c: 4 }
   324  	UpdateMask string `json:"updateMask,omitempty"`
   325  	// ForceSendFields is a list of field names (e.g. "Properties") to
   326  	// unconditionally include in API requests. By default, fields with empty or
   327  	// default values are omitted from API requests. See
   328  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   329  	// details.
   330  	ForceSendFields []string `json:"-"`
   331  	// NullFields is a list of field names (e.g. "Properties") to include in API
   332  	// requests with the JSON null value. By default, fields with empty values are
   333  	// omitted from API requests. See
   334  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   335  	NullFields []string `json:"-"`
   336  }
   337  
   338  func (s *AlterTablePropertiesRequest) MarshalJSON() ([]byte, error) {
   339  	type NoMethod AlterTablePropertiesRequest
   340  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   341  }
   342  
   343  // AuditConfig: Specifies the audit configuration for a service. The
   344  // configuration determines which permission types are logged, and what
   345  // identities, if any, are exempted from logging. An AuditConfig must have one
   346  // or more AuditLogConfigs.If there are AuditConfigs for both allServices and a
   347  // specific service, the union of the two AuditConfigs is used for that
   348  // service: the log_types specified in each AuditConfig are enabled, and the
   349  // exempted_members in each AuditLogConfig are exempted.Example Policy with
   350  // multiple AuditConfigs: { "audit_configs": [ { "service": "allServices",
   351  // "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [
   352  // "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" }, { "log_type":
   353  // "ADMIN_READ" } ] }, { "service": "sampleservice.googleapis.com",
   354  // "audit_log_configs": [ { "log_type": "DATA_READ" }, { "log_type":
   355  // "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For
   356  // sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ
   357  // logging. It also exempts jose@example.com from DATA_READ logging, and
   358  // aliya@example.com from DATA_WRITE logging.
   359  type AuditConfig struct {
   360  	// AuditLogConfigs: The configuration for logging of each type of permission.
   361  	AuditLogConfigs []*AuditLogConfig `json:"auditLogConfigs,omitempty"`
   362  	// Service: Specifies a service that will be enabled for audit logging. For
   363  	// example, storage.googleapis.com, cloudsql.googleapis.com. allServices is a
   364  	// special value that covers all services.
   365  	Service string `json:"service,omitempty"`
   366  	// ForceSendFields is a list of field names (e.g. "AuditLogConfigs") to
   367  	// unconditionally include in API requests. By default, fields with empty or
   368  	// default values are omitted from API requests. See
   369  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   370  	// details.
   371  	ForceSendFields []string `json:"-"`
   372  	// NullFields is a list of field names (e.g. "AuditLogConfigs") to include in
   373  	// API requests with the JSON null value. By default, fields with empty values
   374  	// are omitted from API requests. See
   375  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   376  	NullFields []string `json:"-"`
   377  }
   378  
   379  func (s *AuditConfig) MarshalJSON() ([]byte, error) {
   380  	type NoMethod AuditConfig
   381  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   382  }
   383  
   384  // AuditLogConfig: Provides the configuration for logging a type of
   385  // permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ",
   386  // "exempted_members": [ "user:jose@example.com" ] }, { "log_type":
   387  // "DATA_WRITE" } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while
   388  // exempting jose@example.com from DATA_READ logging.
   389  type AuditLogConfig struct {
   390  	// ExemptedMembers: Specifies the identities that do not cause logging for this
   391  	// type of permission. Follows the same format of Binding.members.
   392  	ExemptedMembers []string `json:"exemptedMembers,omitempty"`
   393  	// LogType: The log type that this config enables.
   394  	//
   395  	// Possible values:
   396  	//   "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this.
   397  	//   "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy
   398  	//   "DATA_WRITE" - Data writes. Example: CloudSQL Users create
   399  	//   "DATA_READ" - Data reads. Example: CloudSQL Users list
   400  	LogType string `json:"logType,omitempty"`
   401  	// ForceSendFields is a list of field names (e.g. "ExemptedMembers") to
   402  	// unconditionally include in API requests. By default, fields with empty or
   403  	// default values are omitted from API requests. See
   404  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   405  	// details.
   406  	ForceSendFields []string `json:"-"`
   407  	// NullFields is a list of field names (e.g. "ExemptedMembers") to include in
   408  	// API requests with the JSON null value. By default, fields with empty values
   409  	// are omitted from API requests. See
   410  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   411  	NullFields []string `json:"-"`
   412  }
   413  
   414  func (s *AuditLogConfig) MarshalJSON() ([]byte, error) {
   415  	type NoMethod AuditLogConfig
   416  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   417  }
   418  
   419  // AutoscalingConfig: Represents the autoscaling configuration of a metastore
   420  // service.
   421  type AutoscalingConfig struct {
   422  	// AutoscalingEnabled: Optional. Whether or not autoscaling is enabled for this
   423  	// service.
   424  	AutoscalingEnabled bool `json:"autoscalingEnabled,omitempty"`
   425  	// AutoscalingFactor: Output only. The scaling factor of a service with
   426  	// autoscaling enabled.
   427  	AutoscalingFactor float64 `json:"autoscalingFactor,omitempty"`
   428  	// LimitConfig: Optional. The LimitConfig of the service.
   429  	LimitConfig *LimitConfig `json:"limitConfig,omitempty"`
   430  	// ForceSendFields is a list of field names (e.g. "AutoscalingEnabled") to
   431  	// unconditionally include in API requests. By default, fields with empty or
   432  	// default values are omitted from API requests. See
   433  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   434  	// details.
   435  	ForceSendFields []string `json:"-"`
   436  	// NullFields is a list of field names (e.g. "AutoscalingEnabled") to include
   437  	// in API requests with the JSON null value. By default, fields with empty
   438  	// values are omitted from API requests. See
   439  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   440  	NullFields []string `json:"-"`
   441  }
   442  
   443  func (s *AutoscalingConfig) MarshalJSON() ([]byte, error) {
   444  	type NoMethod AutoscalingConfig
   445  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   446  }
   447  
   448  func (s *AutoscalingConfig) UnmarshalJSON(data []byte) error {
   449  	type NoMethod AutoscalingConfig
   450  	var s1 struct {
   451  		AutoscalingFactor gensupport.JSONFloat64 `json:"autoscalingFactor"`
   452  		*NoMethod
   453  	}
   454  	s1.NoMethod = (*NoMethod)(s)
   455  	if err := json.Unmarshal(data, &s1); err != nil {
   456  		return err
   457  	}
   458  	s.AutoscalingFactor = float64(s1.AutoscalingFactor)
   459  	return nil
   460  }
   461  
   462  // AuxiliaryVersionConfig: Configuration information for the auxiliary service
   463  // versions.
   464  type AuxiliaryVersionConfig struct {
   465  	// ConfigOverrides: A mapping of Hive metastore configuration key-value pairs
   466  	// to apply to the auxiliary Hive metastore (configured in hive-site.xml) in
   467  	// addition to the primary version's overrides. If keys are present in both the
   468  	// auxiliary version's overrides and the primary version's overrides, the value
   469  	// from the auxiliary version's overrides takes precedence.
   470  	ConfigOverrides map[string]string `json:"configOverrides,omitempty"`
   471  	// NetworkConfig: Output only. The network configuration contains the endpoint
   472  	// URI(s) of the auxiliary Hive metastore service.
   473  	NetworkConfig *NetworkConfig `json:"networkConfig,omitempty"`
   474  	// Version: The Hive metastore version of the auxiliary service. It must be
   475  	// less than the primary Hive metastore service's version.
   476  	Version string `json:"version,omitempty"`
   477  	// ForceSendFields is a list of field names (e.g. "ConfigOverrides") to
   478  	// unconditionally include in API requests. By default, fields with empty or
   479  	// default values are omitted from API requests. See
   480  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   481  	// details.
   482  	ForceSendFields []string `json:"-"`
   483  	// NullFields is a list of field names (e.g. "ConfigOverrides") to include in
   484  	// API requests with the JSON null value. By default, fields with empty values
   485  	// are omitted from API requests. See
   486  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   487  	NullFields []string `json:"-"`
   488  }
   489  
   490  func (s *AuxiliaryVersionConfig) MarshalJSON() ([]byte, error) {
   491  	type NoMethod AuxiliaryVersionConfig
   492  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   493  }
   494  
   495  // BackendMetastore: Represents a backend metastore for the federation.
   496  type BackendMetastore struct {
   497  	// MetastoreType: The type of the backend metastore.
   498  	//
   499  	// Possible values:
   500  	//   "METASTORE_TYPE_UNSPECIFIED" - The metastore type is not set.
   501  	//   "DATAPLEX" - The backend metastore is Dataplex.
   502  	//   "BIGQUERY" - The backend metastore is BigQuery.
   503  	//   "DATAPROC_METASTORE" - The backend metastore is Dataproc Metastore.
   504  	MetastoreType string `json:"metastoreType,omitempty"`
   505  	// Name: The relative resource name of the metastore that is being federated.
   506  	// The formats of the relative resource names for the currently supported
   507  	// metastores are listed below: BigQuery projects/{project_id} Dataproc
   508  	// Metastore projects/{project_id}/locations/{location}/services/{service_id}
   509  	Name string `json:"name,omitempty"`
   510  	// ForceSendFields is a list of field names (e.g. "MetastoreType") to
   511  	// unconditionally include in API requests. By default, fields with empty or
   512  	// default values are omitted from API requests. See
   513  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   514  	// details.
   515  	ForceSendFields []string `json:"-"`
   516  	// NullFields is a list of field names (e.g. "MetastoreType") to include in API
   517  	// requests with the JSON null value. By default, fields with empty values are
   518  	// omitted from API requests. See
   519  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   520  	NullFields []string `json:"-"`
   521  }
   522  
   523  func (s *BackendMetastore) MarshalJSON() ([]byte, error) {
   524  	type NoMethod BackendMetastore
   525  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   526  }
   527  
   528  // Backup: The details of a backup resource.
   529  type Backup struct {
   530  	// CreateTime: Output only. The time when the backup was started.
   531  	CreateTime string `json:"createTime,omitempty"`
   532  	// Description: The description of the backup.
   533  	Description string `json:"description,omitempty"`
   534  	// EndTime: Output only. The time when the backup finished creating.
   535  	EndTime string `json:"endTime,omitempty"`
   536  	// Name: Immutable. The relative resource name of the backup, in the following
   537  	// form:projects/{project_number}/locations/{location_id}/services/{service_id}/
   538  	// backups/{backup_id}
   539  	Name string `json:"name,omitempty"`
   540  	// RestoringServices: Output only. Services that are restoring from the backup.
   541  	RestoringServices []string `json:"restoringServices,omitempty"`
   542  	// ServiceRevision: Output only. The revision of the service at the time of
   543  	// backup.
   544  	ServiceRevision *Service `json:"serviceRevision,omitempty"`
   545  	// State: Output only. The current state of the backup.
   546  	//
   547  	// Possible values:
   548  	//   "STATE_UNSPECIFIED" - The state of the backup is unknown.
   549  	//   "CREATING" - The backup is being created.
   550  	//   "DELETING" - The backup is being deleted.
   551  	//   "ACTIVE" - The backup is active and ready to use.
   552  	//   "FAILED" - The backup failed.
   553  	//   "RESTORING" - The backup is being restored.
   554  	State string `json:"state,omitempty"`
   555  
   556  	// ServerResponse contains the HTTP response code and headers from the server.
   557  	googleapi.ServerResponse `json:"-"`
   558  	// ForceSendFields is a list of field names (e.g. "CreateTime") to
   559  	// unconditionally include in API requests. By default, fields with empty or
   560  	// default values are omitted from API requests. See
   561  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   562  	// details.
   563  	ForceSendFields []string `json:"-"`
   564  	// NullFields is a list of field names (e.g. "CreateTime") to include in API
   565  	// requests with the JSON null value. By default, fields with empty values are
   566  	// omitted from API requests. See
   567  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   568  	NullFields []string `json:"-"`
   569  }
   570  
   571  func (s *Backup) MarshalJSON() ([]byte, error) {
   572  	type NoMethod Backup
   573  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   574  }
   575  
   576  // Binding: Associates members, or principals, with a role.
   577  type Binding struct {
   578  	// Condition: The condition that is associated with this binding.If the
   579  	// condition evaluates to true, then this binding applies to the current
   580  	// request.If the condition evaluates to false, then this binding does not
   581  	// apply to the current request. However, a different role binding might grant
   582  	// the same role to one or more of the principals in this binding.To learn
   583  	// which resources support conditions in their IAM policies, see the IAM
   584  	// documentation
   585  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
   586  	Condition *Expr `json:"condition,omitempty"`
   587  	// Members: Specifies the principals requesting access for a Google Cloud
   588  	// resource. members can have the following values: allUsers: A special
   589  	// identifier that represents anyone who is on the internet; with or without a
   590  	// Google account. allAuthenticatedUsers: A special identifier that represents
   591  	// anyone who is authenticated with a Google account or a service account. Does
   592  	// not include identities that come from external identity providers (IdPs)
   593  	// through identity federation. user:{emailid}: An email address that
   594  	// represents a specific Google account. For example, alice@example.com .
   595  	// serviceAccount:{emailid}: An email address that represents a Google service
   596  	// account. For example, my-other-app@appspot.gserviceaccount.com.
   597  	// serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]: An
   598  	// identifier for a Kubernetes service account
   599  	// (https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts).
   600  	// For example, my-project.svc.id.goog[my-namespace/my-kubernetes-sa].
   601  	// group:{emailid}: An email address that represents a Google group. For
   602  	// example, admins@example.com. domain:{domain}: The G Suite domain (primary)
   603  	// that represents all the users of that domain. For example, google.com or
   604  	// example.com.
   605  	// principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/subj
   606  	// ect/{subject_attribute_value}: A single identity in a workforce identity
   607  	// pool.
   608  	// principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/g
   609  	// roup/{group_id}: All workforce identities in a group.
   610  	// principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/a
   611  	// ttribute.{attribute_name}/{attribute_value}: All workforce identities with a
   612  	// specific attribute value.
   613  	// principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/*
   614  	// : All identities in a workforce identity pool.
   615  	// principal://iam.googleapis.com/projects/{project_number}/locations/global/wor
   616  	// kloadIdentityPools/{pool_id}/subject/{subject_attribute_value}: A single
   617  	// identity in a workload identity pool.
   618  	// principalSet://iam.googleapis.com/projects/{project_number}/locations/global/
   619  	// workloadIdentityPools/{pool_id}/group/{group_id}: A workload identity pool
   620  	// group.
   621  	// principalSet://iam.googleapis.com/projects/{project_number}/locations/global/
   622  	// workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{attribute_value}:
   623  	//  All identities in a workload identity pool with a certain attribute.
   624  	// principalSet://iam.googleapis.com/projects/{project_number}/locations/global/
   625  	// workloadIdentityPools/{pool_id}/*: All identities in a workload identity
   626  	// pool. deleted:user:{emailid}?uid={uniqueid}: An email address (plus unique
   627  	// identifier) representing a user that has been recently deleted. For example,
   628  	// alice@example.com?uid=123456789012345678901. If the user is recovered, this
   629  	// value reverts to user:{emailid} and the recovered user retains the role in
   630  	// the binding. deleted:serviceAccount:{emailid}?uid={uniqueid}: An email
   631  	// address (plus unique identifier) representing a service account that has
   632  	// been recently deleted. For example,
   633  	// my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901. If the
   634  	// service account is undeleted, this value reverts to serviceAccount:{emailid}
   635  	// and the undeleted service account retains the role in the binding.
   636  	// deleted:group:{emailid}?uid={uniqueid}: An email address (plus unique
   637  	// identifier) representing a Google group that has been recently deleted. For
   638  	// example, admins@example.com?uid=123456789012345678901. If the group is
   639  	// recovered, this value reverts to group:{emailid} and the recovered group
   640  	// retains the role in the binding.
   641  	// deleted:principal://iam.googleapis.com/locations/global/workforcePools/{pool_
   642  	// id}/subject/{subject_attribute_value}: Deleted single identity in a
   643  	// workforce identity pool. For example,
   644  	// deleted:principal://iam.googleapis.com/locations/global/workforcePools/my-poo
   645  	// l-id/subject/my-subject-attribute-value.
   646  	Members []string `json:"members,omitempty"`
   647  	// Role: Role that is assigned to the list of members, or principals. For
   648  	// example, roles/viewer, roles/editor, or roles/owner.For an overview of the
   649  	// IAM roles and permissions, see the IAM documentation
   650  	// (https://cloud.google.com/iam/docs/roles-overview). For a list of the
   651  	// available pre-defined roles, see here
   652  	// (https://cloud.google.com/iam/docs/understanding-roles).
   653  	Role string `json:"role,omitempty"`
   654  	// ForceSendFields is a list of field names (e.g. "Condition") to
   655  	// unconditionally include in API requests. By default, fields with empty or
   656  	// default values are omitted from API requests. See
   657  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   658  	// details.
   659  	ForceSendFields []string `json:"-"`
   660  	// NullFields is a list of field names (e.g. "Condition") to include in API
   661  	// requests with the JSON null value. By default, fields with empty values are
   662  	// omitted from API requests. See
   663  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   664  	NullFields []string `json:"-"`
   665  }
   666  
   667  func (s *Binding) MarshalJSON() ([]byte, error) {
   668  	type NoMethod Binding
   669  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   670  }
   671  
   672  // CancelMigrationRequest: Request message for
   673  // DataprocMetastore.CancelMigration.
   674  type CancelMigrationRequest struct {
   675  }
   676  
   677  // CancelMigrationResponse: Response message for
   678  // DataprocMetastore.CancelMigration.
   679  type CancelMigrationResponse struct {
   680  	// MigrationExecution: The relative resource name of the migration execution,
   681  	// in the following
   682  	// form:projects/{project_number}/locations/{location_id}/services/{service_id}/
   683  	// migrationExecutions/{migration_execution_id}.
   684  	MigrationExecution string `json:"migrationExecution,omitempty"`
   685  	// ForceSendFields is a list of field names (e.g. "MigrationExecution") to
   686  	// unconditionally include in API requests. By default, fields with empty or
   687  	// default values are omitted from API requests. See
   688  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   689  	// details.
   690  	ForceSendFields []string `json:"-"`
   691  	// NullFields is a list of field names (e.g. "MigrationExecution") to include
   692  	// in API requests with the JSON null value. By default, fields with empty
   693  	// values are omitted from API requests. See
   694  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   695  	NullFields []string `json:"-"`
   696  }
   697  
   698  func (s *CancelMigrationResponse) MarshalJSON() ([]byte, error) {
   699  	type NoMethod CancelMigrationResponse
   700  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   701  }
   702  
   703  // CancelOperationRequest: The request message for Operations.CancelOperation.
   704  type CancelOperationRequest struct {
   705  }
   706  
   707  // CdcConfig: Configuration information to start the Change Data Capture (CDC)
   708  // streams from customer database to backend database of Dataproc Metastore.
   709  type CdcConfig struct {
   710  	// Bucket: Optional. The bucket to write the intermediate stream event data in.
   711  	// The bucket name must be without any prefix like "gs://". See the bucket
   712  	// naming requirements (https://cloud.google.com/storage/docs/buckets#naming).
   713  	// This field is optional. If not set, the Artifacts Cloud Storage bucket will
   714  	// be used.
   715  	Bucket string `json:"bucket,omitempty"`
   716  	// Password: Required. Input only. The password for the user that Datastream
   717  	// service should use for the MySQL connection. This field is not returned on
   718  	// request.
   719  	Password string `json:"password,omitempty"`
   720  	// ReverseProxySubnet: Required. The URL of the subnetwork resource to create
   721  	// the VM instance hosting the reverse proxy in. More context in
   722  	// https://cloud.google.com/datastream/docs/private-connectivity#reverse-csql-proxy
   723  	// The subnetwork should reside in the network provided in the request that
   724  	// Datastream will peer to and should be in the same region as Datastream, in
   725  	// the following format.
   726  	// projects/{project_id}/regions/{region_id}/subnetworks/{subnetwork_id}
   727  	ReverseProxySubnet string `json:"reverseProxySubnet,omitempty"`
   728  	// RootPath: Optional. The root path inside the Cloud Storage bucket. The
   729  	// stream event data will be written to this path. The default value is
   730  	// /migration.
   731  	RootPath string `json:"rootPath,omitempty"`
   732  	// SubnetIpRange: Required. A /29 CIDR IP range for peering with datastream.
   733  	SubnetIpRange string `json:"subnetIpRange,omitempty"`
   734  	// Username: Required. The username that the Datastream service should use for
   735  	// the MySQL connection.
   736  	Username string `json:"username,omitempty"`
   737  	// VpcNetwork: Required. Fully qualified name of the Cloud SQL instance's VPC
   738  	// network or the shared VPC network that Datastream will peer to, in the
   739  	// following format:
   740  	// projects/{project_id}/locations/global/networks/{network_id}. More context
   741  	// in
   742  	// https://cloud.google.com/datastream/docs/network-connectivity-options#privateconnectivity
   743  	VpcNetwork string `json:"vpcNetwork,omitempty"`
   744  	// ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally
   745  	// include in API requests. By default, fields with empty or default values are
   746  	// omitted from API requests. See
   747  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   748  	// details.
   749  	ForceSendFields []string `json:"-"`
   750  	// NullFields is a list of field names (e.g. "Bucket") to include in API
   751  	// requests with the JSON null value. By default, fields with empty values are
   752  	// omitted from API requests. See
   753  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   754  	NullFields []string `json:"-"`
   755  }
   756  
   757  func (s *CdcConfig) MarshalJSON() ([]byte, error) {
   758  	type NoMethod CdcConfig
   759  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   760  }
   761  
   762  // CloudSQLConnectionConfig: Configuration information to establish customer
   763  // database connection before the cutover phase of migration
   764  type CloudSQLConnectionConfig struct {
   765  	// HiveDatabaseName: Required. The hive database name.
   766  	HiveDatabaseName string `json:"hiveDatabaseName,omitempty"`
   767  	// InstanceConnectionName: Required. Cloud SQL database connection name
   768  	// (project_id:region:instance_name)
   769  	InstanceConnectionName string `json:"instanceConnectionName,omitempty"`
   770  	// IpAddress: Required. The private IP address of the Cloud SQL instance.
   771  	IpAddress string `json:"ipAddress,omitempty"`
   772  	// NatSubnet: Required. The relative resource name of the subnetwork to be used
   773  	// for Private Service Connect. Note that this cannot be a regular subnet and
   774  	// is used only for NAT.
   775  	// (https://cloud.google.com/vpc/docs/about-vpc-hosted-services#psc-subnets)
   776  	// This subnet is used to publish the SOCKS5 proxy service. The subnet size
   777  	// must be at least /29 and it should reside in a network through which the
   778  	// Cloud SQL instance is accessible. The resource name should be in the format,
   779  	// projects/{project_id}/regions/{region_id}/subnetworks/{subnetwork_id}
   780  	NatSubnet string `json:"natSubnet,omitempty"`
   781  	// Password: Required. Input only. The password for the user that Dataproc
   782  	// Metastore service will be using to connect to the database. This field is
   783  	// not returned on request.
   784  	Password string `json:"password,omitempty"`
   785  	// Port: Required. The network port of the database.
   786  	Port int64 `json:"port,omitempty"`
   787  	// ProxySubnet: Required. The relative resource name of the subnetwork to
   788  	// deploy the SOCKS5 proxy service in. The subnetwork should reside in a
   789  	// network through which the Cloud SQL instance is accessible. The resource
   790  	// name should be in the format,
   791  	// projects/{project_id}/regions/{region_id}/subnetworks/{subnetwork_id}
   792  	ProxySubnet string `json:"proxySubnet,omitempty"`
   793  	// Username: Required. The username that Dataproc Metastore service will use to
   794  	// connect to the database.
   795  	Username string `json:"username,omitempty"`
   796  	// ForceSendFields is a list of field names (e.g. "HiveDatabaseName") to
   797  	// unconditionally include in API requests. By default, fields with empty or
   798  	// default values are omitted from API requests. See
   799  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   800  	// details.
   801  	ForceSendFields []string `json:"-"`
   802  	// NullFields is a list of field names (e.g. "HiveDatabaseName") to include in
   803  	// API requests with the JSON null value. By default, fields with empty values
   804  	// are omitted from API requests. See
   805  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   806  	NullFields []string `json:"-"`
   807  }
   808  
   809  func (s *CloudSQLConnectionConfig) MarshalJSON() ([]byte, error) {
   810  	type NoMethod CloudSQLConnectionConfig
   811  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   812  }
   813  
   814  // CloudSQLMigrationConfig: Configuration information for migrating from
   815  // self-managed hive metastore on Google Cloud using Cloud SQL as the backend
   816  // database to Dataproc Metastore.
   817  type CloudSQLMigrationConfig struct {
   818  	// CdcConfig: Required. Configuration information to start the Change Data
   819  	// Capture (CDC) streams from customer database to backend database of Dataproc
   820  	// Metastore. Dataproc Metastore switches to using its backend database after
   821  	// the cutover phase of migration.
   822  	CdcConfig *CdcConfig `json:"cdcConfig,omitempty"`
   823  	// CloudSqlConnectionConfig: Required. Configuration information to establish
   824  	// customer database connection before the cutover phase of migration
   825  	CloudSqlConnectionConfig *CloudSQLConnectionConfig `json:"cloudSqlConnectionConfig,omitempty"`
   826  	// ForceSendFields is a list of field names (e.g. "CdcConfig") to
   827  	// unconditionally include in API requests. By default, fields with empty or
   828  	// default values are omitted from API requests. See
   829  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   830  	// details.
   831  	ForceSendFields []string `json:"-"`
   832  	// NullFields is a list of field names (e.g. "CdcConfig") to include in API
   833  	// requests with the JSON null value. By default, fields with empty values are
   834  	// omitted from API requests. See
   835  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   836  	NullFields []string `json:"-"`
   837  }
   838  
   839  func (s *CloudSQLMigrationConfig) MarshalJSON() ([]byte, error) {
   840  	type NoMethod CloudSQLMigrationConfig
   841  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   842  }
   843  
   844  // CompleteMigrationRequest: Request message for
   845  // DataprocMetastore.CompleteMigration.
   846  type CompleteMigrationRequest struct {
   847  }
   848  
   849  // CompleteMigrationResponse: Response message for
   850  // DataprocMetastore.CompleteMigration.
   851  type CompleteMigrationResponse struct {
   852  	// MigrationExecution: The relative resource name of the migration execution,
   853  	// in the following
   854  	// form:projects/{project_number}/locations/{location_id}/services/{service_id}/
   855  	// migrationExecutions/{migration_execution_id}.
   856  	MigrationExecution string `json:"migrationExecution,omitempty"`
   857  	// ForceSendFields is a list of field names (e.g. "MigrationExecution") to
   858  	// unconditionally include in API requests. By default, fields with empty or
   859  	// default values are omitted from API requests. See
   860  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   861  	// details.
   862  	ForceSendFields []string `json:"-"`
   863  	// NullFields is a list of field names (e.g. "MigrationExecution") to include
   864  	// in API requests with the JSON null value. By default, fields with empty
   865  	// values are omitted from API requests. See
   866  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   867  	NullFields []string `json:"-"`
   868  }
   869  
   870  func (s *CompleteMigrationResponse) MarshalJSON() ([]byte, error) {
   871  	type NoMethod CompleteMigrationResponse
   872  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   873  }
   874  
   875  // Consumer: Contains information of the customer's network configurations.
   876  type Consumer struct {
   877  	// EndpointLocation: Output only. The location of the endpoint URI. Format:
   878  	// projects/{project}/locations/{location}.
   879  	EndpointLocation string `json:"endpointLocation,omitempty"`
   880  	// EndpointUri: Output only. The URI of the endpoint used to access the
   881  	// metastore service.
   882  	EndpointUri string `json:"endpointUri,omitempty"`
   883  	// Subnetwork: Immutable. The subnetwork of the customer project from which an
   884  	// IP address is reserved and used as the Dataproc Metastore service's
   885  	// endpoint. It is accessible to hosts in the subnet and to all hosts in a
   886  	// subnet in the same region and same network. There must be at least one IP
   887  	// address available in the subnet's primary range. The subnet is specified in
   888  	// the following
   889  	// form:projects/{project_number}/regions/{region_id}/subnetworks/{subnetwork_id
   890  	// }
   891  	Subnetwork string `json:"subnetwork,omitempty"`
   892  	// ForceSendFields is a list of field names (e.g. "EndpointLocation") to
   893  	// unconditionally include in API requests. By default, fields with empty or
   894  	// default values are omitted from API requests. See
   895  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   896  	// details.
   897  	ForceSendFields []string `json:"-"`
   898  	// NullFields is a list of field names (e.g. "EndpointLocation") to include in
   899  	// API requests with the JSON null value. By default, fields with empty values
   900  	// are omitted from API requests. See
   901  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   902  	NullFields []string `json:"-"`
   903  }
   904  
   905  func (s *Consumer) MarshalJSON() ([]byte, error) {
   906  	type NoMethod Consumer
   907  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   908  }
   909  
   910  // DataCatalogConfig: Specifies how metastore metadata should be integrated
   911  // with the Data Catalog service.
   912  type DataCatalogConfig struct {
   913  	// Enabled: Optional. Defines whether the metastore metadata should be synced
   914  	// to Data Catalog. The default value is to disable syncing metastore metadata
   915  	// to Data Catalog.
   916  	Enabled bool `json:"enabled,omitempty"`
   917  	// ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally
   918  	// include in API requests. By default, fields with empty or default values are
   919  	// omitted from API requests. See
   920  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   921  	// details.
   922  	ForceSendFields []string `json:"-"`
   923  	// NullFields is a list of field names (e.g. "Enabled") to include in API
   924  	// requests with the JSON null value. By default, fields with empty values are
   925  	// omitted from API requests. See
   926  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   927  	NullFields []string `json:"-"`
   928  }
   929  
   930  func (s *DataCatalogConfig) MarshalJSON() ([]byte, error) {
   931  	type NoMethod DataCatalogConfig
   932  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   933  }
   934  
   935  // DatabaseDump: A specification of the location of and metadata about a
   936  // database dump from a relational database management system.
   937  type DatabaseDump struct {
   938  	// DatabaseType: The type of the database.
   939  	//
   940  	// Possible values:
   941  	//   "DATABASE_TYPE_UNSPECIFIED" - The type of the source database is unknown.
   942  	//   "MYSQL" - The type of the source database is MySQL.
   943  	DatabaseType string `json:"databaseType,omitempty"`
   944  	// GcsUri: A Cloud Storage object or folder URI that specifies the source from
   945  	// which to import metadata. It must begin with gs://.
   946  	GcsUri string `json:"gcsUri,omitempty"`
   947  	// SourceDatabase: The name of the source database.
   948  	SourceDatabase string `json:"sourceDatabase,omitempty"`
   949  	// Type: Optional. The type of the database dump. If unspecified, defaults to
   950  	// MYSQL.
   951  	//
   952  	// Possible values:
   953  	//   "TYPE_UNSPECIFIED" - The type of the database dump is unknown.
   954  	//   "MYSQL" - Database dump is a MySQL dump file.
   955  	//   "AVRO" - Database dump contains Avro files.
   956  	Type string `json:"type,omitempty"`
   957  	// ForceSendFields is a list of field names (e.g. "DatabaseType") to
   958  	// unconditionally include in API requests. By default, fields with empty or
   959  	// default values are omitted from API requests. See
   960  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   961  	// details.
   962  	ForceSendFields []string `json:"-"`
   963  	// NullFields is a list of field names (e.g. "DatabaseType") to include in API
   964  	// requests with the JSON null value. By default, fields with empty values are
   965  	// omitted from API requests. See
   966  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   967  	NullFields []string `json:"-"`
   968  }
   969  
   970  func (s *DatabaseDump) MarshalJSON() ([]byte, error) {
   971  	type NoMethod DatabaseDump
   972  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   973  }
   974  
   975  // DataplexConfig: Specifies how metastore metadata should be integrated with
   976  // the Dataplex service.
   977  type DataplexConfig struct {
   978  	// LakeResources: A reference to the Lake resources that this metastore service
   979  	// is attached to. The key is the lake resource name. Example:
   980  	// projects/{project_number}/locations/{location_id}/lakes/{lake_id}.
   981  	LakeResources map[string]Lake `json:"lakeResources,omitempty"`
   982  	// ForceSendFields is a list of field names (e.g. "LakeResources") to
   983  	// unconditionally include in API requests. By default, fields with empty or
   984  	// default values are omitted from API requests. See
   985  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   986  	// details.
   987  	ForceSendFields []string `json:"-"`
   988  	// NullFields is a list of field names (e.g. "LakeResources") to include in API
   989  	// requests with the JSON null value. By default, fields with empty values are
   990  	// omitted from API requests. See
   991  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   992  	NullFields []string `json:"-"`
   993  }
   994  
   995  func (s *DataplexConfig) MarshalJSON() ([]byte, error) {
   996  	type NoMethod DataplexConfig
   997  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   998  }
   999  
  1000  // Empty: A generic empty message that you can re-use to avoid defining
  1001  // duplicated empty messages in your APIs. A typical example is to use it as
  1002  // the request or the response type of an API method. For instance: service Foo
  1003  // { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
  1004  type Empty struct {
  1005  	// ServerResponse contains the HTTP response code and headers from the server.
  1006  	googleapi.ServerResponse `json:"-"`
  1007  }
  1008  
  1009  // EncryptionConfig: Encryption settings for the service.
  1010  type EncryptionConfig struct {
  1011  	// KmsKey: The fully qualified customer provided Cloud KMS key name to use for
  1012  	// customer data encryption, in the following
  1013  	// format:projects/{project_number}/locations/{location_id}/keyRings/{key_ring_i
  1014  	// d}/cryptoKeys/{crypto_key_id}.
  1015  	KmsKey string `json:"kmsKey,omitempty"`
  1016  	// ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally
  1017  	// include in API requests. By default, fields with empty or default values are
  1018  	// omitted from API requests. See
  1019  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1020  	// details.
  1021  	ForceSendFields []string `json:"-"`
  1022  	// NullFields is a list of field names (e.g. "KmsKey") to include in API
  1023  	// requests with the JSON null value. By default, fields with empty values are
  1024  	// omitted from API requests. See
  1025  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1026  	NullFields []string `json:"-"`
  1027  }
  1028  
  1029  func (s *EncryptionConfig) MarshalJSON() ([]byte, error) {
  1030  	type NoMethod EncryptionConfig
  1031  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1032  }
  1033  
  1034  // ErrorDetails: Error details in public error message for
  1035  // DataprocMetastore.QueryMetadata.
  1036  type ErrorDetails struct {
  1037  	// Details: Additional structured details about this error.Keys define the
  1038  	// failure items. Value describes the exception or details of the item.
  1039  	Details map[string]string `json:"details,omitempty"`
  1040  	// ForceSendFields is a list of field names (e.g. "Details") to unconditionally
  1041  	// include in API requests. By default, fields with empty or default values are
  1042  	// omitted from API requests. See
  1043  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1044  	// details.
  1045  	ForceSendFields []string `json:"-"`
  1046  	// NullFields is a list of field names (e.g. "Details") to include in API
  1047  	// requests with the JSON null value. By default, fields with empty values are
  1048  	// omitted from API requests. See
  1049  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1050  	NullFields []string `json:"-"`
  1051  }
  1052  
  1053  func (s *ErrorDetails) MarshalJSON() ([]byte, error) {
  1054  	type NoMethod ErrorDetails
  1055  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1056  }
  1057  
  1058  // ExportMetadataRequest: Request message for DataprocMetastore.ExportMetadata.
  1059  type ExportMetadataRequest struct {
  1060  	// DatabaseDumpType: Optional. The type of the database dump. If unspecified,
  1061  	// defaults to MYSQL.
  1062  	//
  1063  	// Possible values:
  1064  	//   "TYPE_UNSPECIFIED" - The type of the database dump is unknown.
  1065  	//   "MYSQL" - Database dump is a MySQL dump file.
  1066  	//   "AVRO" - Database dump contains Avro files.
  1067  	DatabaseDumpType string `json:"databaseDumpType,omitempty"`
  1068  	// DestinationGcsFolder: A Cloud Storage URI of a folder, in the format gs:///.
  1069  	// A sub-folder containing exported files will be created below it.
  1070  	DestinationGcsFolder string `json:"destinationGcsFolder,omitempty"`
  1071  	// RequestId: Optional. A request ID. Specify a unique request ID to allow the
  1072  	// server to ignore the request if it has completed. The server will ignore
  1073  	// subsequent requests that provide a duplicate request ID for at least 60
  1074  	// minutes after the first request.For example, if an initial request times
  1075  	// out, followed by another request with the same request ID, the server
  1076  	// ignores the second request to prevent the creation of duplicate
  1077  	// commitments.The request ID must be a valid UUID
  1078  	// (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format). A zero
  1079  	// UUID (00000000-0000-0000-0000-000000000000) is not supported.
  1080  	RequestId string `json:"requestId,omitempty"`
  1081  	// ForceSendFields is a list of field names (e.g. "DatabaseDumpType") to
  1082  	// unconditionally include in API requests. By default, fields with empty or
  1083  	// default values are omitted from API requests. See
  1084  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1085  	// details.
  1086  	ForceSendFields []string `json:"-"`
  1087  	// NullFields is a list of field names (e.g. "DatabaseDumpType") to include in
  1088  	// API requests with the JSON null value. By default, fields with empty values
  1089  	// are omitted from API requests. See
  1090  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1091  	NullFields []string `json:"-"`
  1092  }
  1093  
  1094  func (s *ExportMetadataRequest) MarshalJSON() ([]byte, error) {
  1095  	type NoMethod ExportMetadataRequest
  1096  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1097  }
  1098  
  1099  // Expr: Represents a textual expression in the Common Expression Language
  1100  // (CEL) syntax. CEL is a C-like expression language. The syntax and semantics
  1101  // of CEL are documented at https://github.com/google/cel-spec.Example
  1102  // (Comparison): title: "Summary size limit" description: "Determines if a
  1103  // summary is less than 100 chars" expression: "document.summary.size() < 100"
  1104  // Example (Equality): title: "Requestor is owner" description: "Determines if
  1105  // requestor is the document owner" expression: "document.owner ==
  1106  // request.auth.claims.email" Example (Logic): title: "Public documents"
  1107  // description: "Determine whether the document should be publicly visible"
  1108  // expression: "document.type != 'private' && document.type != 'internal'"
  1109  // Example (Data Manipulation): title: "Notification string" description:
  1110  // "Create a notification string with a timestamp." expression: "'New message
  1111  // received at ' + string(document.create_time)" The exact variables and
  1112  // functions that may be referenced within an expression are determined by the
  1113  // service that evaluates it. See the service documentation for additional
  1114  // information.
  1115  type Expr struct {
  1116  	// Description: Optional. Description of the expression. This is a longer text
  1117  	// which describes the expression, e.g. when hovered over it in a UI.
  1118  	Description string `json:"description,omitempty"`
  1119  	// Expression: Textual representation of an expression in Common Expression
  1120  	// Language syntax.
  1121  	Expression string `json:"expression,omitempty"`
  1122  	// Location: Optional. String indicating the location of the expression for
  1123  	// error reporting, e.g. a file name and a position in the file.
  1124  	Location string `json:"location,omitempty"`
  1125  	// Title: Optional. Title for the expression, i.e. a short string describing
  1126  	// its purpose. This can be used e.g. in UIs which allow to enter the
  1127  	// expression.
  1128  	Title string `json:"title,omitempty"`
  1129  	// ForceSendFields is a list of field names (e.g. "Description") to
  1130  	// unconditionally include in API requests. By default, fields with empty or
  1131  	// default values are omitted from API requests. See
  1132  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1133  	// details.
  1134  	ForceSendFields []string `json:"-"`
  1135  	// NullFields is a list of field names (e.g. "Description") to include in API
  1136  	// requests with the JSON null value. By default, fields with empty values are
  1137  	// omitted from API requests. See
  1138  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1139  	NullFields []string `json:"-"`
  1140  }
  1141  
  1142  func (s *Expr) MarshalJSON() ([]byte, error) {
  1143  	type NoMethod Expr
  1144  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1145  }
  1146  
  1147  // Federation: Represents a federation of multiple backend metastores.
  1148  type Federation struct {
  1149  	// BackendMetastores: A map from BackendMetastore rank to BackendMetastores
  1150  	// from which the federation service serves metadata at query time. The map key
  1151  	// represents the order in which BackendMetastores should be evaluated to
  1152  	// resolve database names at query time and should be greater than or equal to
  1153  	// zero. A BackendMetastore with a lower number will be evaluated before a
  1154  	// BackendMetastore with a higher number.
  1155  	BackendMetastores map[string]BackendMetastore `json:"backendMetastores,omitempty"`
  1156  	// CreateTime: Output only. The time when the metastore federation was created.
  1157  	CreateTime string `json:"createTime,omitempty"`
  1158  	// EndpointUri: Output only. The federation endpoint.
  1159  	EndpointUri string `json:"endpointUri,omitempty"`
  1160  	// Labels: User-defined labels for the metastore federation.
  1161  	Labels map[string]string `json:"labels,omitempty"`
  1162  	// Name: Immutable. The relative resource name of the federation, of the form:
  1163  	// projects/{project_number}/locations/{location_id}/federations/{federation_id}
  1164  	// `.
  1165  	Name string `json:"name,omitempty"`
  1166  	// State: Output only. The current state of the federation.
  1167  	//
  1168  	// Possible values:
  1169  	//   "STATE_UNSPECIFIED" - The state of the metastore federation is unknown.
  1170  	//   "CREATING" - The metastore federation is in the process of being created.
  1171  	//   "ACTIVE" - The metastore federation is running and ready to serve queries.
  1172  	//   "UPDATING" - The metastore federation is being updated. It remains usable
  1173  	// but cannot accept additional update requests or be deleted at this time.
  1174  	//   "DELETING" - The metastore federation is undergoing deletion. It cannot be
  1175  	// used.
  1176  	//   "ERROR" - The metastore federation has encountered an error and cannot be
  1177  	// used. The metastore federation should be deleted.
  1178  	State string `json:"state,omitempty"`
  1179  	// StateMessage: Output only. Additional information about the current state of
  1180  	// the metastore federation, if available.
  1181  	StateMessage string `json:"stateMessage,omitempty"`
  1182  	// Uid: Output only. The globally unique resource identifier of the metastore
  1183  	// federation.
  1184  	Uid string `json:"uid,omitempty"`
  1185  	// UpdateTime: Output only. The time when the metastore federation was last
  1186  	// updated.
  1187  	UpdateTime string `json:"updateTime,omitempty"`
  1188  	// Version: Immutable. The Apache Hive metastore version of the federation. All
  1189  	// backend metastore versions must be compatible with the federation version.
  1190  	Version string `json:"version,omitempty"`
  1191  
  1192  	// ServerResponse contains the HTTP response code and headers from the server.
  1193  	googleapi.ServerResponse `json:"-"`
  1194  	// ForceSendFields is a list of field names (e.g. "BackendMetastores") to
  1195  	// unconditionally include in API requests. By default, fields with empty or
  1196  	// default values are omitted from API requests. See
  1197  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1198  	// details.
  1199  	ForceSendFields []string `json:"-"`
  1200  	// NullFields is a list of field names (e.g. "BackendMetastores") to include in
  1201  	// API requests with the JSON null value. By default, fields with empty values
  1202  	// are omitted from API requests. See
  1203  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1204  	NullFields []string `json:"-"`
  1205  }
  1206  
  1207  func (s *Federation) MarshalJSON() ([]byte, error) {
  1208  	type NoMethod Federation
  1209  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1210  }
  1211  
  1212  // HiveMetastoreConfig: Specifies configuration information specific to running
  1213  // Hive metastore software as the metastore service.
  1214  type HiveMetastoreConfig struct {
  1215  	// AuxiliaryVersions: A mapping of Hive metastore version to the auxiliary
  1216  	// version configuration. When specified, a secondary Hive metastore service is
  1217  	// created along with the primary service. All auxiliary versions must be less
  1218  	// than the service's primary version. The key is the auxiliary service name
  1219  	// and it must match the regular expression a-z?. This means that the first
  1220  	// character must be a lowercase letter, and all the following characters must
  1221  	// be hyphens, lowercase letters, or digits, except the last character, which
  1222  	// cannot be a hyphen.
  1223  	AuxiliaryVersions map[string]AuxiliaryVersionConfig `json:"auxiliaryVersions,omitempty"`
  1224  	// ConfigOverrides: A mapping of Hive metastore configuration key-value pairs
  1225  	// to apply to the Hive metastore (configured in hive-site.xml). The mappings
  1226  	// override system defaults (some keys cannot be overridden). These overrides
  1227  	// are also applied to auxiliary versions and can be further customized in the
  1228  	// auxiliary version's AuxiliaryVersionConfig.
  1229  	ConfigOverrides map[string]string `json:"configOverrides,omitempty"`
  1230  	// EndpointProtocol: The protocol to use for the metastore service endpoint. If
  1231  	// unspecified, defaults to THRIFT.
  1232  	//
  1233  	// Possible values:
  1234  	//   "ENDPOINT_PROTOCOL_UNSPECIFIED" - The protocol is not set.
  1235  	//   "THRIFT" - Use the legacy Apache Thrift protocol for the metastore service
  1236  	// endpoint.
  1237  	//   "GRPC" - Use the modernized gRPC protocol for the metastore service
  1238  	// endpoint.
  1239  	EndpointProtocol string `json:"endpointProtocol,omitempty"`
  1240  	// KerberosConfig: Information used to configure the Hive metastore service as
  1241  	// a service principal in a Kerberos realm. To disable Kerberos, use the
  1242  	// UpdateService method and specify this field's path
  1243  	// (hive_metastore_config.kerberos_config) in the request's update_mask while
  1244  	// omitting this field from the request's service.
  1245  	KerberosConfig *KerberosConfig `json:"kerberosConfig,omitempty"`
  1246  	// Version: Immutable. The Hive metastore schema version.
  1247  	Version string `json:"version,omitempty"`
  1248  	// ForceSendFields is a list of field names (e.g. "AuxiliaryVersions") to
  1249  	// unconditionally include in API requests. By default, fields with empty or
  1250  	// default values are omitted from API requests. See
  1251  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1252  	// details.
  1253  	ForceSendFields []string `json:"-"`
  1254  	// NullFields is a list of field names (e.g. "AuxiliaryVersions") to include in
  1255  	// API requests with the JSON null value. By default, fields with empty values
  1256  	// are omitted from API requests. See
  1257  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1258  	NullFields []string `json:"-"`
  1259  }
  1260  
  1261  func (s *HiveMetastoreConfig) MarshalJSON() ([]byte, error) {
  1262  	type NoMethod HiveMetastoreConfig
  1263  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1264  }
  1265  
  1266  // HiveMetastoreVersion: A specification of a supported version of the Hive
  1267  // Metastore software.
  1268  type HiveMetastoreVersion struct {
  1269  	// IsDefault: Whether version will be chosen by the server if a metastore
  1270  	// service is created with a HiveMetastoreConfig that omits the version.
  1271  	IsDefault bool `json:"isDefault,omitempty"`
  1272  	// Version: The semantic version of the Hive Metastore software.
  1273  	Version string `json:"version,omitempty"`
  1274  	// ForceSendFields is a list of field names (e.g. "IsDefault") to
  1275  	// unconditionally include in API requests. By default, fields with empty or
  1276  	// default values are omitted from API requests. See
  1277  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1278  	// details.
  1279  	ForceSendFields []string `json:"-"`
  1280  	// NullFields is a list of field names (e.g. "IsDefault") to include in API
  1281  	// requests with the JSON null value. By default, fields with empty values are
  1282  	// omitted from API requests. See
  1283  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1284  	NullFields []string `json:"-"`
  1285  }
  1286  
  1287  func (s *HiveMetastoreVersion) MarshalJSON() ([]byte, error) {
  1288  	type NoMethod HiveMetastoreVersion
  1289  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1290  }
  1291  
  1292  // KerberosConfig: Configuration information for a Kerberos principal.
  1293  type KerberosConfig struct {
  1294  	// Keytab: A Kerberos keytab file that can be used to authenticate a service
  1295  	// principal with a Kerberos Key Distribution Center (KDC).
  1296  	Keytab *Secret `json:"keytab,omitempty"`
  1297  	// Krb5ConfigGcsUri: A Cloud Storage URI that specifies the path to a krb5.conf
  1298  	// file. It is of the form gs://{bucket_name}/path/to/krb5.conf, although the
  1299  	// file does not need to be named krb5.conf explicitly.
  1300  	Krb5ConfigGcsUri string `json:"krb5ConfigGcsUri,omitempty"`
  1301  	// Principal: A Kerberos principal that exists in the both the keytab the KDC
  1302  	// to authenticate as. A typical principal is of the form
  1303  	// primary/instance@REALM, but there is no exact format.
  1304  	Principal string `json:"principal,omitempty"`
  1305  	// ForceSendFields is a list of field names (e.g. "Keytab") to unconditionally
  1306  	// include in API requests. By default, fields with empty or default values are
  1307  	// omitted from API requests. See
  1308  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1309  	// details.
  1310  	ForceSendFields []string `json:"-"`
  1311  	// NullFields is a list of field names (e.g. "Keytab") to include in API
  1312  	// requests with the JSON null value. By default, fields with empty values are
  1313  	// omitted from API requests. See
  1314  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1315  	NullFields []string `json:"-"`
  1316  }
  1317  
  1318  func (s *KerberosConfig) MarshalJSON() ([]byte, error) {
  1319  	type NoMethod KerberosConfig
  1320  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1321  }
  1322  
  1323  // Lake: Represents a Lake resource
  1324  type Lake struct {
  1325  	// Name: The Lake resource name. Example:
  1326  	// projects/{project_number}/locations/{location_id}/lakes/{lake_id}
  1327  	Name string `json:"name,omitempty"`
  1328  	// ForceSendFields is a list of field names (e.g. "Name") to unconditionally
  1329  	// include in API requests. By default, fields with empty or default values are
  1330  	// omitted from API requests. See
  1331  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1332  	// details.
  1333  	ForceSendFields []string `json:"-"`
  1334  	// NullFields is a list of field names (e.g. "Name") to include in API requests
  1335  	// with the JSON null value. By default, fields with empty values are omitted
  1336  	// from API requests. See
  1337  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1338  	NullFields []string `json:"-"`
  1339  }
  1340  
  1341  func (s *Lake) MarshalJSON() ([]byte, error) {
  1342  	type NoMethod Lake
  1343  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1344  }
  1345  
  1346  // LatestBackup: The details of the latest scheduled backup.
  1347  type LatestBackup struct {
  1348  	// BackupId: Output only. The ID of an in-progress scheduled backup. Empty if
  1349  	// no backup is in progress.
  1350  	BackupId string `json:"backupId,omitempty"`
  1351  	// Duration: Output only. The duration of the backup completion.
  1352  	Duration string `json:"duration,omitempty"`
  1353  	// StartTime: Output only. The time when the backup was started.
  1354  	StartTime string `json:"startTime,omitempty"`
  1355  	// State: Output only. The current state of the backup.
  1356  	//
  1357  	// Possible values:
  1358  	//   "STATE_UNSPECIFIED" - The state of the backup is unknown.
  1359  	//   "IN_PROGRESS" - The backup is in progress.
  1360  	//   "SUCCEEDED" - The backup completed.
  1361  	//   "FAILED" - The backup failed.
  1362  	State string `json:"state,omitempty"`
  1363  	// ForceSendFields is a list of field names (e.g. "BackupId") to
  1364  	// unconditionally include in API requests. By default, fields with empty or
  1365  	// default values are omitted from API requests. See
  1366  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1367  	// details.
  1368  	ForceSendFields []string `json:"-"`
  1369  	// NullFields is a list of field names (e.g. "BackupId") to include in API
  1370  	// requests with the JSON null value. By default, fields with empty values are
  1371  	// omitted from API requests. See
  1372  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1373  	NullFields []string `json:"-"`
  1374  }
  1375  
  1376  func (s *LatestBackup) MarshalJSON() ([]byte, error) {
  1377  	type NoMethod LatestBackup
  1378  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1379  }
  1380  
  1381  // LimitConfig: Represents the autoscaling limit configuration of a metastore
  1382  // service.
  1383  type LimitConfig struct {
  1384  	// MaxScalingFactor: Optional. The highest scaling factor that the service
  1385  	// should be autoscaled to.
  1386  	MaxScalingFactor float64 `json:"maxScalingFactor,omitempty"`
  1387  	// MinScalingFactor: Optional. The lowest scaling factor that the service
  1388  	// should be autoscaled to.
  1389  	MinScalingFactor float64 `json:"minScalingFactor,omitempty"`
  1390  	// ForceSendFields is a list of field names (e.g. "MaxScalingFactor") to
  1391  	// unconditionally include in API requests. By default, fields with empty or
  1392  	// default values are omitted from API requests. See
  1393  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1394  	// details.
  1395  	ForceSendFields []string `json:"-"`
  1396  	// NullFields is a list of field names (e.g. "MaxScalingFactor") to include in
  1397  	// API requests with the JSON null value. By default, fields with empty values
  1398  	// are omitted from API requests. See
  1399  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1400  	NullFields []string `json:"-"`
  1401  }
  1402  
  1403  func (s *LimitConfig) MarshalJSON() ([]byte, error) {
  1404  	type NoMethod LimitConfig
  1405  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1406  }
  1407  
  1408  func (s *LimitConfig) UnmarshalJSON(data []byte) error {
  1409  	type NoMethod LimitConfig
  1410  	var s1 struct {
  1411  		MaxScalingFactor gensupport.JSONFloat64 `json:"maxScalingFactor"`
  1412  		MinScalingFactor gensupport.JSONFloat64 `json:"minScalingFactor"`
  1413  		*NoMethod
  1414  	}
  1415  	s1.NoMethod = (*NoMethod)(s)
  1416  	if err := json.Unmarshal(data, &s1); err != nil {
  1417  		return err
  1418  	}
  1419  	s.MaxScalingFactor = float64(s1.MaxScalingFactor)
  1420  	s.MinScalingFactor = float64(s1.MinScalingFactor)
  1421  	return nil
  1422  }
  1423  
  1424  // ListBackupsResponse: Response message for DataprocMetastore.ListBackups.
  1425  type ListBackupsResponse struct {
  1426  	// Backups: The backups of the specified service.
  1427  	Backups []*Backup `json:"backups,omitempty"`
  1428  	// NextPageToken: A token that can be sent as page_token to retrieve the next
  1429  	// page. If this field is omitted, there are no subsequent pages.
  1430  	NextPageToken string `json:"nextPageToken,omitempty"`
  1431  	// Unreachable: Locations that could not be reached.
  1432  	Unreachable []string `json:"unreachable,omitempty"`
  1433  
  1434  	// ServerResponse contains the HTTP response code and headers from the server.
  1435  	googleapi.ServerResponse `json:"-"`
  1436  	// ForceSendFields is a list of field names (e.g. "Backups") to unconditionally
  1437  	// include in API requests. By default, fields with empty or default values are
  1438  	// omitted from API requests. See
  1439  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1440  	// details.
  1441  	ForceSendFields []string `json:"-"`
  1442  	// NullFields is a list of field names (e.g. "Backups") to include in API
  1443  	// requests with the JSON null value. By default, fields with empty values are
  1444  	// omitted from API requests. See
  1445  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1446  	NullFields []string `json:"-"`
  1447  }
  1448  
  1449  func (s *ListBackupsResponse) MarshalJSON() ([]byte, error) {
  1450  	type NoMethod ListBackupsResponse
  1451  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1452  }
  1453  
  1454  // ListFederationsResponse: Response message for ListFederations
  1455  type ListFederationsResponse struct {
  1456  	// Federations: The services in the specified location.
  1457  	Federations []*Federation `json:"federations,omitempty"`
  1458  	// NextPageToken: A token that can be sent as page_token to retrieve the next
  1459  	// page. If this field is omitted, there are no subsequent pages.
  1460  	NextPageToken string `json:"nextPageToken,omitempty"`
  1461  	// Unreachable: Locations that could not be reached.
  1462  	Unreachable []string `json:"unreachable,omitempty"`
  1463  
  1464  	// ServerResponse contains the HTTP response code and headers from the server.
  1465  	googleapi.ServerResponse `json:"-"`
  1466  	// ForceSendFields is a list of field names (e.g. "Federations") to
  1467  	// unconditionally include in API requests. By default, fields with empty or
  1468  	// default values are omitted from API requests. See
  1469  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1470  	// details.
  1471  	ForceSendFields []string `json:"-"`
  1472  	// NullFields is a list of field names (e.g. "Federations") to include in API
  1473  	// requests with the JSON null value. By default, fields with empty values are
  1474  	// omitted from API requests. See
  1475  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1476  	NullFields []string `json:"-"`
  1477  }
  1478  
  1479  func (s *ListFederationsResponse) MarshalJSON() ([]byte, error) {
  1480  	type NoMethod ListFederationsResponse
  1481  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1482  }
  1483  
  1484  // ListLocationsResponse: The response message for Locations.ListLocations.
  1485  type ListLocationsResponse struct {
  1486  	// Locations: A list of locations that matches the specified filter in the
  1487  	// request.
  1488  	Locations []*Location `json:"locations,omitempty"`
  1489  	// NextPageToken: The standard List next-page token.
  1490  	NextPageToken string `json:"nextPageToken,omitempty"`
  1491  
  1492  	// ServerResponse contains the HTTP response code and headers from the server.
  1493  	googleapi.ServerResponse `json:"-"`
  1494  	// ForceSendFields is a list of field names (e.g. "Locations") to
  1495  	// unconditionally include in API requests. By default, fields with empty or
  1496  	// default values are omitted from API requests. See
  1497  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1498  	// details.
  1499  	ForceSendFields []string `json:"-"`
  1500  	// NullFields is a list of field names (e.g. "Locations") to include in API
  1501  	// requests with the JSON null value. By default, fields with empty values are
  1502  	// omitted from API requests. See
  1503  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1504  	NullFields []string `json:"-"`
  1505  }
  1506  
  1507  func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) {
  1508  	type NoMethod ListLocationsResponse
  1509  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1510  }
  1511  
  1512  // ListMetadataImportsResponse: Response message for
  1513  // DataprocMetastore.ListMetadataImports.
  1514  type ListMetadataImportsResponse struct {
  1515  	// MetadataImports: The imports in the specified service.
  1516  	MetadataImports []*MetadataImport `json:"metadataImports,omitempty"`
  1517  	// NextPageToken: A token that can be sent as page_token to retrieve the next
  1518  	// page. If this field is omitted, there are no subsequent pages.
  1519  	NextPageToken string `json:"nextPageToken,omitempty"`
  1520  	// Unreachable: Locations that could not be reached.
  1521  	Unreachable []string `json:"unreachable,omitempty"`
  1522  
  1523  	// ServerResponse contains the HTTP response code and headers from the server.
  1524  	googleapi.ServerResponse `json:"-"`
  1525  	// ForceSendFields is a list of field names (e.g. "MetadataImports") to
  1526  	// unconditionally include in API requests. By default, fields with empty or
  1527  	// default values are omitted from API requests. See
  1528  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1529  	// details.
  1530  	ForceSendFields []string `json:"-"`
  1531  	// NullFields is a list of field names (e.g. "MetadataImports") to include in
  1532  	// API requests with the JSON null value. By default, fields with empty values
  1533  	// are omitted from API requests. See
  1534  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1535  	NullFields []string `json:"-"`
  1536  }
  1537  
  1538  func (s *ListMetadataImportsResponse) MarshalJSON() ([]byte, error) {
  1539  	type NoMethod ListMetadataImportsResponse
  1540  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1541  }
  1542  
  1543  // ListMigrationExecutionsResponse: Response message for
  1544  // DataprocMetastore.ListMigrationExecutions.
  1545  type ListMigrationExecutionsResponse struct {
  1546  	// MigrationExecutions: The migration executions on the specified service.
  1547  	MigrationExecutions []*MigrationExecution `json:"migrationExecutions,omitempty"`
  1548  	// NextPageToken: A token that can be sent as page_token to retrieve the next
  1549  	// page. If this field is omitted, there are no subsequent pages.
  1550  	NextPageToken string `json:"nextPageToken,omitempty"`
  1551  	// Unreachable: Locations that could not be reached.
  1552  	Unreachable []string `json:"unreachable,omitempty"`
  1553  
  1554  	// ServerResponse contains the HTTP response code and headers from the server.
  1555  	googleapi.ServerResponse `json:"-"`
  1556  	// ForceSendFields is a list of field names (e.g. "MigrationExecutions") to
  1557  	// unconditionally include in API requests. By default, fields with empty or
  1558  	// default values are omitted from API requests. See
  1559  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1560  	// details.
  1561  	ForceSendFields []string `json:"-"`
  1562  	// NullFields is a list of field names (e.g. "MigrationExecutions") to include
  1563  	// in API requests with the JSON null value. By default, fields with empty
  1564  	// values are omitted from API requests. See
  1565  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1566  	NullFields []string `json:"-"`
  1567  }
  1568  
  1569  func (s *ListMigrationExecutionsResponse) MarshalJSON() ([]byte, error) {
  1570  	type NoMethod ListMigrationExecutionsResponse
  1571  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1572  }
  1573  
  1574  // ListOperationsResponse: The response message for Operations.ListOperations.
  1575  type ListOperationsResponse struct {
  1576  	// NextPageToken: The standard List next-page token.
  1577  	NextPageToken string `json:"nextPageToken,omitempty"`
  1578  	// Operations: A list of operations that matches the specified filter in the
  1579  	// request.
  1580  	Operations []*Operation `json:"operations,omitempty"`
  1581  
  1582  	// ServerResponse contains the HTTP response code and headers from the server.
  1583  	googleapi.ServerResponse `json:"-"`
  1584  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1585  	// unconditionally include in API requests. By default, fields with empty or
  1586  	// default values are omitted from API requests. See
  1587  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1588  	// details.
  1589  	ForceSendFields []string `json:"-"`
  1590  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1591  	// requests with the JSON null value. By default, fields with empty values are
  1592  	// omitted from API requests. See
  1593  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1594  	NullFields []string `json:"-"`
  1595  }
  1596  
  1597  func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
  1598  	type NoMethod ListOperationsResponse
  1599  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1600  }
  1601  
  1602  // ListServicesResponse: Response message for DataprocMetastore.ListServices.
  1603  type ListServicesResponse struct {
  1604  	// NextPageToken: A token that can be sent as page_token to retrieve the next
  1605  	// page. If this field is omitted, there are no subsequent pages.
  1606  	NextPageToken string `json:"nextPageToken,omitempty"`
  1607  	// Services: The services in the specified location.
  1608  	Services []*Service `json:"services,omitempty"`
  1609  	// Unreachable: Locations that could not be reached.
  1610  	Unreachable []string `json:"unreachable,omitempty"`
  1611  
  1612  	// ServerResponse contains the HTTP response code and headers from the server.
  1613  	googleapi.ServerResponse `json:"-"`
  1614  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1615  	// unconditionally include in API requests. By default, fields with empty or
  1616  	// default values are omitted from API requests. See
  1617  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1618  	// details.
  1619  	ForceSendFields []string `json:"-"`
  1620  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1621  	// requests with the JSON null value. By default, fields with empty values are
  1622  	// omitted from API requests. See
  1623  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1624  	NullFields []string `json:"-"`
  1625  }
  1626  
  1627  func (s *ListServicesResponse) MarshalJSON() ([]byte, error) {
  1628  	type NoMethod ListServicesResponse
  1629  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1630  }
  1631  
  1632  // Location: A resource that represents a Google Cloud location.
  1633  type Location struct {
  1634  	// DisplayName: The friendly name for this location, typically a nearby city
  1635  	// name. For example, "Tokyo".
  1636  	DisplayName string `json:"displayName,omitempty"`
  1637  	// Labels: Cross-service attributes for the location. For example
  1638  	// {"cloud.googleapis.com/region": "us-east1"}
  1639  	Labels map[string]string `json:"labels,omitempty"`
  1640  	// LocationId: The canonical id for this location. For example: "us-east1".
  1641  	LocationId string `json:"locationId,omitempty"`
  1642  	// Metadata: Service-specific metadata. For example the available capacity at
  1643  	// the given location.
  1644  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  1645  	// Name: Resource name for the location, which may vary between
  1646  	// implementations. For example: "projects/example-project/locations/us-east1"
  1647  	Name string `json:"name,omitempty"`
  1648  
  1649  	// ServerResponse contains the HTTP response code and headers from the server.
  1650  	googleapi.ServerResponse `json:"-"`
  1651  	// ForceSendFields is a list of field names (e.g. "DisplayName") to
  1652  	// unconditionally include in API requests. By default, fields with empty or
  1653  	// default values are omitted from API requests. See
  1654  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1655  	// details.
  1656  	ForceSendFields []string `json:"-"`
  1657  	// NullFields is a list of field names (e.g. "DisplayName") to include in API
  1658  	// requests with the JSON null value. By default, fields with empty values are
  1659  	// omitted from API requests. See
  1660  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1661  	NullFields []string `json:"-"`
  1662  }
  1663  
  1664  func (s *Location) MarshalJSON() ([]byte, error) {
  1665  	type NoMethod Location
  1666  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1667  }
  1668  
  1669  // LocationMetadata: Metadata about the service in a location.
  1670  type LocationMetadata struct {
  1671  	// MultiRegionMetadata: The multi-region metadata if the current region is a
  1672  	// multi-region.
  1673  	MultiRegionMetadata *MultiRegionMetadata `json:"multiRegionMetadata,omitempty"`
  1674  	// SupportedHiveMetastoreVersions: The versions of Hive Metastore that can be
  1675  	// used when creating a new metastore service in this location. The server
  1676  	// guarantees that exactly one HiveMetastoreVersion in the list will set
  1677  	// is_default.
  1678  	SupportedHiveMetastoreVersions []*HiveMetastoreVersion `json:"supportedHiveMetastoreVersions,omitempty"`
  1679  	// ForceSendFields is a list of field names (e.g. "MultiRegionMetadata") to
  1680  	// unconditionally include in API requests. By default, fields with empty or
  1681  	// default values are omitted from API requests. See
  1682  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1683  	// details.
  1684  	ForceSendFields []string `json:"-"`
  1685  	// NullFields is a list of field names (e.g. "MultiRegionMetadata") to include
  1686  	// in API requests with the JSON null value. By default, fields with empty
  1687  	// values are omitted from API requests. See
  1688  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1689  	NullFields []string `json:"-"`
  1690  }
  1691  
  1692  func (s *LocationMetadata) MarshalJSON() ([]byte, error) {
  1693  	type NoMethod LocationMetadata
  1694  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1695  }
  1696  
  1697  // MaintenanceWindow: Maintenance window. This specifies when Dataproc
  1698  // Metastore may perform system maintenance operation to the service.
  1699  type MaintenanceWindow struct {
  1700  	// DayOfWeek: The day of week, when the window starts.
  1701  	//
  1702  	// Possible values:
  1703  	//   "DAY_OF_WEEK_UNSPECIFIED" - The day of the week is unspecified.
  1704  	//   "MONDAY" - Monday
  1705  	//   "TUESDAY" - Tuesday
  1706  	//   "WEDNESDAY" - Wednesday
  1707  	//   "THURSDAY" - Thursday
  1708  	//   "FRIDAY" - Friday
  1709  	//   "SATURDAY" - Saturday
  1710  	//   "SUNDAY" - Sunday
  1711  	DayOfWeek string `json:"dayOfWeek,omitempty"`
  1712  	// HourOfDay: The hour of day (0-23) when the window starts.
  1713  	HourOfDay int64 `json:"hourOfDay,omitempty"`
  1714  	// ForceSendFields is a list of field names (e.g. "DayOfWeek") to
  1715  	// unconditionally include in API requests. By default, fields with empty or
  1716  	// default values are omitted from API requests. See
  1717  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1718  	// details.
  1719  	ForceSendFields []string `json:"-"`
  1720  	// NullFields is a list of field names (e.g. "DayOfWeek") to include in API
  1721  	// requests with the JSON null value. By default, fields with empty values are
  1722  	// omitted from API requests. See
  1723  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1724  	NullFields []string `json:"-"`
  1725  }
  1726  
  1727  func (s *MaintenanceWindow) MarshalJSON() ([]byte, error) {
  1728  	type NoMethod MaintenanceWindow
  1729  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1730  }
  1731  
  1732  // MetadataExport: The details of a metadata export operation.
  1733  type MetadataExport struct {
  1734  	// DatabaseDumpType: Output only. The type of the database dump.
  1735  	//
  1736  	// Possible values:
  1737  	//   "TYPE_UNSPECIFIED" - The type of the database dump is unknown.
  1738  	//   "MYSQL" - Database dump is a MySQL dump file.
  1739  	//   "AVRO" - Database dump contains Avro files.
  1740  	DatabaseDumpType string `json:"databaseDumpType,omitempty"`
  1741  	// DestinationGcsUri: Output only. A Cloud Storage URI of a folder that
  1742  	// metadata are exported to, in the form of gs:////, where is automatically
  1743  	// generated.
  1744  	DestinationGcsUri string `json:"destinationGcsUri,omitempty"`
  1745  	// EndTime: Output only. The time when the export ended.
  1746  	EndTime string `json:"endTime,omitempty"`
  1747  	// StartTime: Output only. The time when the export started.
  1748  	StartTime string `json:"startTime,omitempty"`
  1749  	// State: Output only. The current state of the export.
  1750  	//
  1751  	// Possible values:
  1752  	//   "STATE_UNSPECIFIED" - The state of the metadata export is unknown.
  1753  	//   "RUNNING" - The metadata export is running.
  1754  	//   "SUCCEEDED" - The metadata export completed successfully.
  1755  	//   "FAILED" - The metadata export failed.
  1756  	//   "CANCELLED" - The metadata export is cancelled.
  1757  	State string `json:"state,omitempty"`
  1758  	// ForceSendFields is a list of field names (e.g. "DatabaseDumpType") to
  1759  	// unconditionally include in API requests. By default, fields with empty or
  1760  	// default values are omitted from API requests. See
  1761  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1762  	// details.
  1763  	ForceSendFields []string `json:"-"`
  1764  	// NullFields is a list of field names (e.g. "DatabaseDumpType") to include in
  1765  	// API requests with the JSON null value. By default, fields with empty values
  1766  	// are omitted from API requests. See
  1767  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1768  	NullFields []string `json:"-"`
  1769  }
  1770  
  1771  func (s *MetadataExport) MarshalJSON() ([]byte, error) {
  1772  	type NoMethod MetadataExport
  1773  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1774  }
  1775  
  1776  // MetadataImport: A metastore resource that imports metadata.
  1777  type MetadataImport struct {
  1778  	// CreateTime: Output only. The time when the metadata import was started.
  1779  	CreateTime string `json:"createTime,omitempty"`
  1780  	// DatabaseDump: Immutable. A database dump from a pre-existing metastore's
  1781  	// database.
  1782  	DatabaseDump *DatabaseDump `json:"databaseDump,omitempty"`
  1783  	// Description: The description of the metadata import.
  1784  	Description string `json:"description,omitempty"`
  1785  	// EndTime: Output only. The time when the metadata import finished.
  1786  	EndTime string `json:"endTime,omitempty"`
  1787  	// Name: Immutable. The relative resource name of the metadata import, of the
  1788  	// form:projects/{project_number}/locations/{location_id}/services/{service_id}/
  1789  	// metadataImports/{metadata_import_id}.
  1790  	Name string `json:"name,omitempty"`
  1791  	// State: Output only. The current state of the metadata import.
  1792  	//
  1793  	// Possible values:
  1794  	//   "STATE_UNSPECIFIED" - The state of the metadata import is unknown.
  1795  	//   "RUNNING" - The metadata import is running.
  1796  	//   "SUCCEEDED" - The metadata import completed successfully.
  1797  	//   "UPDATING" - The metadata import is being updated.
  1798  	//   "FAILED" - The metadata import failed, and attempted metadata changes were
  1799  	// rolled back.
  1800  	State string `json:"state,omitempty"`
  1801  	// UpdateTime: Output only. The time when the metadata import was last updated.
  1802  	UpdateTime string `json:"updateTime,omitempty"`
  1803  
  1804  	// ServerResponse contains the HTTP response code and headers from the server.
  1805  	googleapi.ServerResponse `json:"-"`
  1806  	// ForceSendFields is a list of field names (e.g. "CreateTime") to
  1807  	// unconditionally include in API requests. By default, fields with empty or
  1808  	// default values are omitted from API requests. See
  1809  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1810  	// details.
  1811  	ForceSendFields []string `json:"-"`
  1812  	// NullFields is a list of field names (e.g. "CreateTime") to include in API
  1813  	// requests with the JSON null value. By default, fields with empty values are
  1814  	// omitted from API requests. See
  1815  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1816  	NullFields []string `json:"-"`
  1817  }
  1818  
  1819  func (s *MetadataImport) MarshalJSON() ([]byte, error) {
  1820  	type NoMethod MetadataImport
  1821  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1822  }
  1823  
  1824  // MetadataIntegration: Specifies how metastore metadata should be integrated
  1825  // with external services.
  1826  type MetadataIntegration struct {
  1827  	// DataCatalogConfig: Optional. The integration config for the Data Catalog
  1828  	// service.
  1829  	DataCatalogConfig *DataCatalogConfig `json:"dataCatalogConfig,omitempty"`
  1830  	// DataplexConfig: The integration config for the Dataplex service.
  1831  	DataplexConfig *DataplexConfig `json:"dataplexConfig,omitempty"`
  1832  	// ForceSendFields is a list of field names (e.g. "DataCatalogConfig") to
  1833  	// unconditionally include in API requests. By default, fields with empty or
  1834  	// default values are omitted from API requests. See
  1835  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1836  	// details.
  1837  	ForceSendFields []string `json:"-"`
  1838  	// NullFields is a list of field names (e.g. "DataCatalogConfig") to include in
  1839  	// API requests with the JSON null value. By default, fields with empty values
  1840  	// are omitted from API requests. See
  1841  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1842  	NullFields []string `json:"-"`
  1843  }
  1844  
  1845  func (s *MetadataIntegration) MarshalJSON() ([]byte, error) {
  1846  	type NoMethod MetadataIntegration
  1847  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1848  }
  1849  
  1850  // MetadataManagementActivity: The metadata management activities of the
  1851  // metastore service.
  1852  type MetadataManagementActivity struct {
  1853  	// MetadataExports: Output only. The latest metadata exports of the metastore
  1854  	// service.
  1855  	MetadataExports []*MetadataExport `json:"metadataExports,omitempty"`
  1856  	// Restores: Output only. The latest restores of the metastore service.
  1857  	Restores []*Restore `json:"restores,omitempty"`
  1858  	// ForceSendFields is a list of field names (e.g. "MetadataExports") to
  1859  	// unconditionally include in API requests. By default, fields with empty or
  1860  	// default values are omitted from API requests. See
  1861  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1862  	// details.
  1863  	ForceSendFields []string `json:"-"`
  1864  	// NullFields is a list of field names (e.g. "MetadataExports") to include in
  1865  	// API requests with the JSON null value. By default, fields with empty values
  1866  	// are omitted from API requests. See
  1867  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1868  	NullFields []string `json:"-"`
  1869  }
  1870  
  1871  func (s *MetadataManagementActivity) MarshalJSON() ([]byte, error) {
  1872  	type NoMethod MetadataManagementActivity
  1873  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1874  }
  1875  
  1876  // MigrationExecution: The details of a migration execution resource.
  1877  type MigrationExecution struct {
  1878  	// CloudSqlMigrationConfig: Configuration information specific to migrating
  1879  	// from self-managed hive metastore on Google Cloud using Cloud SQL as the
  1880  	// backend database to Dataproc Metastore.
  1881  	CloudSqlMigrationConfig *CloudSQLMigrationConfig `json:"cloudSqlMigrationConfig,omitempty"`
  1882  	// CreateTime: Output only. The time when the migration execution was started.
  1883  	CreateTime string `json:"createTime,omitempty"`
  1884  	// EndTime: Output only. The time when the migration execution finished.
  1885  	EndTime string `json:"endTime,omitempty"`
  1886  	// Name: Output only. The relative resource name of the migration execution, in
  1887  	// the following form:
  1888  	// projects/{project_number}/locations/{location_id}/services/{service_id}/migra
  1889  	// tionExecutions/{migration_execution_id}
  1890  	Name string `json:"name,omitempty"`
  1891  	// Phase: Output only. The current phase of the migration execution.
  1892  	//
  1893  	// Possible values:
  1894  	//   "PHASE_UNSPECIFIED" - The phase of the migration execution is unknown.
  1895  	//   "REPLICATION" - Replication phase refers to the migration phase when
  1896  	// Dataproc Metastore is running a pipeline to replicate changes in the
  1897  	// customer database to its backend database. During this phase, Dataproc
  1898  	// Metastore uses the customer database as the hive metastore backend database.
  1899  	//   "CUTOVER" - Cutover phase refers to the migration phase when Dataproc
  1900  	// Metastore switches to using its own backend database. Migration enters this
  1901  	// phase when customer is done migrating all their clusters/workloads to
  1902  	// Dataproc Metastore and triggers CompleteMigration.
  1903  	Phase string `json:"phase,omitempty"`
  1904  	// State: Output only. The current state of the migration execution.
  1905  	//
  1906  	// Possible values:
  1907  	//   "STATE_UNSPECIFIED" - The state of the migration execution is unknown.
  1908  	//   "STARTING" - The migration execution is starting.
  1909  	//   "RUNNING" - The migration execution is running.
  1910  	//   "CANCELLING" - The migration execution is in the process of being
  1911  	// cancelled.
  1912  	//   "AWAITING_USER_ACTION" - The migration execution is awaiting user action.
  1913  	//   "SUCCEEDED" - The migration execution has completed successfully.
  1914  	//   "FAILED" - The migration execution has failed.
  1915  	//   "CANCELLED" - The migration execution is cancelled.
  1916  	//   "DELETING" - The migration execution is being deleted.
  1917  	State string `json:"state,omitempty"`
  1918  	// StateMessage: Output only. Additional information about the current state of
  1919  	// the migration execution.
  1920  	StateMessage string `json:"stateMessage,omitempty"`
  1921  
  1922  	// ServerResponse contains the HTTP response code and headers from the server.
  1923  	googleapi.ServerResponse `json:"-"`
  1924  	// ForceSendFields is a list of field names (e.g. "CloudSqlMigrationConfig") to
  1925  	// unconditionally include in API requests. By default, fields with empty or
  1926  	// default values are omitted from API requests. See
  1927  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1928  	// details.
  1929  	ForceSendFields []string `json:"-"`
  1930  	// NullFields is a list of field names (e.g. "CloudSqlMigrationConfig") to
  1931  	// include in API requests with the JSON null value. By default, fields with
  1932  	// empty values are omitted from API requests. See
  1933  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1934  	NullFields []string `json:"-"`
  1935  }
  1936  
  1937  func (s *MigrationExecution) MarshalJSON() ([]byte, error) {
  1938  	type NoMethod MigrationExecution
  1939  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1940  }
  1941  
  1942  // MoveTableToDatabaseRequest: Request message for
  1943  // DataprocMetastore.MoveTableToDatabase.
  1944  type MoveTableToDatabaseRequest struct {
  1945  	// DbName: Required. The name of the database where the table resides.
  1946  	DbName string `json:"dbName,omitempty"`
  1947  	// DestinationDbName: Required. The name of the database where the table should
  1948  	// be moved.
  1949  	DestinationDbName string `json:"destinationDbName,omitempty"`
  1950  	// TableName: Required. The name of the table to be moved.
  1951  	TableName string `json:"tableName,omitempty"`
  1952  	// ForceSendFields is a list of field names (e.g. "DbName") to unconditionally
  1953  	// include in API requests. By default, fields with empty or default values are
  1954  	// omitted from API requests. See
  1955  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1956  	// details.
  1957  	ForceSendFields []string `json:"-"`
  1958  	// NullFields is a list of field names (e.g. "DbName") to include in API
  1959  	// requests with the JSON null value. By default, fields with empty values are
  1960  	// omitted from API requests. See
  1961  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1962  	NullFields []string `json:"-"`
  1963  }
  1964  
  1965  func (s *MoveTableToDatabaseRequest) MarshalJSON() ([]byte, error) {
  1966  	type NoMethod MoveTableToDatabaseRequest
  1967  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1968  }
  1969  
  1970  // MoveTableToDatabaseResponse: Response message for
  1971  // DataprocMetastore.MoveTableToDatabase.
  1972  type MoveTableToDatabaseResponse struct {
  1973  }
  1974  
  1975  // MultiRegionMetadata: The metadata for the multi-region that includes the
  1976  // constituent regions. The metadata is only populated if the region is
  1977  // multi-region. For single region, it will be empty.
  1978  type MultiRegionMetadata struct {
  1979  	// ConstituentRegions: The regions constituting the multi-region.
  1980  	ConstituentRegions []string `json:"constituentRegions,omitempty"`
  1981  	// ForceSendFields is a list of field names (e.g. "ConstituentRegions") to
  1982  	// unconditionally include in API requests. By default, fields with empty or
  1983  	// default values are omitted from API requests. See
  1984  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1985  	// details.
  1986  	ForceSendFields []string `json:"-"`
  1987  	// NullFields is a list of field names (e.g. "ConstituentRegions") to include
  1988  	// in API requests with the JSON null value. By default, fields with empty
  1989  	// values are omitted from API requests. See
  1990  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1991  	NullFields []string `json:"-"`
  1992  }
  1993  
  1994  func (s *MultiRegionMetadata) MarshalJSON() ([]byte, error) {
  1995  	type NoMethod MultiRegionMetadata
  1996  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1997  }
  1998  
  1999  // NetworkConfig: Network configuration for the Dataproc Metastore service.
  2000  type NetworkConfig struct {
  2001  	// Consumers: Immutable. The consumer-side network configuration for the
  2002  	// Dataproc Metastore instance.
  2003  	Consumers []*Consumer `json:"consumers,omitempty"`
  2004  	// CustomRoutesEnabled: Enables custom routes to be imported and exported for
  2005  	// the Dataproc Metastore service's peered VPC network.
  2006  	CustomRoutesEnabled bool `json:"customRoutesEnabled,omitempty"`
  2007  	// ForceSendFields is a list of field names (e.g. "Consumers") to
  2008  	// unconditionally include in API requests. By default, fields with empty or
  2009  	// default values are omitted from API requests. See
  2010  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2011  	// details.
  2012  	ForceSendFields []string `json:"-"`
  2013  	// NullFields is a list of field names (e.g. "Consumers") to include in API
  2014  	// requests with the JSON null value. By default, fields with empty values are
  2015  	// omitted from API requests. See
  2016  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2017  	NullFields []string `json:"-"`
  2018  }
  2019  
  2020  func (s *NetworkConfig) MarshalJSON() ([]byte, error) {
  2021  	type NoMethod NetworkConfig
  2022  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2023  }
  2024  
  2025  // Operation: This resource represents a long-running operation that is the
  2026  // result of a network API call.
  2027  type Operation struct {
  2028  	// Done: If the value is false, it means the operation is still in progress. If
  2029  	// true, the operation is completed, and either error or response is available.
  2030  	Done bool `json:"done,omitempty"`
  2031  	// Error: The error result of the operation in case of failure or cancellation.
  2032  	Error *Status `json:"error,omitempty"`
  2033  	// Metadata: Service-specific metadata associated with the operation. It
  2034  	// typically contains progress information and common metadata such as create
  2035  	// time. Some services might not provide such metadata. Any method that returns
  2036  	// a long-running operation should document the metadata type, if any.
  2037  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  2038  	// Name: The server-assigned name, which is only unique within the same service
  2039  	// that originally returns it. If you use the default HTTP mapping, the name
  2040  	// should be a resource name ending with operations/{unique_id}.
  2041  	Name string `json:"name,omitempty"`
  2042  	// Response: The normal, successful response of the operation. If the original
  2043  	// method returns no data on success, such as Delete, the response is
  2044  	// google.protobuf.Empty. If the original method is standard Get/Create/Update,
  2045  	// the response should be the resource. For other methods, the response should
  2046  	// have the type XxxResponse, where Xxx is the original method name. For
  2047  	// example, if the original method name is TakeSnapshot(), the inferred
  2048  	// response type is TakeSnapshotResponse.
  2049  	Response googleapi.RawMessage `json:"response,omitempty"`
  2050  
  2051  	// ServerResponse contains the HTTP response code and headers from the server.
  2052  	googleapi.ServerResponse `json:"-"`
  2053  	// ForceSendFields is a list of field names (e.g. "Done") to unconditionally
  2054  	// include in API requests. By default, fields with empty or default values are
  2055  	// omitted from API requests. See
  2056  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2057  	// details.
  2058  	ForceSendFields []string `json:"-"`
  2059  	// NullFields is a list of field names (e.g. "Done") to include in API requests
  2060  	// with the JSON null value. By default, fields with empty values are omitted
  2061  	// from API requests. See
  2062  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2063  	NullFields []string `json:"-"`
  2064  }
  2065  
  2066  func (s *Operation) MarshalJSON() ([]byte, error) {
  2067  	type NoMethod Operation
  2068  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2069  }
  2070  
  2071  // OperationMetadata: Represents the metadata of a long-running operation.
  2072  type OperationMetadata struct {
  2073  	// ApiVersion: Output only. API version used to start the operation.
  2074  	ApiVersion string `json:"apiVersion,omitempty"`
  2075  	// CreateTime: Output only. The time the operation was created.
  2076  	CreateTime string `json:"createTime,omitempty"`
  2077  	// EndTime: Output only. The time the operation finished running.
  2078  	EndTime string `json:"endTime,omitempty"`
  2079  	// RequestedCancellation: Output only. Identifies whether the caller has
  2080  	// requested cancellation of the operation. Operations that have successfully
  2081  	// been cancelled have Operation.error value with a google.rpc.Status.code of
  2082  	// 1, corresponding to Code.CANCELLED.
  2083  	RequestedCancellation bool `json:"requestedCancellation,omitempty"`
  2084  	// StatusMessage: Output only. Human-readable status of the operation, if any.
  2085  	StatusMessage string `json:"statusMessage,omitempty"`
  2086  	// Target: Output only. Server-defined resource path for the target of the
  2087  	// operation.
  2088  	Target string `json:"target,omitempty"`
  2089  	// Verb: Output only. Name of the verb executed by the operation.
  2090  	Verb string `json:"verb,omitempty"`
  2091  	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
  2092  	// unconditionally include in API requests. By default, fields with empty or
  2093  	// default values are omitted from API requests. See
  2094  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2095  	// details.
  2096  	ForceSendFields []string `json:"-"`
  2097  	// NullFields is a list of field names (e.g. "ApiVersion") to include in API
  2098  	// requests with the JSON null value. By default, fields with empty values are
  2099  	// omitted from API requests. See
  2100  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2101  	NullFields []string `json:"-"`
  2102  }
  2103  
  2104  func (s *OperationMetadata) MarshalJSON() ([]byte, error) {
  2105  	type NoMethod OperationMetadata
  2106  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2107  }
  2108  
  2109  // Policy: An Identity and Access Management (IAM) policy, which specifies
  2110  // access controls for Google Cloud resources.A Policy is a collection of
  2111  // bindings. A binding binds one or more members, or principals, to a single
  2112  // role. Principals can be user accounts, service accounts, Google groups, and
  2113  // domains (such as G Suite). A role is a named list of permissions; each role
  2114  // can be an IAM predefined role or a user-created custom role.For some types
  2115  // of Google Cloud resources, a binding can also specify a condition, which is
  2116  // a logical expression that allows access to a resource only if the expression
  2117  // evaluates to true. A condition can add constraints based on attributes of
  2118  // the request, the resource, or both. To learn which resources support
  2119  // conditions in their IAM policies, see the IAM documentation
  2120  // (https://cloud.google.com/iam/help/conditions/resource-policies).JSON
  2121  // example: { "bindings": [ { "role":
  2122  // "roles/resourcemanager.organizationAdmin", "members": [
  2123  // "user:mike@example.com", "group:admins@example.com", "domain:google.com",
  2124  // "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role":
  2125  // "roles/resourcemanager.organizationViewer", "members": [
  2126  // "user:eve@example.com" ], "condition": { "title": "expirable access",
  2127  // "description": "Does not grant access after Sep 2020", "expression":
  2128  // "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag":
  2129  // "BwWWja0YfJA=", "version": 3 } YAML example: bindings: - members: -
  2130  // user:mike@example.com - group:admins@example.com - domain:google.com -
  2131  // serviceAccount:my-project-id@appspot.gserviceaccount.com role:
  2132  // roles/resourcemanager.organizationAdmin - members: - user:eve@example.com
  2133  // role: roles/resourcemanager.organizationViewer condition: title: expirable
  2134  // access description: Does not grant access after Sep 2020 expression:
  2135  // request.time < timestamp('2020-10-01T00:00:00.000Z') etag: BwWWja0YfJA=
  2136  // version: 3 For a description of IAM and its features, see the IAM
  2137  // documentation (https://cloud.google.com/iam/docs/).
  2138  type Policy struct {
  2139  	// AuditConfigs: Specifies cloud audit logging configuration for this policy.
  2140  	AuditConfigs []*AuditConfig `json:"auditConfigs,omitempty"`
  2141  	// Bindings: Associates a list of members, or principals, with a role.
  2142  	// Optionally, may specify a condition that determines how and when the
  2143  	// bindings are applied. Each of the bindings must contain at least one
  2144  	// principal.The bindings in a Policy can refer to up to 1,500 principals; up
  2145  	// to 250 of these principals can be Google groups. Each occurrence of a
  2146  	// principal counts towards these limits. For example, if the bindings grant 50
  2147  	// different roles to user:alice@example.com, and not to any other principal,
  2148  	// then you can add another 1,450 principals to the bindings in the Policy.
  2149  	Bindings []*Binding `json:"bindings,omitempty"`
  2150  	// Etag: etag is used for optimistic concurrency control as a way to help
  2151  	// prevent simultaneous updates of a policy from overwriting each other. It is
  2152  	// strongly suggested that systems make use of the etag in the
  2153  	// read-modify-write cycle to perform policy updates in order to avoid race
  2154  	// conditions: An etag is returned in the response to getIamPolicy, and systems
  2155  	// are expected to put that etag in the request to setIamPolicy to ensure that
  2156  	// their change will be applied to the same version of the policy.Important: If
  2157  	// you use IAM Conditions, you must include the etag field whenever you call
  2158  	// setIamPolicy. If you omit this field, then IAM allows you to overwrite a
  2159  	// version 3 policy with a version 1 policy, and all of the conditions in the
  2160  	// version 3 policy are lost.
  2161  	Etag string `json:"etag,omitempty"`
  2162  	// Version: Specifies the format of the policy.Valid values are 0, 1, and 3.
  2163  	// Requests that specify an invalid value are rejected.Any operation that
  2164  	// affects conditional role bindings must specify version 3. This requirement
  2165  	// applies to the following operations: Getting a policy that includes a
  2166  	// conditional role binding Adding a conditional role binding to a policy
  2167  	// Changing a conditional role binding in a policy Removing any role binding,
  2168  	// with or without a condition, from a policy that includes
  2169  	// conditionsImportant: If you use IAM Conditions, you must include the etag
  2170  	// field whenever you call setIamPolicy. If you omit this field, then IAM
  2171  	// allows you to overwrite a version 3 policy with a version 1 policy, and all
  2172  	// of the conditions in the version 3 policy are lost.If a policy does not
  2173  	// include any conditions, operations on that policy may specify any valid
  2174  	// version or leave the field unset.To learn which resources support conditions
  2175  	// in their IAM policies, see the IAM documentation
  2176  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
  2177  	Version int64 `json:"version,omitempty"`
  2178  
  2179  	// ServerResponse contains the HTTP response code and headers from the server.
  2180  	googleapi.ServerResponse `json:"-"`
  2181  	// ForceSendFields is a list of field names (e.g. "AuditConfigs") to
  2182  	// unconditionally include in API requests. By default, fields with empty or
  2183  	// default values are omitted from API requests. See
  2184  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2185  	// details.
  2186  	ForceSendFields []string `json:"-"`
  2187  	// NullFields is a list of field names (e.g. "AuditConfigs") to include in API
  2188  	// requests with the JSON null value. By default, fields with empty values are
  2189  	// omitted from API requests. See
  2190  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2191  	NullFields []string `json:"-"`
  2192  }
  2193  
  2194  func (s *Policy) MarshalJSON() ([]byte, error) {
  2195  	type NoMethod Policy
  2196  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2197  }
  2198  
  2199  // QueryMetadataRequest: Request message for DataprocMetastore.QueryMetadata.
  2200  type QueryMetadataRequest struct {
  2201  	// Query: Required. A read-only SQL query to execute against the metadata
  2202  	// database. The query cannot change or mutate the data.
  2203  	Query string `json:"query,omitempty"`
  2204  	// ForceSendFields is a list of field names (e.g. "Query") to unconditionally
  2205  	// include in API requests. By default, fields with empty or default values are
  2206  	// omitted from API requests. See
  2207  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2208  	// details.
  2209  	ForceSendFields []string `json:"-"`
  2210  	// NullFields is a list of field names (e.g. "Query") to include in API
  2211  	// requests with the JSON null value. By default, fields with empty values are
  2212  	// omitted from API requests. See
  2213  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2214  	NullFields []string `json:"-"`
  2215  }
  2216  
  2217  func (s *QueryMetadataRequest) MarshalJSON() ([]byte, error) {
  2218  	type NoMethod QueryMetadataRequest
  2219  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2220  }
  2221  
  2222  // QueryMetadataResponse: Response message for DataprocMetastore.QueryMetadata.
  2223  type QueryMetadataResponse struct {
  2224  	// ResultManifestUri: The manifest URI is link to a JSON instance in Cloud
  2225  	// Storage. This instance manifests immediately along with
  2226  	// QueryMetadataResponse. The content of the URI is not retriable until the
  2227  	// long-running operation query against the metadata finishes.
  2228  	ResultManifestUri string `json:"resultManifestUri,omitempty"`
  2229  	// ForceSendFields is a list of field names (e.g. "ResultManifestUri") to
  2230  	// unconditionally include in API requests. By default, fields with empty or
  2231  	// default values are omitted from API requests. See
  2232  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2233  	// details.
  2234  	ForceSendFields []string `json:"-"`
  2235  	// NullFields is a list of field names (e.g. "ResultManifestUri") to include in
  2236  	// API requests with the JSON null value. By default, fields with empty values
  2237  	// are omitted from API requests. See
  2238  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2239  	NullFields []string `json:"-"`
  2240  }
  2241  
  2242  func (s *QueryMetadataResponse) MarshalJSON() ([]byte, error) {
  2243  	type NoMethod QueryMetadataResponse
  2244  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2245  }
  2246  
  2247  // RemoveIamPolicyRequest: Request message for
  2248  // DataprocMetastore.RemoveIamPolicy.
  2249  type RemoveIamPolicyRequest struct {
  2250  	// Asynchronous: Optional. Removes IAM policy attached to database or table
  2251  	// asynchronously when it is set. The default is false.
  2252  	Asynchronous bool `json:"asynchronous,omitempty"`
  2253  	// ForceSendFields is a list of field names (e.g. "Asynchronous") to
  2254  	// unconditionally include in API requests. By default, fields with empty or
  2255  	// default values are omitted from API requests. See
  2256  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2257  	// details.
  2258  	ForceSendFields []string `json:"-"`
  2259  	// NullFields is a list of field names (e.g. "Asynchronous") to include in API
  2260  	// requests with the JSON null value. By default, fields with empty values are
  2261  	// omitted from API requests. See
  2262  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2263  	NullFields []string `json:"-"`
  2264  }
  2265  
  2266  func (s *RemoveIamPolicyRequest) MarshalJSON() ([]byte, error) {
  2267  	type NoMethod RemoveIamPolicyRequest
  2268  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2269  }
  2270  
  2271  // RemoveIamPolicyResponse: Response message for
  2272  // DataprocMetastore.RemoveIamPolicy.
  2273  type RemoveIamPolicyResponse struct {
  2274  	// Success: True if the policy is successfully removed.
  2275  	Success bool `json:"success,omitempty"`
  2276  
  2277  	// ServerResponse contains the HTTP response code and headers from the server.
  2278  	googleapi.ServerResponse `json:"-"`
  2279  	// ForceSendFields is a list of field names (e.g. "Success") to unconditionally
  2280  	// include in API requests. By default, fields with empty or default values are
  2281  	// omitted from API requests. See
  2282  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2283  	// details.
  2284  	ForceSendFields []string `json:"-"`
  2285  	// NullFields is a list of field names (e.g. "Success") to include in API
  2286  	// requests with the JSON null value. By default, fields with empty values are
  2287  	// omitted from API requests. See
  2288  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2289  	NullFields []string `json:"-"`
  2290  }
  2291  
  2292  func (s *RemoveIamPolicyResponse) MarshalJSON() ([]byte, error) {
  2293  	type NoMethod RemoveIamPolicyResponse
  2294  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2295  }
  2296  
  2297  // Restore: The details of a metadata restore operation.
  2298  type Restore struct {
  2299  	// Backup: Output only. The relative resource name of the metastore service
  2300  	// backup to restore from, in the following
  2301  	// form:projects/{project_id}/locations/{location_id}/services/{service_id}/back
  2302  	// ups/{backup_id}.
  2303  	Backup string `json:"backup,omitempty"`
  2304  	// BackupLocation: Optional. A Cloud Storage URI specifying where the backup
  2305  	// artifacts are stored, in the format gs:///.
  2306  	BackupLocation string `json:"backupLocation,omitempty"`
  2307  	// Details: Output only. The restore details containing the revision of the
  2308  	// service to be restored to, in format of JSON.
  2309  	Details string `json:"details,omitempty"`
  2310  	// EndTime: Output only. The time when the restore ended.
  2311  	EndTime string `json:"endTime,omitempty"`
  2312  	// StartTime: Output only. The time when the restore started.
  2313  	StartTime string `json:"startTime,omitempty"`
  2314  	// State: Output only. The current state of the restore.
  2315  	//
  2316  	// Possible values:
  2317  	//   "STATE_UNSPECIFIED" - The state of the metadata restore is unknown.
  2318  	//   "RUNNING" - The metadata restore is running.
  2319  	//   "SUCCEEDED" - The metadata restore completed successfully.
  2320  	//   "FAILED" - The metadata restore failed.
  2321  	//   "CANCELLED" - The metadata restore is cancelled.
  2322  	State string `json:"state,omitempty"`
  2323  	// Type: Output only. The type of restore.
  2324  	//
  2325  	// Possible values:
  2326  	//   "RESTORE_TYPE_UNSPECIFIED" - The restore type is unknown.
  2327  	//   "FULL" - The service's metadata and configuration are restored.
  2328  	//   "METADATA_ONLY" - Only the service's metadata is restored.
  2329  	Type string `json:"type,omitempty"`
  2330  	// ForceSendFields is a list of field names (e.g. "Backup") to unconditionally
  2331  	// include in API requests. By default, fields with empty or default values are
  2332  	// omitted from API requests. See
  2333  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2334  	// details.
  2335  	ForceSendFields []string `json:"-"`
  2336  	// NullFields is a list of field names (e.g. "Backup") to include in API
  2337  	// requests with the JSON null value. By default, fields with empty values are
  2338  	// omitted from API requests. See
  2339  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2340  	NullFields []string `json:"-"`
  2341  }
  2342  
  2343  func (s *Restore) MarshalJSON() ([]byte, error) {
  2344  	type NoMethod Restore
  2345  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2346  }
  2347  
  2348  // RestoreServiceRequest: Request message for DataprocMetastore.Restore.
  2349  type RestoreServiceRequest struct {
  2350  	// Backup: Optional. The relative resource name of the metastore service backup
  2351  	// to restore from, in the following
  2352  	// form:projects/{project_id}/locations/{location_id}/services/{service_id}/back
  2353  	// ups/{backup_id}. Mutually exclusive with backup_location, and exactly one of
  2354  	// the two must be set.
  2355  	Backup string `json:"backup,omitempty"`
  2356  	// BackupLocation: Optional. A Cloud Storage URI specifying the location of the
  2357  	// backup artifacts, namely - backup avro files under "avro/",
  2358  	// backup_metastore.json and service.json, in the following form:gs://.
  2359  	// Mutually exclusive with backup, and exactly one of the two must be set.
  2360  	BackupLocation string `json:"backupLocation,omitempty"`
  2361  	// RequestId: Optional. A request ID. Specify a unique request ID to allow the
  2362  	// server to ignore the request if it has completed. The server will ignore
  2363  	// subsequent requests that provide a duplicate request ID for at least 60
  2364  	// minutes after the first request.For example, if an initial request times
  2365  	// out, followed by another request with the same request ID, the server
  2366  	// ignores the second request to prevent the creation of duplicate
  2367  	// commitments.The request ID must be a valid UUID
  2368  	// (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format). A zero
  2369  	// UUID (00000000-0000-0000-0000-000000000000) is not supported.
  2370  	RequestId string `json:"requestId,omitempty"`
  2371  	// RestoreType: Optional. The type of restore. If unspecified, defaults to
  2372  	// METADATA_ONLY.
  2373  	//
  2374  	// Possible values:
  2375  	//   "RESTORE_TYPE_UNSPECIFIED" - The restore type is unknown.
  2376  	//   "FULL" - The service's metadata and configuration are restored.
  2377  	//   "METADATA_ONLY" - Only the service's metadata is restored.
  2378  	RestoreType string `json:"restoreType,omitempty"`
  2379  	// ForceSendFields is a list of field names (e.g. "Backup") to unconditionally
  2380  	// include in API requests. By default, fields with empty or default values are
  2381  	// omitted from API requests. See
  2382  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2383  	// details.
  2384  	ForceSendFields []string `json:"-"`
  2385  	// NullFields is a list of field names (e.g. "Backup") to include in API
  2386  	// requests with the JSON null value. By default, fields with empty values are
  2387  	// omitted from API requests. See
  2388  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2389  	NullFields []string `json:"-"`
  2390  }
  2391  
  2392  func (s *RestoreServiceRequest) MarshalJSON() ([]byte, error) {
  2393  	type NoMethod RestoreServiceRequest
  2394  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2395  }
  2396  
  2397  // ScalingConfig: Represents the scaling configuration of a metastore service.
  2398  type ScalingConfig struct {
  2399  	// AutoscalingConfig: Optional. The autoscaling configuration.
  2400  	AutoscalingConfig *AutoscalingConfig `json:"autoscalingConfig,omitempty"`
  2401  	// InstanceSize: An enum of readable instance sizes, with each instance size
  2402  	// mapping to a float value (e.g. InstanceSize.EXTRA_SMALL =
  2403  	// scaling_factor(0.1))
  2404  	//
  2405  	// Possible values:
  2406  	//   "INSTANCE_SIZE_UNSPECIFIED" - Unspecified instance size
  2407  	//   "EXTRA_SMALL" - Extra small instance size, maps to a scaling factor of
  2408  	// 0.1.
  2409  	//   "SMALL" - Small instance size, maps to a scaling factor of 0.5.
  2410  	//   "MEDIUM" - Medium instance size, maps to a scaling factor of 1.0.
  2411  	//   "LARGE" - Large instance size, maps to a scaling factor of 3.0.
  2412  	//   "EXTRA_LARGE" - Extra large instance size, maps to a scaling factor of
  2413  	// 6.0.
  2414  	InstanceSize string `json:"instanceSize,omitempty"`
  2415  	// ScalingFactor: Scaling factor, increments of 0.1 for values less than 1.0,
  2416  	// and increments of 1.0 for values greater than 1.0.
  2417  	ScalingFactor float64 `json:"scalingFactor,omitempty"`
  2418  	// ForceSendFields is a list of field names (e.g. "AutoscalingConfig") to
  2419  	// unconditionally include in API requests. By default, fields with empty or
  2420  	// default values are omitted from API requests. See
  2421  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2422  	// details.
  2423  	ForceSendFields []string `json:"-"`
  2424  	// NullFields is a list of field names (e.g. "AutoscalingConfig") to include in
  2425  	// API requests with the JSON null value. By default, fields with empty values
  2426  	// are omitted from API requests. See
  2427  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2428  	NullFields []string `json:"-"`
  2429  }
  2430  
  2431  func (s *ScalingConfig) MarshalJSON() ([]byte, error) {
  2432  	type NoMethod ScalingConfig
  2433  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2434  }
  2435  
  2436  func (s *ScalingConfig) UnmarshalJSON(data []byte) error {
  2437  	type NoMethod ScalingConfig
  2438  	var s1 struct {
  2439  		ScalingFactor gensupport.JSONFloat64 `json:"scalingFactor"`
  2440  		*NoMethod
  2441  	}
  2442  	s1.NoMethod = (*NoMethod)(s)
  2443  	if err := json.Unmarshal(data, &s1); err != nil {
  2444  		return err
  2445  	}
  2446  	s.ScalingFactor = float64(s1.ScalingFactor)
  2447  	return nil
  2448  }
  2449  
  2450  // ScheduledBackup: This specifies the configuration of scheduled backup.
  2451  type ScheduledBackup struct {
  2452  	// BackupLocation: Optional. A Cloud Storage URI of a folder, in the format
  2453  	// gs:///. A sub-folder containing backup files will be stored below it.
  2454  	BackupLocation string `json:"backupLocation,omitempty"`
  2455  	// CronSchedule: Optional. The scheduled interval in Cron format, see
  2456  	// https://en.wikipedia.org/wiki/Cron The default is empty: scheduled backup is
  2457  	// not enabled. Must be specified to enable scheduled backups.
  2458  	CronSchedule string `json:"cronSchedule,omitempty"`
  2459  	// Enabled: Optional. Defines whether the scheduled backup is enabled. The
  2460  	// default value is false.
  2461  	Enabled bool `json:"enabled,omitempty"`
  2462  	// LatestBackup: Output only. The details of the latest scheduled backup.
  2463  	LatestBackup *LatestBackup `json:"latestBackup,omitempty"`
  2464  	// NextScheduledTime: Output only. The time when the next backups execution is
  2465  	// scheduled to start.
  2466  	NextScheduledTime string `json:"nextScheduledTime,omitempty"`
  2467  	// TimeZone: Optional. Specifies the time zone to be used when interpreting
  2468  	// cron_schedule. Must be a time zone name from the time zone database
  2469  	// (https://en.wikipedia.org/wiki/List_of_tz_database_time_zones), e.g.
  2470  	// America/Los_Angeles or Africa/Abidjan. If left unspecified, the default is
  2471  	// UTC.
  2472  	TimeZone string `json:"timeZone,omitempty"`
  2473  	// ForceSendFields is a list of field names (e.g. "BackupLocation") to
  2474  	// unconditionally include in API requests. By default, fields with empty or
  2475  	// default values are omitted from API requests. See
  2476  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2477  	// details.
  2478  	ForceSendFields []string `json:"-"`
  2479  	// NullFields is a list of field names (e.g. "BackupLocation") to include in
  2480  	// API requests with the JSON null value. By default, fields with empty values
  2481  	// are omitted from API requests. See
  2482  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2483  	NullFields []string `json:"-"`
  2484  }
  2485  
  2486  func (s *ScheduledBackup) MarshalJSON() ([]byte, error) {
  2487  	type NoMethod ScheduledBackup
  2488  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2489  }
  2490  
  2491  // Secret: A securely stored value.
  2492  type Secret struct {
  2493  	// CloudSecret: The relative resource name of a Secret Manager secret version,
  2494  	// in the following
  2495  	// form:projects/{project_number}/secrets/{secret_id}/versions/{version_id}.
  2496  	CloudSecret string `json:"cloudSecret,omitempty"`
  2497  	// ForceSendFields is a list of field names (e.g. "CloudSecret") to
  2498  	// unconditionally include in API requests. By default, fields with empty or
  2499  	// default values are omitted from API requests. See
  2500  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2501  	// details.
  2502  	ForceSendFields []string `json:"-"`
  2503  	// NullFields is a list of field names (e.g. "CloudSecret") to include in API
  2504  	// requests with the JSON null value. By default, fields with empty values are
  2505  	// omitted from API requests. See
  2506  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2507  	NullFields []string `json:"-"`
  2508  }
  2509  
  2510  func (s *Secret) MarshalJSON() ([]byte, error) {
  2511  	type NoMethod Secret
  2512  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2513  }
  2514  
  2515  // Service: A managed metastore service that serves metadata queries.
  2516  type Service struct {
  2517  	// ArtifactGcsUri: Output only. A Cloud Storage URI (starting with gs://) that
  2518  	// specifies where artifacts related to the metastore service are stored.
  2519  	ArtifactGcsUri string `json:"artifactGcsUri,omitempty"`
  2520  	// CreateTime: Output only. The time when the metastore service was created.
  2521  	CreateTime string `json:"createTime,omitempty"`
  2522  	// DatabaseType: Immutable. The database type that the Metastore service stores
  2523  	// its data.
  2524  	//
  2525  	// Possible values:
  2526  	//   "DATABASE_TYPE_UNSPECIFIED" - The DATABASE_TYPE is not set.
  2527  	//   "MYSQL" - MySQL is used to persist the metastore data.
  2528  	//   "SPANNER" - Spanner is used to persist the metastore data.
  2529  	DatabaseType string `json:"databaseType,omitempty"`
  2530  	// EncryptionConfig: Immutable. Information used to configure the Dataproc
  2531  	// Metastore service to encrypt customer data at rest. Cannot be updated.
  2532  	EncryptionConfig *EncryptionConfig `json:"encryptionConfig,omitempty"`
  2533  	// EndpointUri: Output only. The URI of the endpoint used to access the
  2534  	// metastore service.
  2535  	EndpointUri string `json:"endpointUri,omitempty"`
  2536  	// HiveMetastoreConfig: Configuration information specific to running Hive
  2537  	// metastore software as the metastore service.
  2538  	HiveMetastoreConfig *HiveMetastoreConfig `json:"hiveMetastoreConfig,omitempty"`
  2539  	// Labels: User-defined labels for the metastore service.
  2540  	Labels map[string]string `json:"labels,omitempty"`
  2541  	// MaintenanceWindow: The one hour maintenance window of the metastore service.
  2542  	// This specifies when the service can be restarted for maintenance purposes in
  2543  	// UTC time. Maintenance window is not needed for services with the SPANNER
  2544  	// database type.
  2545  	MaintenanceWindow *MaintenanceWindow `json:"maintenanceWindow,omitempty"`
  2546  	// MetadataIntegration: Optional. The setting that defines how metastore
  2547  	// metadata should be integrated with external services and systems.
  2548  	MetadataIntegration *MetadataIntegration `json:"metadataIntegration,omitempty"`
  2549  	// MetadataManagementActivity: Output only. The metadata management activities
  2550  	// of the metastore service.
  2551  	MetadataManagementActivity *MetadataManagementActivity `json:"metadataManagementActivity,omitempty"`
  2552  	// Name: Immutable. The relative resource name of the metastore service, in the
  2553  	// following
  2554  	// format:projects/{project_number}/locations/{location_id}/services/{service_id
  2555  	// }.
  2556  	Name string `json:"name,omitempty"`
  2557  	// Network: Immutable. The relative resource name of the VPC network on which
  2558  	// the instance can be accessed. It is specified in the following
  2559  	// form:projects/{project_number}/global/networks/{network_id}.
  2560  	Network string `json:"network,omitempty"`
  2561  	// NetworkConfig: The configuration specifying the network settings for the
  2562  	// Dataproc Metastore service.
  2563  	NetworkConfig *NetworkConfig `json:"networkConfig,omitempty"`
  2564  	// Port: The TCP port at which the metastore service is reached. Default: 9083.
  2565  	Port int64 `json:"port,omitempty"`
  2566  	// ReleaseChannel: Immutable. The release channel of the service. If
  2567  	// unspecified, defaults to STABLE.
  2568  	//
  2569  	// Possible values:
  2570  	//   "RELEASE_CHANNEL_UNSPECIFIED" - Release channel is not specified.
  2571  	//   "CANARY" - The CANARY release channel contains the newest features, which
  2572  	// may be unstable and subject to unresolved issues with no known workarounds.
  2573  	// Services using the CANARY release channel are not subject to any SLAs.
  2574  	//   "STABLE" - The STABLE release channel contains features that are
  2575  	// considered stable and have been validated for production use.
  2576  	ReleaseChannel string `json:"releaseChannel,omitempty"`
  2577  	// ScalingConfig: Scaling configuration of the metastore service.
  2578  	ScalingConfig *ScalingConfig `json:"scalingConfig,omitempty"`
  2579  	// ScheduledBackup: Optional. The configuration of scheduled backup for the
  2580  	// metastore service.
  2581  	ScheduledBackup *ScheduledBackup `json:"scheduledBackup,omitempty"`
  2582  	// State: Output only. The current state of the metastore service.
  2583  	//
  2584  	// Possible values:
  2585  	//   "STATE_UNSPECIFIED" - The state of the metastore service is unknown.
  2586  	//   "CREATING" - The metastore service is in the process of being created.
  2587  	//   "ACTIVE" - The metastore service is running and ready to serve queries.
  2588  	//   "SUSPENDING" - The metastore service is entering suspension. Its
  2589  	// query-serving availability may cease unexpectedly.
  2590  	//   "SUSPENDED" - The metastore service is suspended and unable to serve
  2591  	// queries.
  2592  	//   "UPDATING" - The metastore service is being updated. It remains usable but
  2593  	// cannot accept additional update requests or be deleted at this time.
  2594  	//   "DELETING" - The metastore service is undergoing deletion. It cannot be
  2595  	// used.
  2596  	//   "ERROR" - The metastore service has encountered an error and cannot be
  2597  	// used. The metastore service should be deleted.
  2598  	//   "MIGRATING" - The metastore service is processing a managed migration.
  2599  	State string `json:"state,omitempty"`
  2600  	// StateMessage: Output only. Additional information about the current state of
  2601  	// the metastore service, if available.
  2602  	StateMessage string `json:"stateMessage,omitempty"`
  2603  	// TelemetryConfig: The configuration specifying telemetry settings for the
  2604  	// Dataproc Metastore service. If unspecified defaults to JSON.
  2605  	TelemetryConfig *TelemetryConfig `json:"telemetryConfig,omitempty"`
  2606  	// Tier: The tier of the service.
  2607  	//
  2608  	// Possible values:
  2609  	//   "TIER_UNSPECIFIED" - The tier is not set.
  2610  	//   "DEVELOPER" - The developer tier provides limited scalability and no fault
  2611  	// tolerance. Good for low-cost proof-of-concept.
  2612  	//   "ENTERPRISE" - The enterprise tier provides multi-zone high availability,
  2613  	// and sufficient scalability for enterprise-level Dataproc Metastore
  2614  	// workloads.
  2615  	Tier string `json:"tier,omitempty"`
  2616  	// Uid: Output only. The globally unique resource identifier of the metastore
  2617  	// service.
  2618  	Uid string `json:"uid,omitempty"`
  2619  	// UpdateTime: Output only. The time when the metastore service was last
  2620  	// updated.
  2621  	UpdateTime string `json:"updateTime,omitempty"`
  2622  
  2623  	// ServerResponse contains the HTTP response code and headers from the server.
  2624  	googleapi.ServerResponse `json:"-"`
  2625  	// ForceSendFields is a list of field names (e.g. "ArtifactGcsUri") to
  2626  	// unconditionally include in API requests. By default, fields with empty or
  2627  	// default values are omitted from API requests. See
  2628  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2629  	// details.
  2630  	ForceSendFields []string `json:"-"`
  2631  	// NullFields is a list of field names (e.g. "ArtifactGcsUri") to include in
  2632  	// API requests with the JSON null value. By default, fields with empty values
  2633  	// are omitted from API requests. See
  2634  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2635  	NullFields []string `json:"-"`
  2636  }
  2637  
  2638  func (s *Service) MarshalJSON() ([]byte, error) {
  2639  	type NoMethod Service
  2640  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2641  }
  2642  
  2643  // SetIamPolicyRequest: Request message for SetIamPolicy method.
  2644  type SetIamPolicyRequest struct {
  2645  	// Policy: REQUIRED: The complete policy to be applied to the resource. The
  2646  	// size of the policy is limited to a few 10s of KB. An empty policy is a valid
  2647  	// policy but certain Google Cloud services (such as Projects) might reject
  2648  	// them.
  2649  	Policy *Policy `json:"policy,omitempty"`
  2650  	// UpdateMask: OPTIONAL: A FieldMask specifying which fields of the policy to
  2651  	// modify. Only the fields in the mask will be modified. If no mask is
  2652  	// provided, the following default mask is used:paths: "bindings, etag"
  2653  	UpdateMask string `json:"updateMask,omitempty"`
  2654  	// ForceSendFields is a list of field names (e.g. "Policy") to unconditionally
  2655  	// include in API requests. By default, fields with empty or default values are
  2656  	// omitted from API requests. See
  2657  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2658  	// details.
  2659  	ForceSendFields []string `json:"-"`
  2660  	// NullFields is a list of field names (e.g. "Policy") to include in API
  2661  	// requests with the JSON null value. By default, fields with empty values are
  2662  	// omitted from API requests. See
  2663  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2664  	NullFields []string `json:"-"`
  2665  }
  2666  
  2667  func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
  2668  	type NoMethod SetIamPolicyRequest
  2669  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2670  }
  2671  
  2672  // StartMigrationRequest: Request message for DataprocMetastore.StartMigration.
  2673  type StartMigrationRequest struct {
  2674  	// MigrationExecution: Required. The configuration details for the migration.
  2675  	MigrationExecution *MigrationExecution `json:"migrationExecution,omitempty"`
  2676  	// RequestId: Optional. A request ID. Specify a unique request ID to allow the
  2677  	// server to ignore the request if it has completed. The server will ignore
  2678  	// subsequent requests that provide a duplicate request ID for at least 60
  2679  	// minutes after the first request.For example, if an initial request times
  2680  	// out, followed by another request with the same request ID, the server
  2681  	// ignores the second request to prevent the creation of duplicate
  2682  	// commitments.The request ID must be a valid UUID
  2683  	// (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  2684  	// UUID (00000000-0000-0000-0000-000000000000) is not supported.
  2685  	RequestId string `json:"requestId,omitempty"`
  2686  	// ForceSendFields is a list of field names (e.g. "MigrationExecution") to
  2687  	// unconditionally include in API requests. By default, fields with empty or
  2688  	// default values are omitted from API requests. See
  2689  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2690  	// details.
  2691  	ForceSendFields []string `json:"-"`
  2692  	// NullFields is a list of field names (e.g. "MigrationExecution") to include
  2693  	// in API requests with the JSON null value. By default, fields with empty
  2694  	// values are omitted from API requests. See
  2695  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2696  	NullFields []string `json:"-"`
  2697  }
  2698  
  2699  func (s *StartMigrationRequest) MarshalJSON() ([]byte, error) {
  2700  	type NoMethod StartMigrationRequest
  2701  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2702  }
  2703  
  2704  // Status: The Status type defines a logical error model that is suitable for
  2705  // different programming environments, including REST APIs and RPC APIs. It is
  2706  // used by gRPC (https://github.com/grpc). Each Status message contains three
  2707  // pieces of data: error code, error message, and error details.You can find
  2708  // out more about this error model and how to work with it in the API Design
  2709  // Guide (https://cloud.google.com/apis/design/errors).
  2710  type Status struct {
  2711  	// Code: The status code, which should be an enum value of google.rpc.Code.
  2712  	Code int64 `json:"code,omitempty"`
  2713  	// Details: A list of messages that carry the error details. There is a common
  2714  	// set of message types for APIs to use.
  2715  	Details []googleapi.RawMessage `json:"details,omitempty"`
  2716  	// Message: A developer-facing error message, which should be in English. Any
  2717  	// user-facing error message should be localized and sent in the
  2718  	// google.rpc.Status.details field, or localized by the client.
  2719  	Message string `json:"message,omitempty"`
  2720  	// ForceSendFields is a list of field names (e.g. "Code") to unconditionally
  2721  	// include in API requests. By default, fields with empty or default values are
  2722  	// omitted from API requests. See
  2723  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2724  	// details.
  2725  	ForceSendFields []string `json:"-"`
  2726  	// NullFields is a list of field names (e.g. "Code") to include in API requests
  2727  	// with the JSON null value. By default, fields with empty values are omitted
  2728  	// from API requests. See
  2729  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2730  	NullFields []string `json:"-"`
  2731  }
  2732  
  2733  func (s *Status) MarshalJSON() ([]byte, error) {
  2734  	type NoMethod Status
  2735  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2736  }
  2737  
  2738  // TelemetryConfig: Telemetry Configuration for the Dataproc Metastore service.
  2739  type TelemetryConfig struct {
  2740  	// LogFormat: The output format of the Dataproc Metastore service's logs.
  2741  	//
  2742  	// Possible values:
  2743  	//   "LOG_FORMAT_UNSPECIFIED" - The LOG_FORMAT is not set.
  2744  	//   "LEGACY" - Logging output uses the legacy textPayload format.
  2745  	//   "JSON" - Logging output uses the jsonPayload format.
  2746  	LogFormat string `json:"logFormat,omitempty"`
  2747  	// ForceSendFields is a list of field names (e.g. "LogFormat") to
  2748  	// unconditionally include in API requests. By default, fields with empty or
  2749  	// default values are omitted from API requests. See
  2750  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2751  	// details.
  2752  	ForceSendFields []string `json:"-"`
  2753  	// NullFields is a list of field names (e.g. "LogFormat") to include in API
  2754  	// requests with the JSON null value. By default, fields with empty values are
  2755  	// omitted from API requests. See
  2756  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2757  	NullFields []string `json:"-"`
  2758  }
  2759  
  2760  func (s *TelemetryConfig) MarshalJSON() ([]byte, error) {
  2761  	type NoMethod TelemetryConfig
  2762  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2763  }
  2764  
  2765  // TestIamPermissionsRequest: Request message for TestIamPermissions method.
  2766  type TestIamPermissionsRequest struct {
  2767  	// Permissions: The set of permissions to check for the resource. Permissions
  2768  	// with wildcards (such as * or storage.*) are not allowed. For more
  2769  	// information see IAM Overview
  2770  	// (https://cloud.google.com/iam/docs/overview#permissions).
  2771  	Permissions []string `json:"permissions,omitempty"`
  2772  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  2773  	// unconditionally include in API requests. By default, fields with empty or
  2774  	// default values are omitted from API requests. See
  2775  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2776  	// details.
  2777  	ForceSendFields []string `json:"-"`
  2778  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  2779  	// requests with the JSON null value. By default, fields with empty values are
  2780  	// omitted from API requests. See
  2781  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2782  	NullFields []string `json:"-"`
  2783  }
  2784  
  2785  func (s *TestIamPermissionsRequest) MarshalJSON() ([]byte, error) {
  2786  	type NoMethod TestIamPermissionsRequest
  2787  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2788  }
  2789  
  2790  // TestIamPermissionsResponse: Response message for TestIamPermissions method.
  2791  type TestIamPermissionsResponse struct {
  2792  	// Permissions: A subset of TestPermissionsRequest.permissions that the caller
  2793  	// is allowed.
  2794  	Permissions []string `json:"permissions,omitempty"`
  2795  
  2796  	// ServerResponse contains the HTTP response code and headers from the server.
  2797  	googleapi.ServerResponse `json:"-"`
  2798  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  2799  	// unconditionally include in API requests. By default, fields with empty or
  2800  	// default values are omitted from API requests. See
  2801  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2802  	// details.
  2803  	ForceSendFields []string `json:"-"`
  2804  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  2805  	// requests with the JSON null value. By default, fields with empty values are
  2806  	// omitted from API requests. See
  2807  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2808  	NullFields []string `json:"-"`
  2809  }
  2810  
  2811  func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) {
  2812  	type NoMethod TestIamPermissionsResponse
  2813  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2814  }
  2815  
  2816  type ProjectsLocationsGetCall struct {
  2817  	s            *APIService
  2818  	name         string
  2819  	urlParams_   gensupport.URLParams
  2820  	ifNoneMatch_ string
  2821  	ctx_         context.Context
  2822  	header_      http.Header
  2823  }
  2824  
  2825  // Get: Gets information about a location.
  2826  //
  2827  // - name: Resource name for the location.
  2828  func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall {
  2829  	c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2830  	c.name = name
  2831  	return c
  2832  }
  2833  
  2834  // Fields allows partial responses to be retrieved. See
  2835  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2836  // details.
  2837  func (c *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall {
  2838  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2839  	return c
  2840  }
  2841  
  2842  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2843  // object's ETag matches the given value. This is useful for getting updates
  2844  // only after the object has changed since the last request.
  2845  func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall {
  2846  	c.ifNoneMatch_ = entityTag
  2847  	return c
  2848  }
  2849  
  2850  // Context sets the context to be used in this call's Do method.
  2851  func (c *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall {
  2852  	c.ctx_ = ctx
  2853  	return c
  2854  }
  2855  
  2856  // Header returns a http.Header that can be modified by the caller to add
  2857  // headers to the request.
  2858  func (c *ProjectsLocationsGetCall) Header() http.Header {
  2859  	if c.header_ == nil {
  2860  		c.header_ = make(http.Header)
  2861  	}
  2862  	return c.header_
  2863  }
  2864  
  2865  func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) {
  2866  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2867  	if c.ifNoneMatch_ != "" {
  2868  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2869  	}
  2870  	var body io.Reader = nil
  2871  	c.urlParams_.Set("alt", alt)
  2872  	c.urlParams_.Set("prettyPrint", "false")
  2873  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  2874  	urls += "?" + c.urlParams_.Encode()
  2875  	req, err := http.NewRequest("GET", urls, body)
  2876  	if err != nil {
  2877  		return nil, err
  2878  	}
  2879  	req.Header = reqHeaders
  2880  	googleapi.Expand(req.URL, map[string]string{
  2881  		"name": c.name,
  2882  	})
  2883  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2884  }
  2885  
  2886  // Do executes the "metastore.projects.locations.get" call.
  2887  // Any non-2xx status code is an error. Response headers are in either
  2888  // *Location.ServerResponse.Header or (if a response was returned at all) in
  2889  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2890  // whether the returned error was because http.StatusNotModified was returned.
  2891  func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) {
  2892  	gensupport.SetOptions(c.urlParams_, opts...)
  2893  	res, err := c.doRequest("json")
  2894  	if res != nil && res.StatusCode == http.StatusNotModified {
  2895  		if res.Body != nil {
  2896  			res.Body.Close()
  2897  		}
  2898  		return nil, gensupport.WrapError(&googleapi.Error{
  2899  			Code:   res.StatusCode,
  2900  			Header: res.Header,
  2901  		})
  2902  	}
  2903  	if err != nil {
  2904  		return nil, err
  2905  	}
  2906  	defer googleapi.CloseBody(res)
  2907  	if err := googleapi.CheckResponse(res); err != nil {
  2908  		return nil, gensupport.WrapError(err)
  2909  	}
  2910  	ret := &Location{
  2911  		ServerResponse: googleapi.ServerResponse{
  2912  			Header:         res.Header,
  2913  			HTTPStatusCode: res.StatusCode,
  2914  		},
  2915  	}
  2916  	target := &ret
  2917  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2918  		return nil, err
  2919  	}
  2920  	return ret, nil
  2921  }
  2922  
  2923  type ProjectsLocationsListCall struct {
  2924  	s            *APIService
  2925  	name         string
  2926  	urlParams_   gensupport.URLParams
  2927  	ifNoneMatch_ string
  2928  	ctx_         context.Context
  2929  	header_      http.Header
  2930  }
  2931  
  2932  // List: Lists information about the supported locations for this service.
  2933  //
  2934  // - name: The resource that owns the locations collection, if applicable.
  2935  func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall {
  2936  	c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2937  	c.name = name
  2938  	return c
  2939  }
  2940  
  2941  // Filter sets the optional parameter "filter": A filter to narrow down results
  2942  // to a preferred subset. The filtering language accepts strings like
  2943  // "displayName=tokyo", and is documented in more detail in AIP-160
  2944  // (https://google.aip.dev/160).
  2945  func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall {
  2946  	c.urlParams_.Set("filter", filter)
  2947  	return c
  2948  }
  2949  
  2950  // PageSize sets the optional parameter "pageSize": The maximum number of
  2951  // results to return. If not set, the service selects a default.
  2952  func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall {
  2953  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  2954  	return c
  2955  }
  2956  
  2957  // PageToken sets the optional parameter "pageToken": A page token received
  2958  // from the next_page_token field in the response. Send that page token to
  2959  // receive the subsequent page.
  2960  func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall {
  2961  	c.urlParams_.Set("pageToken", pageToken)
  2962  	return c
  2963  }
  2964  
  2965  // Fields allows partial responses to be retrieved. See
  2966  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2967  // details.
  2968  func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall {
  2969  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2970  	return c
  2971  }
  2972  
  2973  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2974  // object's ETag matches the given value. This is useful for getting updates
  2975  // only after the object has changed since the last request.
  2976  func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall {
  2977  	c.ifNoneMatch_ = entityTag
  2978  	return c
  2979  }
  2980  
  2981  // Context sets the context to be used in this call's Do method.
  2982  func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall {
  2983  	c.ctx_ = ctx
  2984  	return c
  2985  }
  2986  
  2987  // Header returns a http.Header that can be modified by the caller to add
  2988  // headers to the request.
  2989  func (c *ProjectsLocationsListCall) Header() http.Header {
  2990  	if c.header_ == nil {
  2991  		c.header_ = make(http.Header)
  2992  	}
  2993  	return c.header_
  2994  }
  2995  
  2996  func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) {
  2997  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2998  	if c.ifNoneMatch_ != "" {
  2999  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3000  	}
  3001  	var body io.Reader = nil
  3002  	c.urlParams_.Set("alt", alt)
  3003  	c.urlParams_.Set("prettyPrint", "false")
  3004  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}/locations")
  3005  	urls += "?" + c.urlParams_.Encode()
  3006  	req, err := http.NewRequest("GET", urls, body)
  3007  	if err != nil {
  3008  		return nil, err
  3009  	}
  3010  	req.Header = reqHeaders
  3011  	googleapi.Expand(req.URL, map[string]string{
  3012  		"name": c.name,
  3013  	})
  3014  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3015  }
  3016  
  3017  // Do executes the "metastore.projects.locations.list" call.
  3018  // Any non-2xx status code is an error. Response headers are in either
  3019  // *ListLocationsResponse.ServerResponse.Header or (if a response was returned
  3020  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3021  // check whether the returned error was because http.StatusNotModified was
  3022  // returned.
  3023  func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) {
  3024  	gensupport.SetOptions(c.urlParams_, opts...)
  3025  	res, err := c.doRequest("json")
  3026  	if res != nil && res.StatusCode == http.StatusNotModified {
  3027  		if res.Body != nil {
  3028  			res.Body.Close()
  3029  		}
  3030  		return nil, gensupport.WrapError(&googleapi.Error{
  3031  			Code:   res.StatusCode,
  3032  			Header: res.Header,
  3033  		})
  3034  	}
  3035  	if err != nil {
  3036  		return nil, err
  3037  	}
  3038  	defer googleapi.CloseBody(res)
  3039  	if err := googleapi.CheckResponse(res); err != nil {
  3040  		return nil, gensupport.WrapError(err)
  3041  	}
  3042  	ret := &ListLocationsResponse{
  3043  		ServerResponse: googleapi.ServerResponse{
  3044  			Header:         res.Header,
  3045  			HTTPStatusCode: res.StatusCode,
  3046  		},
  3047  	}
  3048  	target := &ret
  3049  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3050  		return nil, err
  3051  	}
  3052  	return ret, nil
  3053  }
  3054  
  3055  // Pages invokes f for each page of results.
  3056  // A non-nil error returned from f will halt the iteration.
  3057  // The provided context supersedes any context provided to the Context method.
  3058  func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) error) error {
  3059  	c.ctx_ = ctx
  3060  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3061  	for {
  3062  		x, err := c.Do()
  3063  		if err != nil {
  3064  			return err
  3065  		}
  3066  		if err := f(x); err != nil {
  3067  			return err
  3068  		}
  3069  		if x.NextPageToken == "" {
  3070  			return nil
  3071  		}
  3072  		c.PageToken(x.NextPageToken)
  3073  	}
  3074  }
  3075  
  3076  type ProjectsLocationsFederationsCreateCall struct {
  3077  	s          *APIService
  3078  	parent     string
  3079  	federation *Federation
  3080  	urlParams_ gensupport.URLParams
  3081  	ctx_       context.Context
  3082  	header_    http.Header
  3083  }
  3084  
  3085  // Create: Creates a metastore federation in a project and location.
  3086  //
  3087  //   - parent: The relative resource name of the location in which to create a
  3088  //     federation service, in the following
  3089  //     form:projects/{project_number}/locations/{location_id}.
  3090  func (r *ProjectsLocationsFederationsService) Create(parent string, federation *Federation) *ProjectsLocationsFederationsCreateCall {
  3091  	c := &ProjectsLocationsFederationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3092  	c.parent = parent
  3093  	c.federation = federation
  3094  	return c
  3095  }
  3096  
  3097  // FederationId sets the optional parameter "federationId": Required. The ID of
  3098  // the metastore federation, which is used as the final component of the
  3099  // metastore federation's name.This value must be between 2 and 63 characters
  3100  // long inclusive, begin with a letter, end with a letter or number, and
  3101  // consist of alpha-numeric ASCII characters or hyphens.
  3102  func (c *ProjectsLocationsFederationsCreateCall) FederationId(federationId string) *ProjectsLocationsFederationsCreateCall {
  3103  	c.urlParams_.Set("federationId", federationId)
  3104  	return c
  3105  }
  3106  
  3107  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  3108  // unique request ID to allow the server to ignore the request if it has
  3109  // completed. The server will ignore subsequent requests that provide a
  3110  // duplicate request ID for at least 60 minutes after the first request.For
  3111  // example, if an initial request times out, followed by another request with
  3112  // the same request ID, the server ignores the second request to prevent the
  3113  // creation of duplicate commitments.The request ID must be a valid UUID
  3114  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  3115  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  3116  func (c *ProjectsLocationsFederationsCreateCall) RequestId(requestId string) *ProjectsLocationsFederationsCreateCall {
  3117  	c.urlParams_.Set("requestId", requestId)
  3118  	return c
  3119  }
  3120  
  3121  // Fields allows partial responses to be retrieved. See
  3122  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3123  // details.
  3124  func (c *ProjectsLocationsFederationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsCreateCall {
  3125  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3126  	return c
  3127  }
  3128  
  3129  // Context sets the context to be used in this call's Do method.
  3130  func (c *ProjectsLocationsFederationsCreateCall) Context(ctx context.Context) *ProjectsLocationsFederationsCreateCall {
  3131  	c.ctx_ = ctx
  3132  	return c
  3133  }
  3134  
  3135  // Header returns a http.Header that can be modified by the caller to add
  3136  // headers to the request.
  3137  func (c *ProjectsLocationsFederationsCreateCall) Header() http.Header {
  3138  	if c.header_ == nil {
  3139  		c.header_ = make(http.Header)
  3140  	}
  3141  	return c.header_
  3142  }
  3143  
  3144  func (c *ProjectsLocationsFederationsCreateCall) doRequest(alt string) (*http.Response, error) {
  3145  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3146  	var body io.Reader = nil
  3147  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.federation)
  3148  	if err != nil {
  3149  		return nil, err
  3150  	}
  3151  	c.urlParams_.Set("alt", alt)
  3152  	c.urlParams_.Set("prettyPrint", "false")
  3153  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/federations")
  3154  	urls += "?" + c.urlParams_.Encode()
  3155  	req, err := http.NewRequest("POST", urls, body)
  3156  	if err != nil {
  3157  		return nil, err
  3158  	}
  3159  	req.Header = reqHeaders
  3160  	googleapi.Expand(req.URL, map[string]string{
  3161  		"parent": c.parent,
  3162  	})
  3163  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3164  }
  3165  
  3166  // Do executes the "metastore.projects.locations.federations.create" call.
  3167  // Any non-2xx status code is an error. Response headers are in either
  3168  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3169  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3170  // whether the returned error was because http.StatusNotModified was returned.
  3171  func (c *ProjectsLocationsFederationsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3172  	gensupport.SetOptions(c.urlParams_, opts...)
  3173  	res, err := c.doRequest("json")
  3174  	if res != nil && res.StatusCode == http.StatusNotModified {
  3175  		if res.Body != nil {
  3176  			res.Body.Close()
  3177  		}
  3178  		return nil, gensupport.WrapError(&googleapi.Error{
  3179  			Code:   res.StatusCode,
  3180  			Header: res.Header,
  3181  		})
  3182  	}
  3183  	if err != nil {
  3184  		return nil, err
  3185  	}
  3186  	defer googleapi.CloseBody(res)
  3187  	if err := googleapi.CheckResponse(res); err != nil {
  3188  		return nil, gensupport.WrapError(err)
  3189  	}
  3190  	ret := &Operation{
  3191  		ServerResponse: googleapi.ServerResponse{
  3192  			Header:         res.Header,
  3193  			HTTPStatusCode: res.StatusCode,
  3194  		},
  3195  	}
  3196  	target := &ret
  3197  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3198  		return nil, err
  3199  	}
  3200  	return ret, nil
  3201  }
  3202  
  3203  type ProjectsLocationsFederationsDeleteCall struct {
  3204  	s          *APIService
  3205  	name       string
  3206  	urlParams_ gensupport.URLParams
  3207  	ctx_       context.Context
  3208  	header_    http.Header
  3209  }
  3210  
  3211  // Delete: Deletes a single federation.
  3212  //
  3213  //   - name: The relative resource name of the metastore federation to delete, in
  3214  //     the following
  3215  //     form:projects/{project_number}/locations/{location_id}/federations/{federat
  3216  //     ion_id}.
  3217  func (r *ProjectsLocationsFederationsService) Delete(name string) *ProjectsLocationsFederationsDeleteCall {
  3218  	c := &ProjectsLocationsFederationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3219  	c.name = name
  3220  	return c
  3221  }
  3222  
  3223  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  3224  // unique request ID to allow the server to ignore the request if it has
  3225  // completed. The server will ignore subsequent requests that provide a
  3226  // duplicate request ID for at least 60 minutes after the first request.For
  3227  // example, if an initial request times out, followed by another request with
  3228  // the same request ID, the server ignores the second request to prevent the
  3229  // creation of duplicate commitments.The request ID must be a valid UUID
  3230  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  3231  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  3232  func (c *ProjectsLocationsFederationsDeleteCall) RequestId(requestId string) *ProjectsLocationsFederationsDeleteCall {
  3233  	c.urlParams_.Set("requestId", requestId)
  3234  	return c
  3235  }
  3236  
  3237  // Fields allows partial responses to be retrieved. See
  3238  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3239  // details.
  3240  func (c *ProjectsLocationsFederationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsDeleteCall {
  3241  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3242  	return c
  3243  }
  3244  
  3245  // Context sets the context to be used in this call's Do method.
  3246  func (c *ProjectsLocationsFederationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsFederationsDeleteCall {
  3247  	c.ctx_ = ctx
  3248  	return c
  3249  }
  3250  
  3251  // Header returns a http.Header that can be modified by the caller to add
  3252  // headers to the request.
  3253  func (c *ProjectsLocationsFederationsDeleteCall) Header() http.Header {
  3254  	if c.header_ == nil {
  3255  		c.header_ = make(http.Header)
  3256  	}
  3257  	return c.header_
  3258  }
  3259  
  3260  func (c *ProjectsLocationsFederationsDeleteCall) doRequest(alt string) (*http.Response, error) {
  3261  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3262  	var body io.Reader = nil
  3263  	c.urlParams_.Set("alt", alt)
  3264  	c.urlParams_.Set("prettyPrint", "false")
  3265  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  3266  	urls += "?" + c.urlParams_.Encode()
  3267  	req, err := http.NewRequest("DELETE", urls, body)
  3268  	if err != nil {
  3269  		return nil, err
  3270  	}
  3271  	req.Header = reqHeaders
  3272  	googleapi.Expand(req.URL, map[string]string{
  3273  		"name": c.name,
  3274  	})
  3275  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3276  }
  3277  
  3278  // Do executes the "metastore.projects.locations.federations.delete" call.
  3279  // Any non-2xx status code is an error. Response headers are in either
  3280  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3281  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3282  // whether the returned error was because http.StatusNotModified was returned.
  3283  func (c *ProjectsLocationsFederationsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3284  	gensupport.SetOptions(c.urlParams_, opts...)
  3285  	res, err := c.doRequest("json")
  3286  	if res != nil && res.StatusCode == http.StatusNotModified {
  3287  		if res.Body != nil {
  3288  			res.Body.Close()
  3289  		}
  3290  		return nil, gensupport.WrapError(&googleapi.Error{
  3291  			Code:   res.StatusCode,
  3292  			Header: res.Header,
  3293  		})
  3294  	}
  3295  	if err != nil {
  3296  		return nil, err
  3297  	}
  3298  	defer googleapi.CloseBody(res)
  3299  	if err := googleapi.CheckResponse(res); err != nil {
  3300  		return nil, gensupport.WrapError(err)
  3301  	}
  3302  	ret := &Operation{
  3303  		ServerResponse: googleapi.ServerResponse{
  3304  			Header:         res.Header,
  3305  			HTTPStatusCode: res.StatusCode,
  3306  		},
  3307  	}
  3308  	target := &ret
  3309  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3310  		return nil, err
  3311  	}
  3312  	return ret, nil
  3313  }
  3314  
  3315  type ProjectsLocationsFederationsGetCall struct {
  3316  	s            *APIService
  3317  	name         string
  3318  	urlParams_   gensupport.URLParams
  3319  	ifNoneMatch_ string
  3320  	ctx_         context.Context
  3321  	header_      http.Header
  3322  }
  3323  
  3324  // Get: Gets the details of a single federation.
  3325  //
  3326  //   - name: The relative resource name of the metastore federation to retrieve,
  3327  //     in the following
  3328  //     form:projects/{project_number}/locations/{location_id}/federations/{federat
  3329  //     ion_id}.
  3330  func (r *ProjectsLocationsFederationsService) Get(name string) *ProjectsLocationsFederationsGetCall {
  3331  	c := &ProjectsLocationsFederationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3332  	c.name = name
  3333  	return c
  3334  }
  3335  
  3336  // Fields allows partial responses to be retrieved. See
  3337  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3338  // details.
  3339  func (c *ProjectsLocationsFederationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsGetCall {
  3340  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3341  	return c
  3342  }
  3343  
  3344  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3345  // object's ETag matches the given value. This is useful for getting updates
  3346  // only after the object has changed since the last request.
  3347  func (c *ProjectsLocationsFederationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsFederationsGetCall {
  3348  	c.ifNoneMatch_ = entityTag
  3349  	return c
  3350  }
  3351  
  3352  // Context sets the context to be used in this call's Do method.
  3353  func (c *ProjectsLocationsFederationsGetCall) Context(ctx context.Context) *ProjectsLocationsFederationsGetCall {
  3354  	c.ctx_ = ctx
  3355  	return c
  3356  }
  3357  
  3358  // Header returns a http.Header that can be modified by the caller to add
  3359  // headers to the request.
  3360  func (c *ProjectsLocationsFederationsGetCall) Header() http.Header {
  3361  	if c.header_ == nil {
  3362  		c.header_ = make(http.Header)
  3363  	}
  3364  	return c.header_
  3365  }
  3366  
  3367  func (c *ProjectsLocationsFederationsGetCall) doRequest(alt string) (*http.Response, error) {
  3368  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3369  	if c.ifNoneMatch_ != "" {
  3370  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3371  	}
  3372  	var body io.Reader = nil
  3373  	c.urlParams_.Set("alt", alt)
  3374  	c.urlParams_.Set("prettyPrint", "false")
  3375  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  3376  	urls += "?" + c.urlParams_.Encode()
  3377  	req, err := http.NewRequest("GET", urls, body)
  3378  	if err != nil {
  3379  		return nil, err
  3380  	}
  3381  	req.Header = reqHeaders
  3382  	googleapi.Expand(req.URL, map[string]string{
  3383  		"name": c.name,
  3384  	})
  3385  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3386  }
  3387  
  3388  // Do executes the "metastore.projects.locations.federations.get" call.
  3389  // Any non-2xx status code is an error. Response headers are in either
  3390  // *Federation.ServerResponse.Header or (if a response was returned at all) in
  3391  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3392  // whether the returned error was because http.StatusNotModified was returned.
  3393  func (c *ProjectsLocationsFederationsGetCall) Do(opts ...googleapi.CallOption) (*Federation, error) {
  3394  	gensupport.SetOptions(c.urlParams_, opts...)
  3395  	res, err := c.doRequest("json")
  3396  	if res != nil && res.StatusCode == http.StatusNotModified {
  3397  		if res.Body != nil {
  3398  			res.Body.Close()
  3399  		}
  3400  		return nil, gensupport.WrapError(&googleapi.Error{
  3401  			Code:   res.StatusCode,
  3402  			Header: res.Header,
  3403  		})
  3404  	}
  3405  	if err != nil {
  3406  		return nil, err
  3407  	}
  3408  	defer googleapi.CloseBody(res)
  3409  	if err := googleapi.CheckResponse(res); err != nil {
  3410  		return nil, gensupport.WrapError(err)
  3411  	}
  3412  	ret := &Federation{
  3413  		ServerResponse: googleapi.ServerResponse{
  3414  			Header:         res.Header,
  3415  			HTTPStatusCode: res.StatusCode,
  3416  		},
  3417  	}
  3418  	target := &ret
  3419  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3420  		return nil, err
  3421  	}
  3422  	return ret, nil
  3423  }
  3424  
  3425  type ProjectsLocationsFederationsGetIamPolicyCall struct {
  3426  	s            *APIService
  3427  	resource     string
  3428  	urlParams_   gensupport.URLParams
  3429  	ifNoneMatch_ string
  3430  	ctx_         context.Context
  3431  	header_      http.Header
  3432  }
  3433  
  3434  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  3435  // empty policy if the resource exists and does not have a policy set.
  3436  //
  3437  //   - resource: REQUIRED: The resource for which the policy is being requested.
  3438  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3439  //     for the appropriate value for this field.
  3440  func (r *ProjectsLocationsFederationsService) GetIamPolicy(resource string) *ProjectsLocationsFederationsGetIamPolicyCall {
  3441  	c := &ProjectsLocationsFederationsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3442  	c.resource = resource
  3443  	return c
  3444  }
  3445  
  3446  // OptionsRequestedPolicyVersion sets the optional parameter
  3447  // "options.requestedPolicyVersion": The maximum policy version that will be
  3448  // used to format the policy.Valid values are 0, 1, and 3. Requests specifying
  3449  // an invalid value will be rejected.Requests for policies with any conditional
  3450  // role bindings must specify version 3. Policies with no conditional role
  3451  // bindings may specify any valid value or leave the field unset.The policy in
  3452  // the response might use the policy version that you specified, or it might
  3453  // use a lower policy version. For example, if you specify version 3, but the
  3454  // policy has no conditional role bindings, the response uses version 1.To
  3455  // learn which resources support conditions in their IAM policies, see the IAM
  3456  // documentation
  3457  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  3458  func (c *ProjectsLocationsFederationsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsFederationsGetIamPolicyCall {
  3459  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  3460  	return c
  3461  }
  3462  
  3463  // Fields allows partial responses to be retrieved. See
  3464  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3465  // details.
  3466  func (c *ProjectsLocationsFederationsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsGetIamPolicyCall {
  3467  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3468  	return c
  3469  }
  3470  
  3471  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3472  // object's ETag matches the given value. This is useful for getting updates
  3473  // only after the object has changed since the last request.
  3474  func (c *ProjectsLocationsFederationsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsFederationsGetIamPolicyCall {
  3475  	c.ifNoneMatch_ = entityTag
  3476  	return c
  3477  }
  3478  
  3479  // Context sets the context to be used in this call's Do method.
  3480  func (c *ProjectsLocationsFederationsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsFederationsGetIamPolicyCall {
  3481  	c.ctx_ = ctx
  3482  	return c
  3483  }
  3484  
  3485  // Header returns a http.Header that can be modified by the caller to add
  3486  // headers to the request.
  3487  func (c *ProjectsLocationsFederationsGetIamPolicyCall) Header() http.Header {
  3488  	if c.header_ == nil {
  3489  		c.header_ = make(http.Header)
  3490  	}
  3491  	return c.header_
  3492  }
  3493  
  3494  func (c *ProjectsLocationsFederationsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3495  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3496  	if c.ifNoneMatch_ != "" {
  3497  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3498  	}
  3499  	var body io.Reader = nil
  3500  	c.urlParams_.Set("alt", alt)
  3501  	c.urlParams_.Set("prettyPrint", "false")
  3502  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy")
  3503  	urls += "?" + c.urlParams_.Encode()
  3504  	req, err := http.NewRequest("GET", urls, body)
  3505  	if err != nil {
  3506  		return nil, err
  3507  	}
  3508  	req.Header = reqHeaders
  3509  	googleapi.Expand(req.URL, map[string]string{
  3510  		"resource": c.resource,
  3511  	})
  3512  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3513  }
  3514  
  3515  // Do executes the "metastore.projects.locations.federations.getIamPolicy" call.
  3516  // Any non-2xx status code is an error. Response headers are in either
  3517  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3518  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3519  // whether the returned error was because http.StatusNotModified was returned.
  3520  func (c *ProjectsLocationsFederationsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3521  	gensupport.SetOptions(c.urlParams_, opts...)
  3522  	res, err := c.doRequest("json")
  3523  	if res != nil && res.StatusCode == http.StatusNotModified {
  3524  		if res.Body != nil {
  3525  			res.Body.Close()
  3526  		}
  3527  		return nil, gensupport.WrapError(&googleapi.Error{
  3528  			Code:   res.StatusCode,
  3529  			Header: res.Header,
  3530  		})
  3531  	}
  3532  	if err != nil {
  3533  		return nil, err
  3534  	}
  3535  	defer googleapi.CloseBody(res)
  3536  	if err := googleapi.CheckResponse(res); err != nil {
  3537  		return nil, gensupport.WrapError(err)
  3538  	}
  3539  	ret := &Policy{
  3540  		ServerResponse: googleapi.ServerResponse{
  3541  			Header:         res.Header,
  3542  			HTTPStatusCode: res.StatusCode,
  3543  		},
  3544  	}
  3545  	target := &ret
  3546  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3547  		return nil, err
  3548  	}
  3549  	return ret, nil
  3550  }
  3551  
  3552  type ProjectsLocationsFederationsListCall struct {
  3553  	s            *APIService
  3554  	parent       string
  3555  	urlParams_   gensupport.URLParams
  3556  	ifNoneMatch_ string
  3557  	ctx_         context.Context
  3558  	header_      http.Header
  3559  }
  3560  
  3561  // List: Lists federations in a project and location.
  3562  //
  3563  //   - parent: The relative resource name of the location of metastore
  3564  //     federations to list, in the following form:
  3565  //     projects/{project_number}/locations/{location_id}.
  3566  func (r *ProjectsLocationsFederationsService) List(parent string) *ProjectsLocationsFederationsListCall {
  3567  	c := &ProjectsLocationsFederationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3568  	c.parent = parent
  3569  	return c
  3570  }
  3571  
  3572  // Filter sets the optional parameter "filter": The filter to apply to list
  3573  // results.
  3574  func (c *ProjectsLocationsFederationsListCall) Filter(filter string) *ProjectsLocationsFederationsListCall {
  3575  	c.urlParams_.Set("filter", filter)
  3576  	return c
  3577  }
  3578  
  3579  // OrderBy sets the optional parameter "orderBy": Specify the ordering of
  3580  // results as described in Sorting Order
  3581  // (https://cloud.google.com/apis/design/design_patterns#sorting_order). If not
  3582  // specified, the results will be sorted in the default order.
  3583  func (c *ProjectsLocationsFederationsListCall) OrderBy(orderBy string) *ProjectsLocationsFederationsListCall {
  3584  	c.urlParams_.Set("orderBy", orderBy)
  3585  	return c
  3586  }
  3587  
  3588  // PageSize sets the optional parameter "pageSize": The maximum number of
  3589  // federations to return. The response may contain less than the maximum
  3590  // number. If unspecified, no more than 500 services are returned. The maximum
  3591  // value is 1000; values above 1000 are changed to 1000.
  3592  func (c *ProjectsLocationsFederationsListCall) PageSize(pageSize int64) *ProjectsLocationsFederationsListCall {
  3593  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3594  	return c
  3595  }
  3596  
  3597  // PageToken sets the optional parameter "pageToken": A page token, received
  3598  // from a previous ListFederationServices call. Provide this token to retrieve
  3599  // the subsequent page.To retrieve the first page, supply an empty page
  3600  // token.When paginating, other parameters provided to ListFederationServices
  3601  // must match the call that provided the page token.
  3602  func (c *ProjectsLocationsFederationsListCall) PageToken(pageToken string) *ProjectsLocationsFederationsListCall {
  3603  	c.urlParams_.Set("pageToken", pageToken)
  3604  	return c
  3605  }
  3606  
  3607  // Fields allows partial responses to be retrieved. See
  3608  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3609  // details.
  3610  func (c *ProjectsLocationsFederationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsListCall {
  3611  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3612  	return c
  3613  }
  3614  
  3615  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3616  // object's ETag matches the given value. This is useful for getting updates
  3617  // only after the object has changed since the last request.
  3618  func (c *ProjectsLocationsFederationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsFederationsListCall {
  3619  	c.ifNoneMatch_ = entityTag
  3620  	return c
  3621  }
  3622  
  3623  // Context sets the context to be used in this call's Do method.
  3624  func (c *ProjectsLocationsFederationsListCall) Context(ctx context.Context) *ProjectsLocationsFederationsListCall {
  3625  	c.ctx_ = ctx
  3626  	return c
  3627  }
  3628  
  3629  // Header returns a http.Header that can be modified by the caller to add
  3630  // headers to the request.
  3631  func (c *ProjectsLocationsFederationsListCall) Header() http.Header {
  3632  	if c.header_ == nil {
  3633  		c.header_ = make(http.Header)
  3634  	}
  3635  	return c.header_
  3636  }
  3637  
  3638  func (c *ProjectsLocationsFederationsListCall) doRequest(alt string) (*http.Response, error) {
  3639  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3640  	if c.ifNoneMatch_ != "" {
  3641  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3642  	}
  3643  	var body io.Reader = nil
  3644  	c.urlParams_.Set("alt", alt)
  3645  	c.urlParams_.Set("prettyPrint", "false")
  3646  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/federations")
  3647  	urls += "?" + c.urlParams_.Encode()
  3648  	req, err := http.NewRequest("GET", urls, body)
  3649  	if err != nil {
  3650  		return nil, err
  3651  	}
  3652  	req.Header = reqHeaders
  3653  	googleapi.Expand(req.URL, map[string]string{
  3654  		"parent": c.parent,
  3655  	})
  3656  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3657  }
  3658  
  3659  // Do executes the "metastore.projects.locations.federations.list" call.
  3660  // Any non-2xx status code is an error. Response headers are in either
  3661  // *ListFederationsResponse.ServerResponse.Header or (if a response was
  3662  // returned at all) in error.(*googleapi.Error).Header. Use
  3663  // googleapi.IsNotModified to check whether the returned error was because
  3664  // http.StatusNotModified was returned.
  3665  func (c *ProjectsLocationsFederationsListCall) Do(opts ...googleapi.CallOption) (*ListFederationsResponse, error) {
  3666  	gensupport.SetOptions(c.urlParams_, opts...)
  3667  	res, err := c.doRequest("json")
  3668  	if res != nil && res.StatusCode == http.StatusNotModified {
  3669  		if res.Body != nil {
  3670  			res.Body.Close()
  3671  		}
  3672  		return nil, gensupport.WrapError(&googleapi.Error{
  3673  			Code:   res.StatusCode,
  3674  			Header: res.Header,
  3675  		})
  3676  	}
  3677  	if err != nil {
  3678  		return nil, err
  3679  	}
  3680  	defer googleapi.CloseBody(res)
  3681  	if err := googleapi.CheckResponse(res); err != nil {
  3682  		return nil, gensupport.WrapError(err)
  3683  	}
  3684  	ret := &ListFederationsResponse{
  3685  		ServerResponse: googleapi.ServerResponse{
  3686  			Header:         res.Header,
  3687  			HTTPStatusCode: res.StatusCode,
  3688  		},
  3689  	}
  3690  	target := &ret
  3691  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3692  		return nil, err
  3693  	}
  3694  	return ret, nil
  3695  }
  3696  
  3697  // Pages invokes f for each page of results.
  3698  // A non-nil error returned from f will halt the iteration.
  3699  // The provided context supersedes any context provided to the Context method.
  3700  func (c *ProjectsLocationsFederationsListCall) Pages(ctx context.Context, f func(*ListFederationsResponse) error) error {
  3701  	c.ctx_ = ctx
  3702  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3703  	for {
  3704  		x, err := c.Do()
  3705  		if err != nil {
  3706  			return err
  3707  		}
  3708  		if err := f(x); err != nil {
  3709  			return err
  3710  		}
  3711  		if x.NextPageToken == "" {
  3712  			return nil
  3713  		}
  3714  		c.PageToken(x.NextPageToken)
  3715  	}
  3716  }
  3717  
  3718  type ProjectsLocationsFederationsPatchCall struct {
  3719  	s          *APIService
  3720  	name       string
  3721  	federation *Federation
  3722  	urlParams_ gensupport.URLParams
  3723  	ctx_       context.Context
  3724  	header_    http.Header
  3725  }
  3726  
  3727  // Patch: Updates the fields of a federation.
  3728  //
  3729  //   - name: Immutable. The relative resource name of the federation, of the
  3730  //     form:
  3731  //     projects/{project_number}/locations/{location_id}/federations/{federation_i
  3732  //     d}`.
  3733  func (r *ProjectsLocationsFederationsService) Patch(name string, federation *Federation) *ProjectsLocationsFederationsPatchCall {
  3734  	c := &ProjectsLocationsFederationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3735  	c.name = name
  3736  	c.federation = federation
  3737  	return c
  3738  }
  3739  
  3740  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  3741  // unique request ID to allow the server to ignore the request if it has
  3742  // completed. The server will ignore subsequent requests that provide a
  3743  // duplicate request ID for at least 60 minutes after the first request.For
  3744  // example, if an initial request times out, followed by another request with
  3745  // the same request ID, the server ignores the second request to prevent the
  3746  // creation of duplicate commitments.The request ID must be a valid UUID
  3747  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  3748  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  3749  func (c *ProjectsLocationsFederationsPatchCall) RequestId(requestId string) *ProjectsLocationsFederationsPatchCall {
  3750  	c.urlParams_.Set("requestId", requestId)
  3751  	return c
  3752  }
  3753  
  3754  // UpdateMask sets the optional parameter "updateMask": Required. A field mask
  3755  // used to specify the fields to be overwritten in the metastore federation
  3756  // resource by the update. Fields specified in the update_mask are relative to
  3757  // the resource (not to the full request). A field is overwritten if it is in
  3758  // the mask.
  3759  func (c *ProjectsLocationsFederationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsFederationsPatchCall {
  3760  	c.urlParams_.Set("updateMask", updateMask)
  3761  	return c
  3762  }
  3763  
  3764  // Fields allows partial responses to be retrieved. See
  3765  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3766  // details.
  3767  func (c *ProjectsLocationsFederationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsPatchCall {
  3768  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3769  	return c
  3770  }
  3771  
  3772  // Context sets the context to be used in this call's Do method.
  3773  func (c *ProjectsLocationsFederationsPatchCall) Context(ctx context.Context) *ProjectsLocationsFederationsPatchCall {
  3774  	c.ctx_ = ctx
  3775  	return c
  3776  }
  3777  
  3778  // Header returns a http.Header that can be modified by the caller to add
  3779  // headers to the request.
  3780  func (c *ProjectsLocationsFederationsPatchCall) Header() http.Header {
  3781  	if c.header_ == nil {
  3782  		c.header_ = make(http.Header)
  3783  	}
  3784  	return c.header_
  3785  }
  3786  
  3787  func (c *ProjectsLocationsFederationsPatchCall) doRequest(alt string) (*http.Response, error) {
  3788  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3789  	var body io.Reader = nil
  3790  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.federation)
  3791  	if err != nil {
  3792  		return nil, err
  3793  	}
  3794  	c.urlParams_.Set("alt", alt)
  3795  	c.urlParams_.Set("prettyPrint", "false")
  3796  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  3797  	urls += "?" + c.urlParams_.Encode()
  3798  	req, err := http.NewRequest("PATCH", urls, body)
  3799  	if err != nil {
  3800  		return nil, err
  3801  	}
  3802  	req.Header = reqHeaders
  3803  	googleapi.Expand(req.URL, map[string]string{
  3804  		"name": c.name,
  3805  	})
  3806  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3807  }
  3808  
  3809  // Do executes the "metastore.projects.locations.federations.patch" call.
  3810  // Any non-2xx status code is an error. Response headers are in either
  3811  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3812  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3813  // whether the returned error was because http.StatusNotModified was returned.
  3814  func (c *ProjectsLocationsFederationsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3815  	gensupport.SetOptions(c.urlParams_, opts...)
  3816  	res, err := c.doRequest("json")
  3817  	if res != nil && res.StatusCode == http.StatusNotModified {
  3818  		if res.Body != nil {
  3819  			res.Body.Close()
  3820  		}
  3821  		return nil, gensupport.WrapError(&googleapi.Error{
  3822  			Code:   res.StatusCode,
  3823  			Header: res.Header,
  3824  		})
  3825  	}
  3826  	if err != nil {
  3827  		return nil, err
  3828  	}
  3829  	defer googleapi.CloseBody(res)
  3830  	if err := googleapi.CheckResponse(res); err != nil {
  3831  		return nil, gensupport.WrapError(err)
  3832  	}
  3833  	ret := &Operation{
  3834  		ServerResponse: googleapi.ServerResponse{
  3835  			Header:         res.Header,
  3836  			HTTPStatusCode: res.StatusCode,
  3837  		},
  3838  	}
  3839  	target := &ret
  3840  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3841  		return nil, err
  3842  	}
  3843  	return ret, nil
  3844  }
  3845  
  3846  type ProjectsLocationsFederationsSetIamPolicyCall struct {
  3847  	s                   *APIService
  3848  	resource            string
  3849  	setiampolicyrequest *SetIamPolicyRequest
  3850  	urlParams_          gensupport.URLParams
  3851  	ctx_                context.Context
  3852  	header_             http.Header
  3853  }
  3854  
  3855  // SetIamPolicy: Sets the access control policy on the specified resource.
  3856  // Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and
  3857  // PERMISSION_DENIED errors.
  3858  //
  3859  //   - resource: REQUIRED: The resource for which the policy is being specified.
  3860  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3861  //     for the appropriate value for this field.
  3862  func (r *ProjectsLocationsFederationsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsFederationsSetIamPolicyCall {
  3863  	c := &ProjectsLocationsFederationsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3864  	c.resource = resource
  3865  	c.setiampolicyrequest = setiampolicyrequest
  3866  	return c
  3867  }
  3868  
  3869  // Fields allows partial responses to be retrieved. See
  3870  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3871  // details.
  3872  func (c *ProjectsLocationsFederationsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsSetIamPolicyCall {
  3873  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3874  	return c
  3875  }
  3876  
  3877  // Context sets the context to be used in this call's Do method.
  3878  func (c *ProjectsLocationsFederationsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsFederationsSetIamPolicyCall {
  3879  	c.ctx_ = ctx
  3880  	return c
  3881  }
  3882  
  3883  // Header returns a http.Header that can be modified by the caller to add
  3884  // headers to the request.
  3885  func (c *ProjectsLocationsFederationsSetIamPolicyCall) Header() http.Header {
  3886  	if c.header_ == nil {
  3887  		c.header_ = make(http.Header)
  3888  	}
  3889  	return c.header_
  3890  }
  3891  
  3892  func (c *ProjectsLocationsFederationsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3893  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3894  	var body io.Reader = nil
  3895  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  3896  	if err != nil {
  3897  		return nil, err
  3898  	}
  3899  	c.urlParams_.Set("alt", alt)
  3900  	c.urlParams_.Set("prettyPrint", "false")
  3901  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy")
  3902  	urls += "?" + c.urlParams_.Encode()
  3903  	req, err := http.NewRequest("POST", urls, body)
  3904  	if err != nil {
  3905  		return nil, err
  3906  	}
  3907  	req.Header = reqHeaders
  3908  	googleapi.Expand(req.URL, map[string]string{
  3909  		"resource": c.resource,
  3910  	})
  3911  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3912  }
  3913  
  3914  // Do executes the "metastore.projects.locations.federations.setIamPolicy" call.
  3915  // Any non-2xx status code is an error. Response headers are in either
  3916  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3917  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3918  // whether the returned error was because http.StatusNotModified was returned.
  3919  func (c *ProjectsLocationsFederationsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3920  	gensupport.SetOptions(c.urlParams_, opts...)
  3921  	res, err := c.doRequest("json")
  3922  	if res != nil && res.StatusCode == http.StatusNotModified {
  3923  		if res.Body != nil {
  3924  			res.Body.Close()
  3925  		}
  3926  		return nil, gensupport.WrapError(&googleapi.Error{
  3927  			Code:   res.StatusCode,
  3928  			Header: res.Header,
  3929  		})
  3930  	}
  3931  	if err != nil {
  3932  		return nil, err
  3933  	}
  3934  	defer googleapi.CloseBody(res)
  3935  	if err := googleapi.CheckResponse(res); err != nil {
  3936  		return nil, gensupport.WrapError(err)
  3937  	}
  3938  	ret := &Policy{
  3939  		ServerResponse: googleapi.ServerResponse{
  3940  			Header:         res.Header,
  3941  			HTTPStatusCode: res.StatusCode,
  3942  		},
  3943  	}
  3944  	target := &ret
  3945  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3946  		return nil, err
  3947  	}
  3948  	return ret, nil
  3949  }
  3950  
  3951  type ProjectsLocationsFederationsTestIamPermissionsCall struct {
  3952  	s                         *APIService
  3953  	resource                  string
  3954  	testiampermissionsrequest *TestIamPermissionsRequest
  3955  	urlParams_                gensupport.URLParams
  3956  	ctx_                      context.Context
  3957  	header_                   http.Header
  3958  }
  3959  
  3960  // TestIamPermissions: Returns permissions that a caller has on the specified
  3961  // resource. If the resource does not exist, this will return an empty set of
  3962  // permissions, not a NOT_FOUND error.Note: This operation is designed to be
  3963  // used for building permission-aware UIs and command-line tools, not for
  3964  // authorization checking. This operation may "fail open" without warning.
  3965  //
  3966  //   - resource: REQUIRED: The resource for which the policy detail is being
  3967  //     requested. See Resource names
  3968  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  3969  //     value for this field.
  3970  func (r *ProjectsLocationsFederationsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsFederationsTestIamPermissionsCall {
  3971  	c := &ProjectsLocationsFederationsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3972  	c.resource = resource
  3973  	c.testiampermissionsrequest = testiampermissionsrequest
  3974  	return c
  3975  }
  3976  
  3977  // Fields allows partial responses to be retrieved. See
  3978  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3979  // details.
  3980  func (c *ProjectsLocationsFederationsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsFederationsTestIamPermissionsCall {
  3981  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3982  	return c
  3983  }
  3984  
  3985  // Context sets the context to be used in this call's Do method.
  3986  func (c *ProjectsLocationsFederationsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsFederationsTestIamPermissionsCall {
  3987  	c.ctx_ = ctx
  3988  	return c
  3989  }
  3990  
  3991  // Header returns a http.Header that can be modified by the caller to add
  3992  // headers to the request.
  3993  func (c *ProjectsLocationsFederationsTestIamPermissionsCall) Header() http.Header {
  3994  	if c.header_ == nil {
  3995  		c.header_ = make(http.Header)
  3996  	}
  3997  	return c.header_
  3998  }
  3999  
  4000  func (c *ProjectsLocationsFederationsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  4001  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4002  	var body io.Reader = nil
  4003  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  4004  	if err != nil {
  4005  		return nil, err
  4006  	}
  4007  	c.urlParams_.Set("alt", alt)
  4008  	c.urlParams_.Set("prettyPrint", "false")
  4009  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions")
  4010  	urls += "?" + c.urlParams_.Encode()
  4011  	req, err := http.NewRequest("POST", urls, body)
  4012  	if err != nil {
  4013  		return nil, err
  4014  	}
  4015  	req.Header = reqHeaders
  4016  	googleapi.Expand(req.URL, map[string]string{
  4017  		"resource": c.resource,
  4018  	})
  4019  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4020  }
  4021  
  4022  // Do executes the "metastore.projects.locations.federations.testIamPermissions" call.
  4023  // Any non-2xx status code is an error. Response headers are in either
  4024  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  4025  // returned at all) in error.(*googleapi.Error).Header. Use
  4026  // googleapi.IsNotModified to check whether the returned error was because
  4027  // http.StatusNotModified was returned.
  4028  func (c *ProjectsLocationsFederationsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  4029  	gensupport.SetOptions(c.urlParams_, opts...)
  4030  	res, err := c.doRequest("json")
  4031  	if res != nil && res.StatusCode == http.StatusNotModified {
  4032  		if res.Body != nil {
  4033  			res.Body.Close()
  4034  		}
  4035  		return nil, gensupport.WrapError(&googleapi.Error{
  4036  			Code:   res.StatusCode,
  4037  			Header: res.Header,
  4038  		})
  4039  	}
  4040  	if err != nil {
  4041  		return nil, err
  4042  	}
  4043  	defer googleapi.CloseBody(res)
  4044  	if err := googleapi.CheckResponse(res); err != nil {
  4045  		return nil, gensupport.WrapError(err)
  4046  	}
  4047  	ret := &TestIamPermissionsResponse{
  4048  		ServerResponse: googleapi.ServerResponse{
  4049  			Header:         res.Header,
  4050  			HTTPStatusCode: res.StatusCode,
  4051  		},
  4052  	}
  4053  	target := &ret
  4054  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4055  		return nil, err
  4056  	}
  4057  	return ret, nil
  4058  }
  4059  
  4060  type ProjectsLocationsOperationsCancelCall struct {
  4061  	s                      *APIService
  4062  	name                   string
  4063  	canceloperationrequest *CancelOperationRequest
  4064  	urlParams_             gensupport.URLParams
  4065  	ctx_                   context.Context
  4066  	header_                http.Header
  4067  }
  4068  
  4069  // Cancel: Starts asynchronous cancellation on a long-running operation. The
  4070  // server makes a best effort to cancel the operation, but success is not
  4071  // guaranteed. If the server doesn't support this method, it returns
  4072  // google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or
  4073  // other methods to check whether the cancellation succeeded or whether the
  4074  // operation completed despite cancellation. On successful cancellation, the
  4075  // operation is not deleted; instead, it becomes an operation with an
  4076  // Operation.error value with a google.rpc.Status.code of 1, corresponding to
  4077  // Code.CANCELLED.
  4078  //
  4079  // - name: The name of the operation resource to be cancelled.
  4080  func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall {
  4081  	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4082  	c.name = name
  4083  	c.canceloperationrequest = canceloperationrequest
  4084  	return c
  4085  }
  4086  
  4087  // Fields allows partial responses to be retrieved. See
  4088  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4089  // details.
  4090  func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
  4091  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4092  	return c
  4093  }
  4094  
  4095  // Context sets the context to be used in this call's Do method.
  4096  func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
  4097  	c.ctx_ = ctx
  4098  	return c
  4099  }
  4100  
  4101  // Header returns a http.Header that can be modified by the caller to add
  4102  // headers to the request.
  4103  func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
  4104  	if c.header_ == nil {
  4105  		c.header_ = make(http.Header)
  4106  	}
  4107  	return c.header_
  4108  }
  4109  
  4110  func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
  4111  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4112  	var body io.Reader = nil
  4113  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest)
  4114  	if err != nil {
  4115  		return nil, err
  4116  	}
  4117  	c.urlParams_.Set("alt", alt)
  4118  	c.urlParams_.Set("prettyPrint", "false")
  4119  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}:cancel")
  4120  	urls += "?" + c.urlParams_.Encode()
  4121  	req, err := http.NewRequest("POST", urls, body)
  4122  	if err != nil {
  4123  		return nil, err
  4124  	}
  4125  	req.Header = reqHeaders
  4126  	googleapi.Expand(req.URL, map[string]string{
  4127  		"name": c.name,
  4128  	})
  4129  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4130  }
  4131  
  4132  // Do executes the "metastore.projects.locations.operations.cancel" call.
  4133  // Any non-2xx status code is an error. Response headers are in either
  4134  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  4135  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4136  // whether the returned error was because http.StatusNotModified was returned.
  4137  func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  4138  	gensupport.SetOptions(c.urlParams_, opts...)
  4139  	res, err := c.doRequest("json")
  4140  	if res != nil && res.StatusCode == http.StatusNotModified {
  4141  		if res.Body != nil {
  4142  			res.Body.Close()
  4143  		}
  4144  		return nil, gensupport.WrapError(&googleapi.Error{
  4145  			Code:   res.StatusCode,
  4146  			Header: res.Header,
  4147  		})
  4148  	}
  4149  	if err != nil {
  4150  		return nil, err
  4151  	}
  4152  	defer googleapi.CloseBody(res)
  4153  	if err := googleapi.CheckResponse(res); err != nil {
  4154  		return nil, gensupport.WrapError(err)
  4155  	}
  4156  	ret := &Empty{
  4157  		ServerResponse: googleapi.ServerResponse{
  4158  			Header:         res.Header,
  4159  			HTTPStatusCode: res.StatusCode,
  4160  		},
  4161  	}
  4162  	target := &ret
  4163  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4164  		return nil, err
  4165  	}
  4166  	return ret, nil
  4167  }
  4168  
  4169  type ProjectsLocationsOperationsDeleteCall struct {
  4170  	s          *APIService
  4171  	name       string
  4172  	urlParams_ gensupport.URLParams
  4173  	ctx_       context.Context
  4174  	header_    http.Header
  4175  }
  4176  
  4177  // Delete: Deletes a long-running operation. This method indicates that the
  4178  // client is no longer interested in the operation result. It does not cancel
  4179  // the operation. If the server doesn't support this method, it returns
  4180  // google.rpc.Code.UNIMPLEMENTED.
  4181  //
  4182  // - name: The name of the operation resource to be deleted.
  4183  func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall {
  4184  	c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4185  	c.name = name
  4186  	return c
  4187  }
  4188  
  4189  // Fields allows partial responses to be retrieved. See
  4190  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4191  // details.
  4192  func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall {
  4193  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4194  	return c
  4195  }
  4196  
  4197  // Context sets the context to be used in this call's Do method.
  4198  func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall {
  4199  	c.ctx_ = ctx
  4200  	return c
  4201  }
  4202  
  4203  // Header returns a http.Header that can be modified by the caller to add
  4204  // headers to the request.
  4205  func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header {
  4206  	if c.header_ == nil {
  4207  		c.header_ = make(http.Header)
  4208  	}
  4209  	return c.header_
  4210  }
  4211  
  4212  func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) {
  4213  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4214  	var body io.Reader = nil
  4215  	c.urlParams_.Set("alt", alt)
  4216  	c.urlParams_.Set("prettyPrint", "false")
  4217  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  4218  	urls += "?" + c.urlParams_.Encode()
  4219  	req, err := http.NewRequest("DELETE", urls, body)
  4220  	if err != nil {
  4221  		return nil, err
  4222  	}
  4223  	req.Header = reqHeaders
  4224  	googleapi.Expand(req.URL, map[string]string{
  4225  		"name": c.name,
  4226  	})
  4227  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4228  }
  4229  
  4230  // Do executes the "metastore.projects.locations.operations.delete" call.
  4231  // Any non-2xx status code is an error. Response headers are in either
  4232  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  4233  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4234  // whether the returned error was because http.StatusNotModified was returned.
  4235  func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  4236  	gensupport.SetOptions(c.urlParams_, opts...)
  4237  	res, err := c.doRequest("json")
  4238  	if res != nil && res.StatusCode == http.StatusNotModified {
  4239  		if res.Body != nil {
  4240  			res.Body.Close()
  4241  		}
  4242  		return nil, gensupport.WrapError(&googleapi.Error{
  4243  			Code:   res.StatusCode,
  4244  			Header: res.Header,
  4245  		})
  4246  	}
  4247  	if err != nil {
  4248  		return nil, err
  4249  	}
  4250  	defer googleapi.CloseBody(res)
  4251  	if err := googleapi.CheckResponse(res); err != nil {
  4252  		return nil, gensupport.WrapError(err)
  4253  	}
  4254  	ret := &Empty{
  4255  		ServerResponse: googleapi.ServerResponse{
  4256  			Header:         res.Header,
  4257  			HTTPStatusCode: res.StatusCode,
  4258  		},
  4259  	}
  4260  	target := &ret
  4261  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4262  		return nil, err
  4263  	}
  4264  	return ret, nil
  4265  }
  4266  
  4267  type ProjectsLocationsOperationsGetCall struct {
  4268  	s            *APIService
  4269  	name         string
  4270  	urlParams_   gensupport.URLParams
  4271  	ifNoneMatch_ string
  4272  	ctx_         context.Context
  4273  	header_      http.Header
  4274  }
  4275  
  4276  // Get: Gets the latest state of a long-running operation. Clients can use this
  4277  // method to poll the operation result at intervals as recommended by the API
  4278  // service.
  4279  //
  4280  // - name: The name of the operation resource.
  4281  func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
  4282  	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4283  	c.name = name
  4284  	return c
  4285  }
  4286  
  4287  // Fields allows partial responses to be retrieved. See
  4288  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4289  // details.
  4290  func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
  4291  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4292  	return c
  4293  }
  4294  
  4295  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4296  // object's ETag matches the given value. This is useful for getting updates
  4297  // only after the object has changed since the last request.
  4298  func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
  4299  	c.ifNoneMatch_ = entityTag
  4300  	return c
  4301  }
  4302  
  4303  // Context sets the context to be used in this call's Do method.
  4304  func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
  4305  	c.ctx_ = ctx
  4306  	return c
  4307  }
  4308  
  4309  // Header returns a http.Header that can be modified by the caller to add
  4310  // headers to the request.
  4311  func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
  4312  	if c.header_ == nil {
  4313  		c.header_ = make(http.Header)
  4314  	}
  4315  	return c.header_
  4316  }
  4317  
  4318  func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
  4319  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4320  	if c.ifNoneMatch_ != "" {
  4321  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4322  	}
  4323  	var body io.Reader = nil
  4324  	c.urlParams_.Set("alt", alt)
  4325  	c.urlParams_.Set("prettyPrint", "false")
  4326  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  4327  	urls += "?" + c.urlParams_.Encode()
  4328  	req, err := http.NewRequest("GET", urls, body)
  4329  	if err != nil {
  4330  		return nil, err
  4331  	}
  4332  	req.Header = reqHeaders
  4333  	googleapi.Expand(req.URL, map[string]string{
  4334  		"name": c.name,
  4335  	})
  4336  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4337  }
  4338  
  4339  // Do executes the "metastore.projects.locations.operations.get" call.
  4340  // Any non-2xx status code is an error. Response headers are in either
  4341  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4342  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4343  // whether the returned error was because http.StatusNotModified was returned.
  4344  func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4345  	gensupport.SetOptions(c.urlParams_, opts...)
  4346  	res, err := c.doRequest("json")
  4347  	if res != nil && res.StatusCode == http.StatusNotModified {
  4348  		if res.Body != nil {
  4349  			res.Body.Close()
  4350  		}
  4351  		return nil, gensupport.WrapError(&googleapi.Error{
  4352  			Code:   res.StatusCode,
  4353  			Header: res.Header,
  4354  		})
  4355  	}
  4356  	if err != nil {
  4357  		return nil, err
  4358  	}
  4359  	defer googleapi.CloseBody(res)
  4360  	if err := googleapi.CheckResponse(res); err != nil {
  4361  		return nil, gensupport.WrapError(err)
  4362  	}
  4363  	ret := &Operation{
  4364  		ServerResponse: googleapi.ServerResponse{
  4365  			Header:         res.Header,
  4366  			HTTPStatusCode: res.StatusCode,
  4367  		},
  4368  	}
  4369  	target := &ret
  4370  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4371  		return nil, err
  4372  	}
  4373  	return ret, nil
  4374  }
  4375  
  4376  type ProjectsLocationsOperationsListCall struct {
  4377  	s            *APIService
  4378  	name         string
  4379  	urlParams_   gensupport.URLParams
  4380  	ifNoneMatch_ string
  4381  	ctx_         context.Context
  4382  	header_      http.Header
  4383  }
  4384  
  4385  // List: Lists operations that match the specified filter in the request. If
  4386  // the server doesn't support this method, it returns UNIMPLEMENTED.
  4387  //
  4388  // - name: The name of the operation's parent resource.
  4389  func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
  4390  	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4391  	c.name = name
  4392  	return c
  4393  }
  4394  
  4395  // Filter sets the optional parameter "filter": The standard list filter.
  4396  func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
  4397  	c.urlParams_.Set("filter", filter)
  4398  	return c
  4399  }
  4400  
  4401  // PageSize sets the optional parameter "pageSize": The standard list page
  4402  // size.
  4403  func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
  4404  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4405  	return c
  4406  }
  4407  
  4408  // PageToken sets the optional parameter "pageToken": The standard list page
  4409  // token.
  4410  func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
  4411  	c.urlParams_.Set("pageToken", pageToken)
  4412  	return c
  4413  }
  4414  
  4415  // Fields allows partial responses to be retrieved. See
  4416  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4417  // details.
  4418  func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
  4419  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4420  	return c
  4421  }
  4422  
  4423  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4424  // object's ETag matches the given value. This is useful for getting updates
  4425  // only after the object has changed since the last request.
  4426  func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
  4427  	c.ifNoneMatch_ = entityTag
  4428  	return c
  4429  }
  4430  
  4431  // Context sets the context to be used in this call's Do method.
  4432  func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
  4433  	c.ctx_ = ctx
  4434  	return c
  4435  }
  4436  
  4437  // Header returns a http.Header that can be modified by the caller to add
  4438  // headers to the request.
  4439  func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
  4440  	if c.header_ == nil {
  4441  		c.header_ = make(http.Header)
  4442  	}
  4443  	return c.header_
  4444  }
  4445  
  4446  func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
  4447  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4448  	if c.ifNoneMatch_ != "" {
  4449  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4450  	}
  4451  	var body io.Reader = nil
  4452  	c.urlParams_.Set("alt", alt)
  4453  	c.urlParams_.Set("prettyPrint", "false")
  4454  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}/operations")
  4455  	urls += "?" + c.urlParams_.Encode()
  4456  	req, err := http.NewRequest("GET", urls, body)
  4457  	if err != nil {
  4458  		return nil, err
  4459  	}
  4460  	req.Header = reqHeaders
  4461  	googleapi.Expand(req.URL, map[string]string{
  4462  		"name": c.name,
  4463  	})
  4464  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4465  }
  4466  
  4467  // Do executes the "metastore.projects.locations.operations.list" call.
  4468  // Any non-2xx status code is an error. Response headers are in either
  4469  // *ListOperationsResponse.ServerResponse.Header or (if a response was returned
  4470  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  4471  // check whether the returned error was because http.StatusNotModified was
  4472  // returned.
  4473  func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
  4474  	gensupport.SetOptions(c.urlParams_, opts...)
  4475  	res, err := c.doRequest("json")
  4476  	if res != nil && res.StatusCode == http.StatusNotModified {
  4477  		if res.Body != nil {
  4478  			res.Body.Close()
  4479  		}
  4480  		return nil, gensupport.WrapError(&googleapi.Error{
  4481  			Code:   res.StatusCode,
  4482  			Header: res.Header,
  4483  		})
  4484  	}
  4485  	if err != nil {
  4486  		return nil, err
  4487  	}
  4488  	defer googleapi.CloseBody(res)
  4489  	if err := googleapi.CheckResponse(res); err != nil {
  4490  		return nil, gensupport.WrapError(err)
  4491  	}
  4492  	ret := &ListOperationsResponse{
  4493  		ServerResponse: googleapi.ServerResponse{
  4494  			Header:         res.Header,
  4495  			HTTPStatusCode: res.StatusCode,
  4496  		},
  4497  	}
  4498  	target := &ret
  4499  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4500  		return nil, err
  4501  	}
  4502  	return ret, nil
  4503  }
  4504  
  4505  // Pages invokes f for each page of results.
  4506  // A non-nil error returned from f will halt the iteration.
  4507  // The provided context supersedes any context provided to the Context method.
  4508  func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
  4509  	c.ctx_ = ctx
  4510  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4511  	for {
  4512  		x, err := c.Do()
  4513  		if err != nil {
  4514  			return err
  4515  		}
  4516  		if err := f(x); err != nil {
  4517  			return err
  4518  		}
  4519  		if x.NextPageToken == "" {
  4520  			return nil
  4521  		}
  4522  		c.PageToken(x.NextPageToken)
  4523  	}
  4524  }
  4525  
  4526  type ProjectsLocationsServicesAlterLocationCall struct {
  4527  	s                                    *APIService
  4528  	service                              string
  4529  	altermetadataresourcelocationrequest *AlterMetadataResourceLocationRequest
  4530  	urlParams_                           gensupport.URLParams
  4531  	ctx_                                 context.Context
  4532  	header_                              http.Header
  4533  }
  4534  
  4535  // AlterLocation: Alter metadata resource location. The metadata resource can
  4536  // be a database, table, or partition. This functionality only updates the
  4537  // parent directory for the respective metadata resource and does not transfer
  4538  // any existing data to the new location.
  4539  //
  4540  //   - service: The relative resource name of the metastore service to mutate
  4541  //     metadata, in the following
  4542  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  4543  func (r *ProjectsLocationsServicesService) AlterLocation(service string, altermetadataresourcelocationrequest *AlterMetadataResourceLocationRequest) *ProjectsLocationsServicesAlterLocationCall {
  4544  	c := &ProjectsLocationsServicesAlterLocationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4545  	c.service = service
  4546  	c.altermetadataresourcelocationrequest = altermetadataresourcelocationrequest
  4547  	return c
  4548  }
  4549  
  4550  // Fields allows partial responses to be retrieved. See
  4551  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4552  // details.
  4553  func (c *ProjectsLocationsServicesAlterLocationCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesAlterLocationCall {
  4554  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4555  	return c
  4556  }
  4557  
  4558  // Context sets the context to be used in this call's Do method.
  4559  func (c *ProjectsLocationsServicesAlterLocationCall) Context(ctx context.Context) *ProjectsLocationsServicesAlterLocationCall {
  4560  	c.ctx_ = ctx
  4561  	return c
  4562  }
  4563  
  4564  // Header returns a http.Header that can be modified by the caller to add
  4565  // headers to the request.
  4566  func (c *ProjectsLocationsServicesAlterLocationCall) Header() http.Header {
  4567  	if c.header_ == nil {
  4568  		c.header_ = make(http.Header)
  4569  	}
  4570  	return c.header_
  4571  }
  4572  
  4573  func (c *ProjectsLocationsServicesAlterLocationCall) doRequest(alt string) (*http.Response, error) {
  4574  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4575  	var body io.Reader = nil
  4576  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.altermetadataresourcelocationrequest)
  4577  	if err != nil {
  4578  		return nil, err
  4579  	}
  4580  	c.urlParams_.Set("alt", alt)
  4581  	c.urlParams_.Set("prettyPrint", "false")
  4582  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:alterLocation")
  4583  	urls += "?" + c.urlParams_.Encode()
  4584  	req, err := http.NewRequest("POST", urls, body)
  4585  	if err != nil {
  4586  		return nil, err
  4587  	}
  4588  	req.Header = reqHeaders
  4589  	googleapi.Expand(req.URL, map[string]string{
  4590  		"service": c.service,
  4591  	})
  4592  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4593  }
  4594  
  4595  // Do executes the "metastore.projects.locations.services.alterLocation" call.
  4596  // Any non-2xx status code is an error. Response headers are in either
  4597  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4598  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4599  // whether the returned error was because http.StatusNotModified was returned.
  4600  func (c *ProjectsLocationsServicesAlterLocationCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4601  	gensupport.SetOptions(c.urlParams_, opts...)
  4602  	res, err := c.doRequest("json")
  4603  	if res != nil && res.StatusCode == http.StatusNotModified {
  4604  		if res.Body != nil {
  4605  			res.Body.Close()
  4606  		}
  4607  		return nil, gensupport.WrapError(&googleapi.Error{
  4608  			Code:   res.StatusCode,
  4609  			Header: res.Header,
  4610  		})
  4611  	}
  4612  	if err != nil {
  4613  		return nil, err
  4614  	}
  4615  	defer googleapi.CloseBody(res)
  4616  	if err := googleapi.CheckResponse(res); err != nil {
  4617  		return nil, gensupport.WrapError(err)
  4618  	}
  4619  	ret := &Operation{
  4620  		ServerResponse: googleapi.ServerResponse{
  4621  			Header:         res.Header,
  4622  			HTTPStatusCode: res.StatusCode,
  4623  		},
  4624  	}
  4625  	target := &ret
  4626  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4627  		return nil, err
  4628  	}
  4629  	return ret, nil
  4630  }
  4631  
  4632  type ProjectsLocationsServicesAlterTablePropertiesCall struct {
  4633  	s                           *APIService
  4634  	service                     string
  4635  	altertablepropertiesrequest *AlterTablePropertiesRequest
  4636  	urlParams_                  gensupport.URLParams
  4637  	ctx_                        context.Context
  4638  	header_                     http.Header
  4639  }
  4640  
  4641  // AlterTableProperties: Alter metadata table properties.
  4642  //
  4643  //   - service: The relative resource name of the Dataproc Metastore service
  4644  //     that's being used to mutate metadata table properties, in the following
  4645  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  4646  func (r *ProjectsLocationsServicesService) AlterTableProperties(service string, altertablepropertiesrequest *AlterTablePropertiesRequest) *ProjectsLocationsServicesAlterTablePropertiesCall {
  4647  	c := &ProjectsLocationsServicesAlterTablePropertiesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4648  	c.service = service
  4649  	c.altertablepropertiesrequest = altertablepropertiesrequest
  4650  	return c
  4651  }
  4652  
  4653  // Fields allows partial responses to be retrieved. See
  4654  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4655  // details.
  4656  func (c *ProjectsLocationsServicesAlterTablePropertiesCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesAlterTablePropertiesCall {
  4657  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4658  	return c
  4659  }
  4660  
  4661  // Context sets the context to be used in this call's Do method.
  4662  func (c *ProjectsLocationsServicesAlterTablePropertiesCall) Context(ctx context.Context) *ProjectsLocationsServicesAlterTablePropertiesCall {
  4663  	c.ctx_ = ctx
  4664  	return c
  4665  }
  4666  
  4667  // Header returns a http.Header that can be modified by the caller to add
  4668  // headers to the request.
  4669  func (c *ProjectsLocationsServicesAlterTablePropertiesCall) Header() http.Header {
  4670  	if c.header_ == nil {
  4671  		c.header_ = make(http.Header)
  4672  	}
  4673  	return c.header_
  4674  }
  4675  
  4676  func (c *ProjectsLocationsServicesAlterTablePropertiesCall) doRequest(alt string) (*http.Response, error) {
  4677  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4678  	var body io.Reader = nil
  4679  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.altertablepropertiesrequest)
  4680  	if err != nil {
  4681  		return nil, err
  4682  	}
  4683  	c.urlParams_.Set("alt", alt)
  4684  	c.urlParams_.Set("prettyPrint", "false")
  4685  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:alterTableProperties")
  4686  	urls += "?" + c.urlParams_.Encode()
  4687  	req, err := http.NewRequest("POST", urls, body)
  4688  	if err != nil {
  4689  		return nil, err
  4690  	}
  4691  	req.Header = reqHeaders
  4692  	googleapi.Expand(req.URL, map[string]string{
  4693  		"service": c.service,
  4694  	})
  4695  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4696  }
  4697  
  4698  // Do executes the "metastore.projects.locations.services.alterTableProperties" call.
  4699  // Any non-2xx status code is an error. Response headers are in either
  4700  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4701  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4702  // whether the returned error was because http.StatusNotModified was returned.
  4703  func (c *ProjectsLocationsServicesAlterTablePropertiesCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4704  	gensupport.SetOptions(c.urlParams_, opts...)
  4705  	res, err := c.doRequest("json")
  4706  	if res != nil && res.StatusCode == http.StatusNotModified {
  4707  		if res.Body != nil {
  4708  			res.Body.Close()
  4709  		}
  4710  		return nil, gensupport.WrapError(&googleapi.Error{
  4711  			Code:   res.StatusCode,
  4712  			Header: res.Header,
  4713  		})
  4714  	}
  4715  	if err != nil {
  4716  		return nil, err
  4717  	}
  4718  	defer googleapi.CloseBody(res)
  4719  	if err := googleapi.CheckResponse(res); err != nil {
  4720  		return nil, gensupport.WrapError(err)
  4721  	}
  4722  	ret := &Operation{
  4723  		ServerResponse: googleapi.ServerResponse{
  4724  			Header:         res.Header,
  4725  			HTTPStatusCode: res.StatusCode,
  4726  		},
  4727  	}
  4728  	target := &ret
  4729  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4730  		return nil, err
  4731  	}
  4732  	return ret, nil
  4733  }
  4734  
  4735  type ProjectsLocationsServicesCancelMigrationCall struct {
  4736  	s                      *APIService
  4737  	service                string
  4738  	cancelmigrationrequest *CancelMigrationRequest
  4739  	urlParams_             gensupport.URLParams
  4740  	ctx_                   context.Context
  4741  	header_                http.Header
  4742  }
  4743  
  4744  // CancelMigration: Cancels the ongoing Managed Migration process.
  4745  //
  4746  //   - service: The relative resource name of the metastore service to cancel the
  4747  //     ongoing migration to, in the following
  4748  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  4749  func (r *ProjectsLocationsServicesService) CancelMigration(service string, cancelmigrationrequest *CancelMigrationRequest) *ProjectsLocationsServicesCancelMigrationCall {
  4750  	c := &ProjectsLocationsServicesCancelMigrationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4751  	c.service = service
  4752  	c.cancelmigrationrequest = cancelmigrationrequest
  4753  	return c
  4754  }
  4755  
  4756  // Fields allows partial responses to be retrieved. See
  4757  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4758  // details.
  4759  func (c *ProjectsLocationsServicesCancelMigrationCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesCancelMigrationCall {
  4760  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4761  	return c
  4762  }
  4763  
  4764  // Context sets the context to be used in this call's Do method.
  4765  func (c *ProjectsLocationsServicesCancelMigrationCall) Context(ctx context.Context) *ProjectsLocationsServicesCancelMigrationCall {
  4766  	c.ctx_ = ctx
  4767  	return c
  4768  }
  4769  
  4770  // Header returns a http.Header that can be modified by the caller to add
  4771  // headers to the request.
  4772  func (c *ProjectsLocationsServicesCancelMigrationCall) Header() http.Header {
  4773  	if c.header_ == nil {
  4774  		c.header_ = make(http.Header)
  4775  	}
  4776  	return c.header_
  4777  }
  4778  
  4779  func (c *ProjectsLocationsServicesCancelMigrationCall) doRequest(alt string) (*http.Response, error) {
  4780  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4781  	var body io.Reader = nil
  4782  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.cancelmigrationrequest)
  4783  	if err != nil {
  4784  		return nil, err
  4785  	}
  4786  	c.urlParams_.Set("alt", alt)
  4787  	c.urlParams_.Set("prettyPrint", "false")
  4788  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:cancelMigration")
  4789  	urls += "?" + c.urlParams_.Encode()
  4790  	req, err := http.NewRequest("POST", urls, body)
  4791  	if err != nil {
  4792  		return nil, err
  4793  	}
  4794  	req.Header = reqHeaders
  4795  	googleapi.Expand(req.URL, map[string]string{
  4796  		"service": c.service,
  4797  	})
  4798  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4799  }
  4800  
  4801  // Do executes the "metastore.projects.locations.services.cancelMigration" call.
  4802  // Any non-2xx status code is an error. Response headers are in either
  4803  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4804  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4805  // whether the returned error was because http.StatusNotModified was returned.
  4806  func (c *ProjectsLocationsServicesCancelMigrationCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4807  	gensupport.SetOptions(c.urlParams_, opts...)
  4808  	res, err := c.doRequest("json")
  4809  	if res != nil && res.StatusCode == http.StatusNotModified {
  4810  		if res.Body != nil {
  4811  			res.Body.Close()
  4812  		}
  4813  		return nil, gensupport.WrapError(&googleapi.Error{
  4814  			Code:   res.StatusCode,
  4815  			Header: res.Header,
  4816  		})
  4817  	}
  4818  	if err != nil {
  4819  		return nil, err
  4820  	}
  4821  	defer googleapi.CloseBody(res)
  4822  	if err := googleapi.CheckResponse(res); err != nil {
  4823  		return nil, gensupport.WrapError(err)
  4824  	}
  4825  	ret := &Operation{
  4826  		ServerResponse: googleapi.ServerResponse{
  4827  			Header:         res.Header,
  4828  			HTTPStatusCode: res.StatusCode,
  4829  		},
  4830  	}
  4831  	target := &ret
  4832  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4833  		return nil, err
  4834  	}
  4835  	return ret, nil
  4836  }
  4837  
  4838  type ProjectsLocationsServicesCompleteMigrationCall struct {
  4839  	s                        *APIService
  4840  	service                  string
  4841  	completemigrationrequest *CompleteMigrationRequest
  4842  	urlParams_               gensupport.URLParams
  4843  	ctx_                     context.Context
  4844  	header_                  http.Header
  4845  }
  4846  
  4847  // CompleteMigration: Completes the managed migration process. The Dataproc
  4848  // Metastore service will switch to using its own backend database after
  4849  // successful migration.
  4850  //
  4851  //   - service: The relative resource name of the metastore service to complete
  4852  //     the migration to, in the following
  4853  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  4854  func (r *ProjectsLocationsServicesService) CompleteMigration(service string, completemigrationrequest *CompleteMigrationRequest) *ProjectsLocationsServicesCompleteMigrationCall {
  4855  	c := &ProjectsLocationsServicesCompleteMigrationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4856  	c.service = service
  4857  	c.completemigrationrequest = completemigrationrequest
  4858  	return c
  4859  }
  4860  
  4861  // Fields allows partial responses to be retrieved. See
  4862  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4863  // details.
  4864  func (c *ProjectsLocationsServicesCompleteMigrationCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesCompleteMigrationCall {
  4865  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4866  	return c
  4867  }
  4868  
  4869  // Context sets the context to be used in this call's Do method.
  4870  func (c *ProjectsLocationsServicesCompleteMigrationCall) Context(ctx context.Context) *ProjectsLocationsServicesCompleteMigrationCall {
  4871  	c.ctx_ = ctx
  4872  	return c
  4873  }
  4874  
  4875  // Header returns a http.Header that can be modified by the caller to add
  4876  // headers to the request.
  4877  func (c *ProjectsLocationsServicesCompleteMigrationCall) Header() http.Header {
  4878  	if c.header_ == nil {
  4879  		c.header_ = make(http.Header)
  4880  	}
  4881  	return c.header_
  4882  }
  4883  
  4884  func (c *ProjectsLocationsServicesCompleteMigrationCall) doRequest(alt string) (*http.Response, error) {
  4885  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4886  	var body io.Reader = nil
  4887  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.completemigrationrequest)
  4888  	if err != nil {
  4889  		return nil, err
  4890  	}
  4891  	c.urlParams_.Set("alt", alt)
  4892  	c.urlParams_.Set("prettyPrint", "false")
  4893  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:completeMigration")
  4894  	urls += "?" + c.urlParams_.Encode()
  4895  	req, err := http.NewRequest("POST", urls, body)
  4896  	if err != nil {
  4897  		return nil, err
  4898  	}
  4899  	req.Header = reqHeaders
  4900  	googleapi.Expand(req.URL, map[string]string{
  4901  		"service": c.service,
  4902  	})
  4903  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4904  }
  4905  
  4906  // Do executes the "metastore.projects.locations.services.completeMigration" call.
  4907  // Any non-2xx status code is an error. Response headers are in either
  4908  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4909  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4910  // whether the returned error was because http.StatusNotModified was returned.
  4911  func (c *ProjectsLocationsServicesCompleteMigrationCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4912  	gensupport.SetOptions(c.urlParams_, opts...)
  4913  	res, err := c.doRequest("json")
  4914  	if res != nil && res.StatusCode == http.StatusNotModified {
  4915  		if res.Body != nil {
  4916  			res.Body.Close()
  4917  		}
  4918  		return nil, gensupport.WrapError(&googleapi.Error{
  4919  			Code:   res.StatusCode,
  4920  			Header: res.Header,
  4921  		})
  4922  	}
  4923  	if err != nil {
  4924  		return nil, err
  4925  	}
  4926  	defer googleapi.CloseBody(res)
  4927  	if err := googleapi.CheckResponse(res); err != nil {
  4928  		return nil, gensupport.WrapError(err)
  4929  	}
  4930  	ret := &Operation{
  4931  		ServerResponse: googleapi.ServerResponse{
  4932  			Header:         res.Header,
  4933  			HTTPStatusCode: res.StatusCode,
  4934  		},
  4935  	}
  4936  	target := &ret
  4937  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4938  		return nil, err
  4939  	}
  4940  	return ret, nil
  4941  }
  4942  
  4943  type ProjectsLocationsServicesCreateCall struct {
  4944  	s          *APIService
  4945  	parent     string
  4946  	service    *Service
  4947  	urlParams_ gensupport.URLParams
  4948  	ctx_       context.Context
  4949  	header_    http.Header
  4950  }
  4951  
  4952  // Create: Creates a metastore service in a project and location.
  4953  //
  4954  //   - parent: The relative resource name of the location in which to create a
  4955  //     metastore service, in the following
  4956  //     form:projects/{project_number}/locations/{location_id}.
  4957  func (r *ProjectsLocationsServicesService) Create(parent string, service *Service) *ProjectsLocationsServicesCreateCall {
  4958  	c := &ProjectsLocationsServicesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4959  	c.parent = parent
  4960  	c.service = service
  4961  	return c
  4962  }
  4963  
  4964  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  4965  // unique request ID to allow the server to ignore the request if it has
  4966  // completed. The server will ignore subsequent requests that provide a
  4967  // duplicate request ID for at least 60 minutes after the first request.For
  4968  // example, if an initial request times out, followed by another request with
  4969  // the same request ID, the server ignores the second request to prevent the
  4970  // creation of duplicate commitments.The request ID must be a valid UUID
  4971  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  4972  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  4973  func (c *ProjectsLocationsServicesCreateCall) RequestId(requestId string) *ProjectsLocationsServicesCreateCall {
  4974  	c.urlParams_.Set("requestId", requestId)
  4975  	return c
  4976  }
  4977  
  4978  // ServiceId sets the optional parameter "serviceId": Required. The ID of the
  4979  // metastore service, which is used as the final component of the metastore
  4980  // service's name.This value must be between 2 and 63 characters long
  4981  // inclusive, begin with a letter, end with a letter or number, and consist of
  4982  // alpha-numeric ASCII characters or hyphens.
  4983  func (c *ProjectsLocationsServicesCreateCall) ServiceId(serviceId string) *ProjectsLocationsServicesCreateCall {
  4984  	c.urlParams_.Set("serviceId", serviceId)
  4985  	return c
  4986  }
  4987  
  4988  // Fields allows partial responses to be retrieved. See
  4989  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4990  // details.
  4991  func (c *ProjectsLocationsServicesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesCreateCall {
  4992  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4993  	return c
  4994  }
  4995  
  4996  // Context sets the context to be used in this call's Do method.
  4997  func (c *ProjectsLocationsServicesCreateCall) Context(ctx context.Context) *ProjectsLocationsServicesCreateCall {
  4998  	c.ctx_ = ctx
  4999  	return c
  5000  }
  5001  
  5002  // Header returns a http.Header that can be modified by the caller to add
  5003  // headers to the request.
  5004  func (c *ProjectsLocationsServicesCreateCall) Header() http.Header {
  5005  	if c.header_ == nil {
  5006  		c.header_ = make(http.Header)
  5007  	}
  5008  	return c.header_
  5009  }
  5010  
  5011  func (c *ProjectsLocationsServicesCreateCall) doRequest(alt string) (*http.Response, error) {
  5012  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5013  	var body io.Reader = nil
  5014  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.service)
  5015  	if err != nil {
  5016  		return nil, err
  5017  	}
  5018  	c.urlParams_.Set("alt", alt)
  5019  	c.urlParams_.Set("prettyPrint", "false")
  5020  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/services")
  5021  	urls += "?" + c.urlParams_.Encode()
  5022  	req, err := http.NewRequest("POST", urls, body)
  5023  	if err != nil {
  5024  		return nil, err
  5025  	}
  5026  	req.Header = reqHeaders
  5027  	googleapi.Expand(req.URL, map[string]string{
  5028  		"parent": c.parent,
  5029  	})
  5030  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5031  }
  5032  
  5033  // Do executes the "metastore.projects.locations.services.create" call.
  5034  // Any non-2xx status code is an error. Response headers are in either
  5035  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5036  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5037  // whether the returned error was because http.StatusNotModified was returned.
  5038  func (c *ProjectsLocationsServicesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5039  	gensupport.SetOptions(c.urlParams_, opts...)
  5040  	res, err := c.doRequest("json")
  5041  	if res != nil && res.StatusCode == http.StatusNotModified {
  5042  		if res.Body != nil {
  5043  			res.Body.Close()
  5044  		}
  5045  		return nil, gensupport.WrapError(&googleapi.Error{
  5046  			Code:   res.StatusCode,
  5047  			Header: res.Header,
  5048  		})
  5049  	}
  5050  	if err != nil {
  5051  		return nil, err
  5052  	}
  5053  	defer googleapi.CloseBody(res)
  5054  	if err := googleapi.CheckResponse(res); err != nil {
  5055  		return nil, gensupport.WrapError(err)
  5056  	}
  5057  	ret := &Operation{
  5058  		ServerResponse: googleapi.ServerResponse{
  5059  			Header:         res.Header,
  5060  			HTTPStatusCode: res.StatusCode,
  5061  		},
  5062  	}
  5063  	target := &ret
  5064  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5065  		return nil, err
  5066  	}
  5067  	return ret, nil
  5068  }
  5069  
  5070  type ProjectsLocationsServicesDeleteCall struct {
  5071  	s          *APIService
  5072  	name       string
  5073  	urlParams_ gensupport.URLParams
  5074  	ctx_       context.Context
  5075  	header_    http.Header
  5076  }
  5077  
  5078  // Delete: Deletes a single service.
  5079  //
  5080  //   - name: The relative resource name of the metastore service to delete, in
  5081  //     the following
  5082  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  5083  //     }.
  5084  func (r *ProjectsLocationsServicesService) Delete(name string) *ProjectsLocationsServicesDeleteCall {
  5085  	c := &ProjectsLocationsServicesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5086  	c.name = name
  5087  	return c
  5088  }
  5089  
  5090  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  5091  // unique request ID to allow the server to ignore the request if it has
  5092  // completed. The server will ignore subsequent requests that provide a
  5093  // duplicate request ID for at least 60 minutes after the first request.For
  5094  // example, if an initial request times out, followed by another request with
  5095  // the same request ID, the server ignores the second request to prevent the
  5096  // creation of duplicate commitments.The request ID must be a valid UUID
  5097  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  5098  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  5099  func (c *ProjectsLocationsServicesDeleteCall) RequestId(requestId string) *ProjectsLocationsServicesDeleteCall {
  5100  	c.urlParams_.Set("requestId", requestId)
  5101  	return c
  5102  }
  5103  
  5104  // Fields allows partial responses to be retrieved. See
  5105  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5106  // details.
  5107  func (c *ProjectsLocationsServicesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDeleteCall {
  5108  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5109  	return c
  5110  }
  5111  
  5112  // Context sets the context to be used in this call's Do method.
  5113  func (c *ProjectsLocationsServicesDeleteCall) Context(ctx context.Context) *ProjectsLocationsServicesDeleteCall {
  5114  	c.ctx_ = ctx
  5115  	return c
  5116  }
  5117  
  5118  // Header returns a http.Header that can be modified by the caller to add
  5119  // headers to the request.
  5120  func (c *ProjectsLocationsServicesDeleteCall) Header() http.Header {
  5121  	if c.header_ == nil {
  5122  		c.header_ = make(http.Header)
  5123  	}
  5124  	return c.header_
  5125  }
  5126  
  5127  func (c *ProjectsLocationsServicesDeleteCall) doRequest(alt string) (*http.Response, error) {
  5128  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  5129  	var body io.Reader = nil
  5130  	c.urlParams_.Set("alt", alt)
  5131  	c.urlParams_.Set("prettyPrint", "false")
  5132  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  5133  	urls += "?" + c.urlParams_.Encode()
  5134  	req, err := http.NewRequest("DELETE", urls, body)
  5135  	if err != nil {
  5136  		return nil, err
  5137  	}
  5138  	req.Header = reqHeaders
  5139  	googleapi.Expand(req.URL, map[string]string{
  5140  		"name": c.name,
  5141  	})
  5142  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5143  }
  5144  
  5145  // Do executes the "metastore.projects.locations.services.delete" call.
  5146  // Any non-2xx status code is an error. Response headers are in either
  5147  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5148  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5149  // whether the returned error was because http.StatusNotModified was returned.
  5150  func (c *ProjectsLocationsServicesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5151  	gensupport.SetOptions(c.urlParams_, opts...)
  5152  	res, err := c.doRequest("json")
  5153  	if res != nil && res.StatusCode == http.StatusNotModified {
  5154  		if res.Body != nil {
  5155  			res.Body.Close()
  5156  		}
  5157  		return nil, gensupport.WrapError(&googleapi.Error{
  5158  			Code:   res.StatusCode,
  5159  			Header: res.Header,
  5160  		})
  5161  	}
  5162  	if err != nil {
  5163  		return nil, err
  5164  	}
  5165  	defer googleapi.CloseBody(res)
  5166  	if err := googleapi.CheckResponse(res); err != nil {
  5167  		return nil, gensupport.WrapError(err)
  5168  	}
  5169  	ret := &Operation{
  5170  		ServerResponse: googleapi.ServerResponse{
  5171  			Header:         res.Header,
  5172  			HTTPStatusCode: res.StatusCode,
  5173  		},
  5174  	}
  5175  	target := &ret
  5176  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5177  		return nil, err
  5178  	}
  5179  	return ret, nil
  5180  }
  5181  
  5182  type ProjectsLocationsServicesExportMetadataCall struct {
  5183  	s                     *APIService
  5184  	service               string
  5185  	exportmetadatarequest *ExportMetadataRequest
  5186  	urlParams_            gensupport.URLParams
  5187  	ctx_                  context.Context
  5188  	header_               http.Header
  5189  }
  5190  
  5191  // ExportMetadata: Exports metadata from a service.
  5192  //
  5193  //   - service: The relative resource name of the metastore service to run
  5194  //     export, in the following
  5195  //     form:projects/{project_id}/locations/{location_id}/services/{service_id}.
  5196  func (r *ProjectsLocationsServicesService) ExportMetadata(service string, exportmetadatarequest *ExportMetadataRequest) *ProjectsLocationsServicesExportMetadataCall {
  5197  	c := &ProjectsLocationsServicesExportMetadataCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5198  	c.service = service
  5199  	c.exportmetadatarequest = exportmetadatarequest
  5200  	return c
  5201  }
  5202  
  5203  // Fields allows partial responses to be retrieved. See
  5204  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5205  // details.
  5206  func (c *ProjectsLocationsServicesExportMetadataCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesExportMetadataCall {
  5207  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5208  	return c
  5209  }
  5210  
  5211  // Context sets the context to be used in this call's Do method.
  5212  func (c *ProjectsLocationsServicesExportMetadataCall) Context(ctx context.Context) *ProjectsLocationsServicesExportMetadataCall {
  5213  	c.ctx_ = ctx
  5214  	return c
  5215  }
  5216  
  5217  // Header returns a http.Header that can be modified by the caller to add
  5218  // headers to the request.
  5219  func (c *ProjectsLocationsServicesExportMetadataCall) Header() http.Header {
  5220  	if c.header_ == nil {
  5221  		c.header_ = make(http.Header)
  5222  	}
  5223  	return c.header_
  5224  }
  5225  
  5226  func (c *ProjectsLocationsServicesExportMetadataCall) doRequest(alt string) (*http.Response, error) {
  5227  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5228  	var body io.Reader = nil
  5229  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.exportmetadatarequest)
  5230  	if err != nil {
  5231  		return nil, err
  5232  	}
  5233  	c.urlParams_.Set("alt", alt)
  5234  	c.urlParams_.Set("prettyPrint", "false")
  5235  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:exportMetadata")
  5236  	urls += "?" + c.urlParams_.Encode()
  5237  	req, err := http.NewRequest("POST", urls, body)
  5238  	if err != nil {
  5239  		return nil, err
  5240  	}
  5241  	req.Header = reqHeaders
  5242  	googleapi.Expand(req.URL, map[string]string{
  5243  		"service": c.service,
  5244  	})
  5245  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5246  }
  5247  
  5248  // Do executes the "metastore.projects.locations.services.exportMetadata" call.
  5249  // Any non-2xx status code is an error. Response headers are in either
  5250  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5251  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5252  // whether the returned error was because http.StatusNotModified was returned.
  5253  func (c *ProjectsLocationsServicesExportMetadataCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5254  	gensupport.SetOptions(c.urlParams_, opts...)
  5255  	res, err := c.doRequest("json")
  5256  	if res != nil && res.StatusCode == http.StatusNotModified {
  5257  		if res.Body != nil {
  5258  			res.Body.Close()
  5259  		}
  5260  		return nil, gensupport.WrapError(&googleapi.Error{
  5261  			Code:   res.StatusCode,
  5262  			Header: res.Header,
  5263  		})
  5264  	}
  5265  	if err != nil {
  5266  		return nil, err
  5267  	}
  5268  	defer googleapi.CloseBody(res)
  5269  	if err := googleapi.CheckResponse(res); err != nil {
  5270  		return nil, gensupport.WrapError(err)
  5271  	}
  5272  	ret := &Operation{
  5273  		ServerResponse: googleapi.ServerResponse{
  5274  			Header:         res.Header,
  5275  			HTTPStatusCode: res.StatusCode,
  5276  		},
  5277  	}
  5278  	target := &ret
  5279  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5280  		return nil, err
  5281  	}
  5282  	return ret, nil
  5283  }
  5284  
  5285  type ProjectsLocationsServicesGetCall struct {
  5286  	s            *APIService
  5287  	name         string
  5288  	urlParams_   gensupport.URLParams
  5289  	ifNoneMatch_ string
  5290  	ctx_         context.Context
  5291  	header_      http.Header
  5292  }
  5293  
  5294  // Get: Gets the details of a single service.
  5295  //
  5296  //   - name: The relative resource name of the metastore service to retrieve, in
  5297  //     the following
  5298  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  5299  //     }.
  5300  func (r *ProjectsLocationsServicesService) Get(name string) *ProjectsLocationsServicesGetCall {
  5301  	c := &ProjectsLocationsServicesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5302  	c.name = name
  5303  	return c
  5304  }
  5305  
  5306  // Fields allows partial responses to be retrieved. See
  5307  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5308  // details.
  5309  func (c *ProjectsLocationsServicesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesGetCall {
  5310  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5311  	return c
  5312  }
  5313  
  5314  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  5315  // object's ETag matches the given value. This is useful for getting updates
  5316  // only after the object has changed since the last request.
  5317  func (c *ProjectsLocationsServicesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesGetCall {
  5318  	c.ifNoneMatch_ = entityTag
  5319  	return c
  5320  }
  5321  
  5322  // Context sets the context to be used in this call's Do method.
  5323  func (c *ProjectsLocationsServicesGetCall) Context(ctx context.Context) *ProjectsLocationsServicesGetCall {
  5324  	c.ctx_ = ctx
  5325  	return c
  5326  }
  5327  
  5328  // Header returns a http.Header that can be modified by the caller to add
  5329  // headers to the request.
  5330  func (c *ProjectsLocationsServicesGetCall) Header() http.Header {
  5331  	if c.header_ == nil {
  5332  		c.header_ = make(http.Header)
  5333  	}
  5334  	return c.header_
  5335  }
  5336  
  5337  func (c *ProjectsLocationsServicesGetCall) doRequest(alt string) (*http.Response, error) {
  5338  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  5339  	if c.ifNoneMatch_ != "" {
  5340  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  5341  	}
  5342  	var body io.Reader = nil
  5343  	c.urlParams_.Set("alt", alt)
  5344  	c.urlParams_.Set("prettyPrint", "false")
  5345  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  5346  	urls += "?" + c.urlParams_.Encode()
  5347  	req, err := http.NewRequest("GET", urls, body)
  5348  	if err != nil {
  5349  		return nil, err
  5350  	}
  5351  	req.Header = reqHeaders
  5352  	googleapi.Expand(req.URL, map[string]string{
  5353  		"name": c.name,
  5354  	})
  5355  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5356  }
  5357  
  5358  // Do executes the "metastore.projects.locations.services.get" call.
  5359  // Any non-2xx status code is an error. Response headers are in either
  5360  // *Service.ServerResponse.Header or (if a response was returned at all) in
  5361  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5362  // whether the returned error was because http.StatusNotModified was returned.
  5363  func (c *ProjectsLocationsServicesGetCall) Do(opts ...googleapi.CallOption) (*Service, error) {
  5364  	gensupport.SetOptions(c.urlParams_, opts...)
  5365  	res, err := c.doRequest("json")
  5366  	if res != nil && res.StatusCode == http.StatusNotModified {
  5367  		if res.Body != nil {
  5368  			res.Body.Close()
  5369  		}
  5370  		return nil, gensupport.WrapError(&googleapi.Error{
  5371  			Code:   res.StatusCode,
  5372  			Header: res.Header,
  5373  		})
  5374  	}
  5375  	if err != nil {
  5376  		return nil, err
  5377  	}
  5378  	defer googleapi.CloseBody(res)
  5379  	if err := googleapi.CheckResponse(res); err != nil {
  5380  		return nil, gensupport.WrapError(err)
  5381  	}
  5382  	ret := &Service{
  5383  		ServerResponse: googleapi.ServerResponse{
  5384  			Header:         res.Header,
  5385  			HTTPStatusCode: res.StatusCode,
  5386  		},
  5387  	}
  5388  	target := &ret
  5389  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5390  		return nil, err
  5391  	}
  5392  	return ret, nil
  5393  }
  5394  
  5395  type ProjectsLocationsServicesGetIamPolicyCall struct {
  5396  	s            *APIService
  5397  	resource     string
  5398  	urlParams_   gensupport.URLParams
  5399  	ifNoneMatch_ string
  5400  	ctx_         context.Context
  5401  	header_      http.Header
  5402  }
  5403  
  5404  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  5405  // empty policy if the resource exists and does not have a policy set.
  5406  //
  5407  //   - resource: REQUIRED: The resource for which the policy is being requested.
  5408  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  5409  //     for the appropriate value for this field.
  5410  func (r *ProjectsLocationsServicesService) GetIamPolicy(resource string) *ProjectsLocationsServicesGetIamPolicyCall {
  5411  	c := &ProjectsLocationsServicesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5412  	c.resource = resource
  5413  	return c
  5414  }
  5415  
  5416  // OptionsRequestedPolicyVersion sets the optional parameter
  5417  // "options.requestedPolicyVersion": The maximum policy version that will be
  5418  // used to format the policy.Valid values are 0, 1, and 3. Requests specifying
  5419  // an invalid value will be rejected.Requests for policies with any conditional
  5420  // role bindings must specify version 3. Policies with no conditional role
  5421  // bindings may specify any valid value or leave the field unset.The policy in
  5422  // the response might use the policy version that you specified, or it might
  5423  // use a lower policy version. For example, if you specify version 3, but the
  5424  // policy has no conditional role bindings, the response uses version 1.To
  5425  // learn which resources support conditions in their IAM policies, see the IAM
  5426  // documentation
  5427  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  5428  func (c *ProjectsLocationsServicesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsServicesGetIamPolicyCall {
  5429  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  5430  	return c
  5431  }
  5432  
  5433  // Fields allows partial responses to be retrieved. See
  5434  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5435  // details.
  5436  func (c *ProjectsLocationsServicesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesGetIamPolicyCall {
  5437  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5438  	return c
  5439  }
  5440  
  5441  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  5442  // object's ETag matches the given value. This is useful for getting updates
  5443  // only after the object has changed since the last request.
  5444  func (c *ProjectsLocationsServicesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesGetIamPolicyCall {
  5445  	c.ifNoneMatch_ = entityTag
  5446  	return c
  5447  }
  5448  
  5449  // Context sets the context to be used in this call's Do method.
  5450  func (c *ProjectsLocationsServicesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesGetIamPolicyCall {
  5451  	c.ctx_ = ctx
  5452  	return c
  5453  }
  5454  
  5455  // Header returns a http.Header that can be modified by the caller to add
  5456  // headers to the request.
  5457  func (c *ProjectsLocationsServicesGetIamPolicyCall) Header() http.Header {
  5458  	if c.header_ == nil {
  5459  		c.header_ = make(http.Header)
  5460  	}
  5461  	return c.header_
  5462  }
  5463  
  5464  func (c *ProjectsLocationsServicesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  5465  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  5466  	if c.ifNoneMatch_ != "" {
  5467  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  5468  	}
  5469  	var body io.Reader = nil
  5470  	c.urlParams_.Set("alt", alt)
  5471  	c.urlParams_.Set("prettyPrint", "false")
  5472  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy")
  5473  	urls += "?" + c.urlParams_.Encode()
  5474  	req, err := http.NewRequest("GET", urls, body)
  5475  	if err != nil {
  5476  		return nil, err
  5477  	}
  5478  	req.Header = reqHeaders
  5479  	googleapi.Expand(req.URL, map[string]string{
  5480  		"resource": c.resource,
  5481  	})
  5482  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5483  }
  5484  
  5485  // Do executes the "metastore.projects.locations.services.getIamPolicy" call.
  5486  // Any non-2xx status code is an error. Response headers are in either
  5487  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  5488  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5489  // whether the returned error was because http.StatusNotModified was returned.
  5490  func (c *ProjectsLocationsServicesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  5491  	gensupport.SetOptions(c.urlParams_, opts...)
  5492  	res, err := c.doRequest("json")
  5493  	if res != nil && res.StatusCode == http.StatusNotModified {
  5494  		if res.Body != nil {
  5495  			res.Body.Close()
  5496  		}
  5497  		return nil, gensupport.WrapError(&googleapi.Error{
  5498  			Code:   res.StatusCode,
  5499  			Header: res.Header,
  5500  		})
  5501  	}
  5502  	if err != nil {
  5503  		return nil, err
  5504  	}
  5505  	defer googleapi.CloseBody(res)
  5506  	if err := googleapi.CheckResponse(res); err != nil {
  5507  		return nil, gensupport.WrapError(err)
  5508  	}
  5509  	ret := &Policy{
  5510  		ServerResponse: googleapi.ServerResponse{
  5511  			Header:         res.Header,
  5512  			HTTPStatusCode: res.StatusCode,
  5513  		},
  5514  	}
  5515  	target := &ret
  5516  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5517  		return nil, err
  5518  	}
  5519  	return ret, nil
  5520  }
  5521  
  5522  type ProjectsLocationsServicesListCall struct {
  5523  	s            *APIService
  5524  	parent       string
  5525  	urlParams_   gensupport.URLParams
  5526  	ifNoneMatch_ string
  5527  	ctx_         context.Context
  5528  	header_      http.Header
  5529  }
  5530  
  5531  // List: Lists services in a project and location.
  5532  //
  5533  //   - parent: The relative resource name of the location of metastore services
  5534  //     to list, in the following
  5535  //     form:projects/{project_number}/locations/{location_id}.
  5536  func (r *ProjectsLocationsServicesService) List(parent string) *ProjectsLocationsServicesListCall {
  5537  	c := &ProjectsLocationsServicesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5538  	c.parent = parent
  5539  	return c
  5540  }
  5541  
  5542  // Filter sets the optional parameter "filter": The filter to apply to list
  5543  // results.
  5544  func (c *ProjectsLocationsServicesListCall) Filter(filter string) *ProjectsLocationsServicesListCall {
  5545  	c.urlParams_.Set("filter", filter)
  5546  	return c
  5547  }
  5548  
  5549  // OrderBy sets the optional parameter "orderBy": Specify the ordering of
  5550  // results as described in Sorting Order
  5551  // (https://cloud.google.com/apis/design/design_patterns#sorting_order). If not
  5552  // specified, the results will be sorted in the default order.
  5553  func (c *ProjectsLocationsServicesListCall) OrderBy(orderBy string) *ProjectsLocationsServicesListCall {
  5554  	c.urlParams_.Set("orderBy", orderBy)
  5555  	return c
  5556  }
  5557  
  5558  // PageSize sets the optional parameter "pageSize": The maximum number of
  5559  // services to return. The response may contain less than the maximum number.
  5560  // If unspecified, no more than 500 services are returned. The maximum value is
  5561  // 1000; values above 1000 are changed to 1000.
  5562  func (c *ProjectsLocationsServicesListCall) PageSize(pageSize int64) *ProjectsLocationsServicesListCall {
  5563  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  5564  	return c
  5565  }
  5566  
  5567  // PageToken sets the optional parameter "pageToken": A page token, received
  5568  // from a previous DataprocMetastore.ListServices call. Provide this token to
  5569  // retrieve the subsequent page.To retrieve the first page, supply an empty
  5570  // page token.When paginating, other parameters provided to
  5571  // DataprocMetastore.ListServices must match the call that provided the page
  5572  // token.
  5573  func (c *ProjectsLocationsServicesListCall) PageToken(pageToken string) *ProjectsLocationsServicesListCall {
  5574  	c.urlParams_.Set("pageToken", pageToken)
  5575  	return c
  5576  }
  5577  
  5578  // Fields allows partial responses to be retrieved. See
  5579  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5580  // details.
  5581  func (c *ProjectsLocationsServicesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesListCall {
  5582  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5583  	return c
  5584  }
  5585  
  5586  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  5587  // object's ETag matches the given value. This is useful for getting updates
  5588  // only after the object has changed since the last request.
  5589  func (c *ProjectsLocationsServicesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesListCall {
  5590  	c.ifNoneMatch_ = entityTag
  5591  	return c
  5592  }
  5593  
  5594  // Context sets the context to be used in this call's Do method.
  5595  func (c *ProjectsLocationsServicesListCall) Context(ctx context.Context) *ProjectsLocationsServicesListCall {
  5596  	c.ctx_ = ctx
  5597  	return c
  5598  }
  5599  
  5600  // Header returns a http.Header that can be modified by the caller to add
  5601  // headers to the request.
  5602  func (c *ProjectsLocationsServicesListCall) Header() http.Header {
  5603  	if c.header_ == nil {
  5604  		c.header_ = make(http.Header)
  5605  	}
  5606  	return c.header_
  5607  }
  5608  
  5609  func (c *ProjectsLocationsServicesListCall) doRequest(alt string) (*http.Response, error) {
  5610  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  5611  	if c.ifNoneMatch_ != "" {
  5612  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  5613  	}
  5614  	var body io.Reader = nil
  5615  	c.urlParams_.Set("alt", alt)
  5616  	c.urlParams_.Set("prettyPrint", "false")
  5617  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/services")
  5618  	urls += "?" + c.urlParams_.Encode()
  5619  	req, err := http.NewRequest("GET", urls, body)
  5620  	if err != nil {
  5621  		return nil, err
  5622  	}
  5623  	req.Header = reqHeaders
  5624  	googleapi.Expand(req.URL, map[string]string{
  5625  		"parent": c.parent,
  5626  	})
  5627  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5628  }
  5629  
  5630  // Do executes the "metastore.projects.locations.services.list" call.
  5631  // Any non-2xx status code is an error. Response headers are in either
  5632  // *ListServicesResponse.ServerResponse.Header or (if a response was returned
  5633  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  5634  // check whether the returned error was because http.StatusNotModified was
  5635  // returned.
  5636  func (c *ProjectsLocationsServicesListCall) Do(opts ...googleapi.CallOption) (*ListServicesResponse, error) {
  5637  	gensupport.SetOptions(c.urlParams_, opts...)
  5638  	res, err := c.doRequest("json")
  5639  	if res != nil && res.StatusCode == http.StatusNotModified {
  5640  		if res.Body != nil {
  5641  			res.Body.Close()
  5642  		}
  5643  		return nil, gensupport.WrapError(&googleapi.Error{
  5644  			Code:   res.StatusCode,
  5645  			Header: res.Header,
  5646  		})
  5647  	}
  5648  	if err != nil {
  5649  		return nil, err
  5650  	}
  5651  	defer googleapi.CloseBody(res)
  5652  	if err := googleapi.CheckResponse(res); err != nil {
  5653  		return nil, gensupport.WrapError(err)
  5654  	}
  5655  	ret := &ListServicesResponse{
  5656  		ServerResponse: googleapi.ServerResponse{
  5657  			Header:         res.Header,
  5658  			HTTPStatusCode: res.StatusCode,
  5659  		},
  5660  	}
  5661  	target := &ret
  5662  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5663  		return nil, err
  5664  	}
  5665  	return ret, nil
  5666  }
  5667  
  5668  // Pages invokes f for each page of results.
  5669  // A non-nil error returned from f will halt the iteration.
  5670  // The provided context supersedes any context provided to the Context method.
  5671  func (c *ProjectsLocationsServicesListCall) Pages(ctx context.Context, f func(*ListServicesResponse) error) error {
  5672  	c.ctx_ = ctx
  5673  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  5674  	for {
  5675  		x, err := c.Do()
  5676  		if err != nil {
  5677  			return err
  5678  		}
  5679  		if err := f(x); err != nil {
  5680  			return err
  5681  		}
  5682  		if x.NextPageToken == "" {
  5683  			return nil
  5684  		}
  5685  		c.PageToken(x.NextPageToken)
  5686  	}
  5687  }
  5688  
  5689  type ProjectsLocationsServicesMoveTableToDatabaseCall struct {
  5690  	s                          *APIService
  5691  	service                    string
  5692  	movetabletodatabaserequest *MoveTableToDatabaseRequest
  5693  	urlParams_                 gensupport.URLParams
  5694  	ctx_                       context.Context
  5695  	header_                    http.Header
  5696  }
  5697  
  5698  // MoveTableToDatabase: Move a table to another database.
  5699  //
  5700  //   - service: The relative resource name of the metastore service to mutate
  5701  //     metadata, in the following
  5702  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  5703  func (r *ProjectsLocationsServicesService) MoveTableToDatabase(service string, movetabletodatabaserequest *MoveTableToDatabaseRequest) *ProjectsLocationsServicesMoveTableToDatabaseCall {
  5704  	c := &ProjectsLocationsServicesMoveTableToDatabaseCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5705  	c.service = service
  5706  	c.movetabletodatabaserequest = movetabletodatabaserequest
  5707  	return c
  5708  }
  5709  
  5710  // Fields allows partial responses to be retrieved. See
  5711  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5712  // details.
  5713  func (c *ProjectsLocationsServicesMoveTableToDatabaseCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMoveTableToDatabaseCall {
  5714  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5715  	return c
  5716  }
  5717  
  5718  // Context sets the context to be used in this call's Do method.
  5719  func (c *ProjectsLocationsServicesMoveTableToDatabaseCall) Context(ctx context.Context) *ProjectsLocationsServicesMoveTableToDatabaseCall {
  5720  	c.ctx_ = ctx
  5721  	return c
  5722  }
  5723  
  5724  // Header returns a http.Header that can be modified by the caller to add
  5725  // headers to the request.
  5726  func (c *ProjectsLocationsServicesMoveTableToDatabaseCall) Header() http.Header {
  5727  	if c.header_ == nil {
  5728  		c.header_ = make(http.Header)
  5729  	}
  5730  	return c.header_
  5731  }
  5732  
  5733  func (c *ProjectsLocationsServicesMoveTableToDatabaseCall) doRequest(alt string) (*http.Response, error) {
  5734  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5735  	var body io.Reader = nil
  5736  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.movetabletodatabaserequest)
  5737  	if err != nil {
  5738  		return nil, err
  5739  	}
  5740  	c.urlParams_.Set("alt", alt)
  5741  	c.urlParams_.Set("prettyPrint", "false")
  5742  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:moveTableToDatabase")
  5743  	urls += "?" + c.urlParams_.Encode()
  5744  	req, err := http.NewRequest("POST", urls, body)
  5745  	if err != nil {
  5746  		return nil, err
  5747  	}
  5748  	req.Header = reqHeaders
  5749  	googleapi.Expand(req.URL, map[string]string{
  5750  		"service": c.service,
  5751  	})
  5752  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5753  }
  5754  
  5755  // Do executes the "metastore.projects.locations.services.moveTableToDatabase" call.
  5756  // Any non-2xx status code is an error. Response headers are in either
  5757  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5758  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5759  // whether the returned error was because http.StatusNotModified was returned.
  5760  func (c *ProjectsLocationsServicesMoveTableToDatabaseCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5761  	gensupport.SetOptions(c.urlParams_, opts...)
  5762  	res, err := c.doRequest("json")
  5763  	if res != nil && res.StatusCode == http.StatusNotModified {
  5764  		if res.Body != nil {
  5765  			res.Body.Close()
  5766  		}
  5767  		return nil, gensupport.WrapError(&googleapi.Error{
  5768  			Code:   res.StatusCode,
  5769  			Header: res.Header,
  5770  		})
  5771  	}
  5772  	if err != nil {
  5773  		return nil, err
  5774  	}
  5775  	defer googleapi.CloseBody(res)
  5776  	if err := googleapi.CheckResponse(res); err != nil {
  5777  		return nil, gensupport.WrapError(err)
  5778  	}
  5779  	ret := &Operation{
  5780  		ServerResponse: googleapi.ServerResponse{
  5781  			Header:         res.Header,
  5782  			HTTPStatusCode: res.StatusCode,
  5783  		},
  5784  	}
  5785  	target := &ret
  5786  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5787  		return nil, err
  5788  	}
  5789  	return ret, nil
  5790  }
  5791  
  5792  type ProjectsLocationsServicesPatchCall struct {
  5793  	s          *APIService
  5794  	name       string
  5795  	service    *Service
  5796  	urlParams_ gensupport.URLParams
  5797  	ctx_       context.Context
  5798  	header_    http.Header
  5799  }
  5800  
  5801  // Patch: Updates the parameters of a single service.
  5802  //
  5803  //   - name: Immutable. The relative resource name of the metastore service, in
  5804  //     the following
  5805  //     format:projects/{project_number}/locations/{location_id}/services/{service_
  5806  //     id}.
  5807  func (r *ProjectsLocationsServicesService) Patch(name string, service *Service) *ProjectsLocationsServicesPatchCall {
  5808  	c := &ProjectsLocationsServicesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5809  	c.name = name
  5810  	c.service = service
  5811  	return c
  5812  }
  5813  
  5814  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  5815  // unique request ID to allow the server to ignore the request if it has
  5816  // completed. The server will ignore subsequent requests that provide a
  5817  // duplicate request ID for at least 60 minutes after the first request.For
  5818  // example, if an initial request times out, followed by another request with
  5819  // the same request ID, the server ignores the second request to prevent the
  5820  // creation of duplicate commitments.The request ID must be a valid UUID
  5821  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  5822  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  5823  func (c *ProjectsLocationsServicesPatchCall) RequestId(requestId string) *ProjectsLocationsServicesPatchCall {
  5824  	c.urlParams_.Set("requestId", requestId)
  5825  	return c
  5826  }
  5827  
  5828  // UpdateMask sets the optional parameter "updateMask": Required. A field mask
  5829  // used to specify the fields to be overwritten in the metastore service
  5830  // resource by the update. Fields specified in the update_mask are relative to
  5831  // the resource (not to the full request). A field is overwritten if it is in
  5832  // the mask.
  5833  func (c *ProjectsLocationsServicesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsServicesPatchCall {
  5834  	c.urlParams_.Set("updateMask", updateMask)
  5835  	return c
  5836  }
  5837  
  5838  // Fields allows partial responses to be retrieved. See
  5839  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5840  // details.
  5841  func (c *ProjectsLocationsServicesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesPatchCall {
  5842  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5843  	return c
  5844  }
  5845  
  5846  // Context sets the context to be used in this call's Do method.
  5847  func (c *ProjectsLocationsServicesPatchCall) Context(ctx context.Context) *ProjectsLocationsServicesPatchCall {
  5848  	c.ctx_ = ctx
  5849  	return c
  5850  }
  5851  
  5852  // Header returns a http.Header that can be modified by the caller to add
  5853  // headers to the request.
  5854  func (c *ProjectsLocationsServicesPatchCall) Header() http.Header {
  5855  	if c.header_ == nil {
  5856  		c.header_ = make(http.Header)
  5857  	}
  5858  	return c.header_
  5859  }
  5860  
  5861  func (c *ProjectsLocationsServicesPatchCall) doRequest(alt string) (*http.Response, error) {
  5862  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5863  	var body io.Reader = nil
  5864  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.service)
  5865  	if err != nil {
  5866  		return nil, err
  5867  	}
  5868  	c.urlParams_.Set("alt", alt)
  5869  	c.urlParams_.Set("prettyPrint", "false")
  5870  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  5871  	urls += "?" + c.urlParams_.Encode()
  5872  	req, err := http.NewRequest("PATCH", urls, body)
  5873  	if err != nil {
  5874  		return nil, err
  5875  	}
  5876  	req.Header = reqHeaders
  5877  	googleapi.Expand(req.URL, map[string]string{
  5878  		"name": c.name,
  5879  	})
  5880  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5881  }
  5882  
  5883  // Do executes the "metastore.projects.locations.services.patch" call.
  5884  // Any non-2xx status code is an error. Response headers are in either
  5885  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5886  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5887  // whether the returned error was because http.StatusNotModified was returned.
  5888  func (c *ProjectsLocationsServicesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5889  	gensupport.SetOptions(c.urlParams_, opts...)
  5890  	res, err := c.doRequest("json")
  5891  	if res != nil && res.StatusCode == http.StatusNotModified {
  5892  		if res.Body != nil {
  5893  			res.Body.Close()
  5894  		}
  5895  		return nil, gensupport.WrapError(&googleapi.Error{
  5896  			Code:   res.StatusCode,
  5897  			Header: res.Header,
  5898  		})
  5899  	}
  5900  	if err != nil {
  5901  		return nil, err
  5902  	}
  5903  	defer googleapi.CloseBody(res)
  5904  	if err := googleapi.CheckResponse(res); err != nil {
  5905  		return nil, gensupport.WrapError(err)
  5906  	}
  5907  	ret := &Operation{
  5908  		ServerResponse: googleapi.ServerResponse{
  5909  			Header:         res.Header,
  5910  			HTTPStatusCode: res.StatusCode,
  5911  		},
  5912  	}
  5913  	target := &ret
  5914  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5915  		return nil, err
  5916  	}
  5917  	return ret, nil
  5918  }
  5919  
  5920  type ProjectsLocationsServicesQueryMetadataCall struct {
  5921  	s                    *APIService
  5922  	service              string
  5923  	querymetadatarequest *QueryMetadataRequest
  5924  	urlParams_           gensupport.URLParams
  5925  	ctx_                 context.Context
  5926  	header_              http.Header
  5927  }
  5928  
  5929  // QueryMetadata: Query Dataproc Metastore metadata.
  5930  //
  5931  //   - service: The relative resource name of the metastore service to query
  5932  //     metadata, in the following
  5933  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  5934  func (r *ProjectsLocationsServicesService) QueryMetadata(service string, querymetadatarequest *QueryMetadataRequest) *ProjectsLocationsServicesQueryMetadataCall {
  5935  	c := &ProjectsLocationsServicesQueryMetadataCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5936  	c.service = service
  5937  	c.querymetadatarequest = querymetadatarequest
  5938  	return c
  5939  }
  5940  
  5941  // Fields allows partial responses to be retrieved. See
  5942  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5943  // details.
  5944  func (c *ProjectsLocationsServicesQueryMetadataCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesQueryMetadataCall {
  5945  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5946  	return c
  5947  }
  5948  
  5949  // Context sets the context to be used in this call's Do method.
  5950  func (c *ProjectsLocationsServicesQueryMetadataCall) Context(ctx context.Context) *ProjectsLocationsServicesQueryMetadataCall {
  5951  	c.ctx_ = ctx
  5952  	return c
  5953  }
  5954  
  5955  // Header returns a http.Header that can be modified by the caller to add
  5956  // headers to the request.
  5957  func (c *ProjectsLocationsServicesQueryMetadataCall) Header() http.Header {
  5958  	if c.header_ == nil {
  5959  		c.header_ = make(http.Header)
  5960  	}
  5961  	return c.header_
  5962  }
  5963  
  5964  func (c *ProjectsLocationsServicesQueryMetadataCall) doRequest(alt string) (*http.Response, error) {
  5965  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5966  	var body io.Reader = nil
  5967  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.querymetadatarequest)
  5968  	if err != nil {
  5969  		return nil, err
  5970  	}
  5971  	c.urlParams_.Set("alt", alt)
  5972  	c.urlParams_.Set("prettyPrint", "false")
  5973  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:queryMetadata")
  5974  	urls += "?" + c.urlParams_.Encode()
  5975  	req, err := http.NewRequest("POST", urls, body)
  5976  	if err != nil {
  5977  		return nil, err
  5978  	}
  5979  	req.Header = reqHeaders
  5980  	googleapi.Expand(req.URL, map[string]string{
  5981  		"service": c.service,
  5982  	})
  5983  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5984  }
  5985  
  5986  // Do executes the "metastore.projects.locations.services.queryMetadata" call.
  5987  // Any non-2xx status code is an error. Response headers are in either
  5988  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5989  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5990  // whether the returned error was because http.StatusNotModified was returned.
  5991  func (c *ProjectsLocationsServicesQueryMetadataCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5992  	gensupport.SetOptions(c.urlParams_, opts...)
  5993  	res, err := c.doRequest("json")
  5994  	if res != nil && res.StatusCode == http.StatusNotModified {
  5995  		if res.Body != nil {
  5996  			res.Body.Close()
  5997  		}
  5998  		return nil, gensupport.WrapError(&googleapi.Error{
  5999  			Code:   res.StatusCode,
  6000  			Header: res.Header,
  6001  		})
  6002  	}
  6003  	if err != nil {
  6004  		return nil, err
  6005  	}
  6006  	defer googleapi.CloseBody(res)
  6007  	if err := googleapi.CheckResponse(res); err != nil {
  6008  		return nil, gensupport.WrapError(err)
  6009  	}
  6010  	ret := &Operation{
  6011  		ServerResponse: googleapi.ServerResponse{
  6012  			Header:         res.Header,
  6013  			HTTPStatusCode: res.StatusCode,
  6014  		},
  6015  	}
  6016  	target := &ret
  6017  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6018  		return nil, err
  6019  	}
  6020  	return ret, nil
  6021  }
  6022  
  6023  type ProjectsLocationsServicesRemoveIamPolicyCall struct {
  6024  	s                      *APIService
  6025  	resource               string
  6026  	removeiampolicyrequest *RemoveIamPolicyRequest
  6027  	urlParams_             gensupport.URLParams
  6028  	ctx_                   context.Context
  6029  	header_                http.Header
  6030  }
  6031  
  6032  // RemoveIamPolicy: Removes the attached IAM policies for a resource
  6033  //
  6034  //   - resource: The relative resource name of the dataplane resource to remove
  6035  //     IAM policy, in the following
  6036  //     form:projects/{project_id}/locations/{location_id}/services/{service_id}/da
  6037  //     tabases/{database_id} or
  6038  //     projects/{project_id}/locations/{location_id}/services/{service_id}/databas
  6039  //     es/{database_id}/tables/{table_id}.
  6040  func (r *ProjectsLocationsServicesService) RemoveIamPolicy(resource string, removeiampolicyrequest *RemoveIamPolicyRequest) *ProjectsLocationsServicesRemoveIamPolicyCall {
  6041  	c := &ProjectsLocationsServicesRemoveIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6042  	c.resource = resource
  6043  	c.removeiampolicyrequest = removeiampolicyrequest
  6044  	return c
  6045  }
  6046  
  6047  // Fields allows partial responses to be retrieved. See
  6048  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6049  // details.
  6050  func (c *ProjectsLocationsServicesRemoveIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesRemoveIamPolicyCall {
  6051  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6052  	return c
  6053  }
  6054  
  6055  // Context sets the context to be used in this call's Do method.
  6056  func (c *ProjectsLocationsServicesRemoveIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesRemoveIamPolicyCall {
  6057  	c.ctx_ = ctx
  6058  	return c
  6059  }
  6060  
  6061  // Header returns a http.Header that can be modified by the caller to add
  6062  // headers to the request.
  6063  func (c *ProjectsLocationsServicesRemoveIamPolicyCall) Header() http.Header {
  6064  	if c.header_ == nil {
  6065  		c.header_ = make(http.Header)
  6066  	}
  6067  	return c.header_
  6068  }
  6069  
  6070  func (c *ProjectsLocationsServicesRemoveIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  6071  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  6072  	var body io.Reader = nil
  6073  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.removeiampolicyrequest)
  6074  	if err != nil {
  6075  		return nil, err
  6076  	}
  6077  	c.urlParams_.Set("alt", alt)
  6078  	c.urlParams_.Set("prettyPrint", "false")
  6079  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:removeIamPolicy")
  6080  	urls += "?" + c.urlParams_.Encode()
  6081  	req, err := http.NewRequest("POST", urls, body)
  6082  	if err != nil {
  6083  		return nil, err
  6084  	}
  6085  	req.Header = reqHeaders
  6086  	googleapi.Expand(req.URL, map[string]string{
  6087  		"resource": c.resource,
  6088  	})
  6089  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6090  }
  6091  
  6092  // Do executes the "metastore.projects.locations.services.removeIamPolicy" call.
  6093  // Any non-2xx status code is an error. Response headers are in either
  6094  // *RemoveIamPolicyResponse.ServerResponse.Header or (if a response was
  6095  // returned at all) in error.(*googleapi.Error).Header. Use
  6096  // googleapi.IsNotModified to check whether the returned error was because
  6097  // http.StatusNotModified was returned.
  6098  func (c *ProjectsLocationsServicesRemoveIamPolicyCall) Do(opts ...googleapi.CallOption) (*RemoveIamPolicyResponse, error) {
  6099  	gensupport.SetOptions(c.urlParams_, opts...)
  6100  	res, err := c.doRequest("json")
  6101  	if res != nil && res.StatusCode == http.StatusNotModified {
  6102  		if res.Body != nil {
  6103  			res.Body.Close()
  6104  		}
  6105  		return nil, gensupport.WrapError(&googleapi.Error{
  6106  			Code:   res.StatusCode,
  6107  			Header: res.Header,
  6108  		})
  6109  	}
  6110  	if err != nil {
  6111  		return nil, err
  6112  	}
  6113  	defer googleapi.CloseBody(res)
  6114  	if err := googleapi.CheckResponse(res); err != nil {
  6115  		return nil, gensupport.WrapError(err)
  6116  	}
  6117  	ret := &RemoveIamPolicyResponse{
  6118  		ServerResponse: googleapi.ServerResponse{
  6119  			Header:         res.Header,
  6120  			HTTPStatusCode: res.StatusCode,
  6121  		},
  6122  	}
  6123  	target := &ret
  6124  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6125  		return nil, err
  6126  	}
  6127  	return ret, nil
  6128  }
  6129  
  6130  type ProjectsLocationsServicesRestoreCall struct {
  6131  	s                     *APIService
  6132  	service               string
  6133  	restoreservicerequest *RestoreServiceRequest
  6134  	urlParams_            gensupport.URLParams
  6135  	ctx_                  context.Context
  6136  	header_               http.Header
  6137  }
  6138  
  6139  // Restore: Restores a service from a backup.
  6140  //
  6141  //   - service: The relative resource name of the metastore service to run
  6142  //     restore, in the following
  6143  //     form:projects/{project_id}/locations/{location_id}/services/{service_id}.
  6144  func (r *ProjectsLocationsServicesService) Restore(service string, restoreservicerequest *RestoreServiceRequest) *ProjectsLocationsServicesRestoreCall {
  6145  	c := &ProjectsLocationsServicesRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6146  	c.service = service
  6147  	c.restoreservicerequest = restoreservicerequest
  6148  	return c
  6149  }
  6150  
  6151  // Fields allows partial responses to be retrieved. See
  6152  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6153  // details.
  6154  func (c *ProjectsLocationsServicesRestoreCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesRestoreCall {
  6155  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6156  	return c
  6157  }
  6158  
  6159  // Context sets the context to be used in this call's Do method.
  6160  func (c *ProjectsLocationsServicesRestoreCall) Context(ctx context.Context) *ProjectsLocationsServicesRestoreCall {
  6161  	c.ctx_ = ctx
  6162  	return c
  6163  }
  6164  
  6165  // Header returns a http.Header that can be modified by the caller to add
  6166  // headers to the request.
  6167  func (c *ProjectsLocationsServicesRestoreCall) Header() http.Header {
  6168  	if c.header_ == nil {
  6169  		c.header_ = make(http.Header)
  6170  	}
  6171  	return c.header_
  6172  }
  6173  
  6174  func (c *ProjectsLocationsServicesRestoreCall) doRequest(alt string) (*http.Response, error) {
  6175  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  6176  	var body io.Reader = nil
  6177  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.restoreservicerequest)
  6178  	if err != nil {
  6179  		return nil, err
  6180  	}
  6181  	c.urlParams_.Set("alt", alt)
  6182  	c.urlParams_.Set("prettyPrint", "false")
  6183  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:restore")
  6184  	urls += "?" + c.urlParams_.Encode()
  6185  	req, err := http.NewRequest("POST", urls, body)
  6186  	if err != nil {
  6187  		return nil, err
  6188  	}
  6189  	req.Header = reqHeaders
  6190  	googleapi.Expand(req.URL, map[string]string{
  6191  		"service": c.service,
  6192  	})
  6193  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6194  }
  6195  
  6196  // Do executes the "metastore.projects.locations.services.restore" call.
  6197  // Any non-2xx status code is an error. Response headers are in either
  6198  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  6199  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6200  // whether the returned error was because http.StatusNotModified was returned.
  6201  func (c *ProjectsLocationsServicesRestoreCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  6202  	gensupport.SetOptions(c.urlParams_, opts...)
  6203  	res, err := c.doRequest("json")
  6204  	if res != nil && res.StatusCode == http.StatusNotModified {
  6205  		if res.Body != nil {
  6206  			res.Body.Close()
  6207  		}
  6208  		return nil, gensupport.WrapError(&googleapi.Error{
  6209  			Code:   res.StatusCode,
  6210  			Header: res.Header,
  6211  		})
  6212  	}
  6213  	if err != nil {
  6214  		return nil, err
  6215  	}
  6216  	defer googleapi.CloseBody(res)
  6217  	if err := googleapi.CheckResponse(res); err != nil {
  6218  		return nil, gensupport.WrapError(err)
  6219  	}
  6220  	ret := &Operation{
  6221  		ServerResponse: googleapi.ServerResponse{
  6222  			Header:         res.Header,
  6223  			HTTPStatusCode: res.StatusCode,
  6224  		},
  6225  	}
  6226  	target := &ret
  6227  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6228  		return nil, err
  6229  	}
  6230  	return ret, nil
  6231  }
  6232  
  6233  type ProjectsLocationsServicesSetIamPolicyCall struct {
  6234  	s                   *APIService
  6235  	resource            string
  6236  	setiampolicyrequest *SetIamPolicyRequest
  6237  	urlParams_          gensupport.URLParams
  6238  	ctx_                context.Context
  6239  	header_             http.Header
  6240  }
  6241  
  6242  // SetIamPolicy: Sets the access control policy on the specified resource.
  6243  // Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and
  6244  // PERMISSION_DENIED errors.
  6245  //
  6246  //   - resource: REQUIRED: The resource for which the policy is being specified.
  6247  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  6248  //     for the appropriate value for this field.
  6249  func (r *ProjectsLocationsServicesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsServicesSetIamPolicyCall {
  6250  	c := &ProjectsLocationsServicesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6251  	c.resource = resource
  6252  	c.setiampolicyrequest = setiampolicyrequest
  6253  	return c
  6254  }
  6255  
  6256  // Fields allows partial responses to be retrieved. See
  6257  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6258  // details.
  6259  func (c *ProjectsLocationsServicesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesSetIamPolicyCall {
  6260  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6261  	return c
  6262  }
  6263  
  6264  // Context sets the context to be used in this call's Do method.
  6265  func (c *ProjectsLocationsServicesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesSetIamPolicyCall {
  6266  	c.ctx_ = ctx
  6267  	return c
  6268  }
  6269  
  6270  // Header returns a http.Header that can be modified by the caller to add
  6271  // headers to the request.
  6272  func (c *ProjectsLocationsServicesSetIamPolicyCall) Header() http.Header {
  6273  	if c.header_ == nil {
  6274  		c.header_ = make(http.Header)
  6275  	}
  6276  	return c.header_
  6277  }
  6278  
  6279  func (c *ProjectsLocationsServicesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  6280  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  6281  	var body io.Reader = nil
  6282  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  6283  	if err != nil {
  6284  		return nil, err
  6285  	}
  6286  	c.urlParams_.Set("alt", alt)
  6287  	c.urlParams_.Set("prettyPrint", "false")
  6288  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy")
  6289  	urls += "?" + c.urlParams_.Encode()
  6290  	req, err := http.NewRequest("POST", urls, body)
  6291  	if err != nil {
  6292  		return nil, err
  6293  	}
  6294  	req.Header = reqHeaders
  6295  	googleapi.Expand(req.URL, map[string]string{
  6296  		"resource": c.resource,
  6297  	})
  6298  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6299  }
  6300  
  6301  // Do executes the "metastore.projects.locations.services.setIamPolicy" call.
  6302  // Any non-2xx status code is an error. Response headers are in either
  6303  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  6304  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6305  // whether the returned error was because http.StatusNotModified was returned.
  6306  func (c *ProjectsLocationsServicesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  6307  	gensupport.SetOptions(c.urlParams_, opts...)
  6308  	res, err := c.doRequest("json")
  6309  	if res != nil && res.StatusCode == http.StatusNotModified {
  6310  		if res.Body != nil {
  6311  			res.Body.Close()
  6312  		}
  6313  		return nil, gensupport.WrapError(&googleapi.Error{
  6314  			Code:   res.StatusCode,
  6315  			Header: res.Header,
  6316  		})
  6317  	}
  6318  	if err != nil {
  6319  		return nil, err
  6320  	}
  6321  	defer googleapi.CloseBody(res)
  6322  	if err := googleapi.CheckResponse(res); err != nil {
  6323  		return nil, gensupport.WrapError(err)
  6324  	}
  6325  	ret := &Policy{
  6326  		ServerResponse: googleapi.ServerResponse{
  6327  			Header:         res.Header,
  6328  			HTTPStatusCode: res.StatusCode,
  6329  		},
  6330  	}
  6331  	target := &ret
  6332  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6333  		return nil, err
  6334  	}
  6335  	return ret, nil
  6336  }
  6337  
  6338  type ProjectsLocationsServicesStartMigrationCall struct {
  6339  	s                     *APIService
  6340  	service               string
  6341  	startmigrationrequest *StartMigrationRequest
  6342  	urlParams_            gensupport.URLParams
  6343  	ctx_                  context.Context
  6344  	header_               http.Header
  6345  }
  6346  
  6347  // StartMigration: Starts the Managed Migration process.
  6348  //
  6349  //   - service: The relative resource name of the metastore service to start
  6350  //     migrating to, in the following
  6351  //     format:projects/{project_id}/locations/{location_id}/services/{service_id}.
  6352  func (r *ProjectsLocationsServicesService) StartMigration(service string, startmigrationrequest *StartMigrationRequest) *ProjectsLocationsServicesStartMigrationCall {
  6353  	c := &ProjectsLocationsServicesStartMigrationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6354  	c.service = service
  6355  	c.startmigrationrequest = startmigrationrequest
  6356  	return c
  6357  }
  6358  
  6359  // Fields allows partial responses to be retrieved. See
  6360  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6361  // details.
  6362  func (c *ProjectsLocationsServicesStartMigrationCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesStartMigrationCall {
  6363  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6364  	return c
  6365  }
  6366  
  6367  // Context sets the context to be used in this call's Do method.
  6368  func (c *ProjectsLocationsServicesStartMigrationCall) Context(ctx context.Context) *ProjectsLocationsServicesStartMigrationCall {
  6369  	c.ctx_ = ctx
  6370  	return c
  6371  }
  6372  
  6373  // Header returns a http.Header that can be modified by the caller to add
  6374  // headers to the request.
  6375  func (c *ProjectsLocationsServicesStartMigrationCall) Header() http.Header {
  6376  	if c.header_ == nil {
  6377  		c.header_ = make(http.Header)
  6378  	}
  6379  	return c.header_
  6380  }
  6381  
  6382  func (c *ProjectsLocationsServicesStartMigrationCall) doRequest(alt string) (*http.Response, error) {
  6383  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  6384  	var body io.Reader = nil
  6385  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.startmigrationrequest)
  6386  	if err != nil {
  6387  		return nil, err
  6388  	}
  6389  	c.urlParams_.Set("alt", alt)
  6390  	c.urlParams_.Set("prettyPrint", "false")
  6391  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+service}:startMigration")
  6392  	urls += "?" + c.urlParams_.Encode()
  6393  	req, err := http.NewRequest("POST", urls, body)
  6394  	if err != nil {
  6395  		return nil, err
  6396  	}
  6397  	req.Header = reqHeaders
  6398  	googleapi.Expand(req.URL, map[string]string{
  6399  		"service": c.service,
  6400  	})
  6401  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6402  }
  6403  
  6404  // Do executes the "metastore.projects.locations.services.startMigration" call.
  6405  // Any non-2xx status code is an error. Response headers are in either
  6406  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  6407  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6408  // whether the returned error was because http.StatusNotModified was returned.
  6409  func (c *ProjectsLocationsServicesStartMigrationCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  6410  	gensupport.SetOptions(c.urlParams_, opts...)
  6411  	res, err := c.doRequest("json")
  6412  	if res != nil && res.StatusCode == http.StatusNotModified {
  6413  		if res.Body != nil {
  6414  			res.Body.Close()
  6415  		}
  6416  		return nil, gensupport.WrapError(&googleapi.Error{
  6417  			Code:   res.StatusCode,
  6418  			Header: res.Header,
  6419  		})
  6420  	}
  6421  	if err != nil {
  6422  		return nil, err
  6423  	}
  6424  	defer googleapi.CloseBody(res)
  6425  	if err := googleapi.CheckResponse(res); err != nil {
  6426  		return nil, gensupport.WrapError(err)
  6427  	}
  6428  	ret := &Operation{
  6429  		ServerResponse: googleapi.ServerResponse{
  6430  			Header:         res.Header,
  6431  			HTTPStatusCode: res.StatusCode,
  6432  		},
  6433  	}
  6434  	target := &ret
  6435  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6436  		return nil, err
  6437  	}
  6438  	return ret, nil
  6439  }
  6440  
  6441  type ProjectsLocationsServicesTestIamPermissionsCall struct {
  6442  	s                         *APIService
  6443  	resource                  string
  6444  	testiampermissionsrequest *TestIamPermissionsRequest
  6445  	urlParams_                gensupport.URLParams
  6446  	ctx_                      context.Context
  6447  	header_                   http.Header
  6448  }
  6449  
  6450  // TestIamPermissions: Returns permissions that a caller has on the specified
  6451  // resource. If the resource does not exist, this will return an empty set of
  6452  // permissions, not a NOT_FOUND error.Note: This operation is designed to be
  6453  // used for building permission-aware UIs and command-line tools, not for
  6454  // authorization checking. This operation may "fail open" without warning.
  6455  //
  6456  //   - resource: REQUIRED: The resource for which the policy detail is being
  6457  //     requested. See Resource names
  6458  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  6459  //     value for this field.
  6460  func (r *ProjectsLocationsServicesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsServicesTestIamPermissionsCall {
  6461  	c := &ProjectsLocationsServicesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6462  	c.resource = resource
  6463  	c.testiampermissionsrequest = testiampermissionsrequest
  6464  	return c
  6465  }
  6466  
  6467  // Fields allows partial responses to be retrieved. See
  6468  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6469  // details.
  6470  func (c *ProjectsLocationsServicesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesTestIamPermissionsCall {
  6471  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6472  	return c
  6473  }
  6474  
  6475  // Context sets the context to be used in this call's Do method.
  6476  func (c *ProjectsLocationsServicesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsServicesTestIamPermissionsCall {
  6477  	c.ctx_ = ctx
  6478  	return c
  6479  }
  6480  
  6481  // Header returns a http.Header that can be modified by the caller to add
  6482  // headers to the request.
  6483  func (c *ProjectsLocationsServicesTestIamPermissionsCall) Header() http.Header {
  6484  	if c.header_ == nil {
  6485  		c.header_ = make(http.Header)
  6486  	}
  6487  	return c.header_
  6488  }
  6489  
  6490  func (c *ProjectsLocationsServicesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  6491  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  6492  	var body io.Reader = nil
  6493  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  6494  	if err != nil {
  6495  		return nil, err
  6496  	}
  6497  	c.urlParams_.Set("alt", alt)
  6498  	c.urlParams_.Set("prettyPrint", "false")
  6499  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions")
  6500  	urls += "?" + c.urlParams_.Encode()
  6501  	req, err := http.NewRequest("POST", urls, body)
  6502  	if err != nil {
  6503  		return nil, err
  6504  	}
  6505  	req.Header = reqHeaders
  6506  	googleapi.Expand(req.URL, map[string]string{
  6507  		"resource": c.resource,
  6508  	})
  6509  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6510  }
  6511  
  6512  // Do executes the "metastore.projects.locations.services.testIamPermissions" call.
  6513  // Any non-2xx status code is an error. Response headers are in either
  6514  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  6515  // returned at all) in error.(*googleapi.Error).Header. Use
  6516  // googleapi.IsNotModified to check whether the returned error was because
  6517  // http.StatusNotModified was returned.
  6518  func (c *ProjectsLocationsServicesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  6519  	gensupport.SetOptions(c.urlParams_, opts...)
  6520  	res, err := c.doRequest("json")
  6521  	if res != nil && res.StatusCode == http.StatusNotModified {
  6522  		if res.Body != nil {
  6523  			res.Body.Close()
  6524  		}
  6525  		return nil, gensupport.WrapError(&googleapi.Error{
  6526  			Code:   res.StatusCode,
  6527  			Header: res.Header,
  6528  		})
  6529  	}
  6530  	if err != nil {
  6531  		return nil, err
  6532  	}
  6533  	defer googleapi.CloseBody(res)
  6534  	if err := googleapi.CheckResponse(res); err != nil {
  6535  		return nil, gensupport.WrapError(err)
  6536  	}
  6537  	ret := &TestIamPermissionsResponse{
  6538  		ServerResponse: googleapi.ServerResponse{
  6539  			Header:         res.Header,
  6540  			HTTPStatusCode: res.StatusCode,
  6541  		},
  6542  	}
  6543  	target := &ret
  6544  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6545  		return nil, err
  6546  	}
  6547  	return ret, nil
  6548  }
  6549  
  6550  type ProjectsLocationsServicesBackupsCreateCall struct {
  6551  	s          *APIService
  6552  	parent     string
  6553  	backup     *Backup
  6554  	urlParams_ gensupport.URLParams
  6555  	ctx_       context.Context
  6556  	header_    http.Header
  6557  }
  6558  
  6559  // Create: Creates a new backup in a given project and location.
  6560  //
  6561  //   - parent: The relative resource name of the service in which to create a
  6562  //     backup of the following
  6563  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  6564  //     }.
  6565  func (r *ProjectsLocationsServicesBackupsService) Create(parent string, backup *Backup) *ProjectsLocationsServicesBackupsCreateCall {
  6566  	c := &ProjectsLocationsServicesBackupsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6567  	c.parent = parent
  6568  	c.backup = backup
  6569  	return c
  6570  }
  6571  
  6572  // BackupId sets the optional parameter "backupId": Required. The ID of the
  6573  // backup, which is used as the final component of the backup's name.This value
  6574  // must be between 1 and 64 characters long, begin with a letter, end with a
  6575  // letter or number, and consist of alpha-numeric ASCII characters or hyphens.
  6576  func (c *ProjectsLocationsServicesBackupsCreateCall) BackupId(backupId string) *ProjectsLocationsServicesBackupsCreateCall {
  6577  	c.urlParams_.Set("backupId", backupId)
  6578  	return c
  6579  }
  6580  
  6581  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  6582  // unique request ID to allow the server to ignore the request if it has
  6583  // completed. The server will ignore subsequent requests that provide a
  6584  // duplicate request ID for at least 60 minutes after the first request.For
  6585  // example, if an initial request times out, followed by another request with
  6586  // the same request ID, the server ignores the second request to prevent the
  6587  // creation of duplicate commitments.The request ID must be a valid UUID
  6588  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  6589  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  6590  func (c *ProjectsLocationsServicesBackupsCreateCall) RequestId(requestId string) *ProjectsLocationsServicesBackupsCreateCall {
  6591  	c.urlParams_.Set("requestId", requestId)
  6592  	return c
  6593  }
  6594  
  6595  // Fields allows partial responses to be retrieved. See
  6596  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6597  // details.
  6598  func (c *ProjectsLocationsServicesBackupsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsCreateCall {
  6599  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6600  	return c
  6601  }
  6602  
  6603  // Context sets the context to be used in this call's Do method.
  6604  func (c *ProjectsLocationsServicesBackupsCreateCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsCreateCall {
  6605  	c.ctx_ = ctx
  6606  	return c
  6607  }
  6608  
  6609  // Header returns a http.Header that can be modified by the caller to add
  6610  // headers to the request.
  6611  func (c *ProjectsLocationsServicesBackupsCreateCall) Header() http.Header {
  6612  	if c.header_ == nil {
  6613  		c.header_ = make(http.Header)
  6614  	}
  6615  	return c.header_
  6616  }
  6617  
  6618  func (c *ProjectsLocationsServicesBackupsCreateCall) doRequest(alt string) (*http.Response, error) {
  6619  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  6620  	var body io.Reader = nil
  6621  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.backup)
  6622  	if err != nil {
  6623  		return nil, err
  6624  	}
  6625  	c.urlParams_.Set("alt", alt)
  6626  	c.urlParams_.Set("prettyPrint", "false")
  6627  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/backups")
  6628  	urls += "?" + c.urlParams_.Encode()
  6629  	req, err := http.NewRequest("POST", urls, body)
  6630  	if err != nil {
  6631  		return nil, err
  6632  	}
  6633  	req.Header = reqHeaders
  6634  	googleapi.Expand(req.URL, map[string]string{
  6635  		"parent": c.parent,
  6636  	})
  6637  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6638  }
  6639  
  6640  // Do executes the "metastore.projects.locations.services.backups.create" call.
  6641  // Any non-2xx status code is an error. Response headers are in either
  6642  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  6643  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6644  // whether the returned error was because http.StatusNotModified was returned.
  6645  func (c *ProjectsLocationsServicesBackupsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  6646  	gensupport.SetOptions(c.urlParams_, opts...)
  6647  	res, err := c.doRequest("json")
  6648  	if res != nil && res.StatusCode == http.StatusNotModified {
  6649  		if res.Body != nil {
  6650  			res.Body.Close()
  6651  		}
  6652  		return nil, gensupport.WrapError(&googleapi.Error{
  6653  			Code:   res.StatusCode,
  6654  			Header: res.Header,
  6655  		})
  6656  	}
  6657  	if err != nil {
  6658  		return nil, err
  6659  	}
  6660  	defer googleapi.CloseBody(res)
  6661  	if err := googleapi.CheckResponse(res); err != nil {
  6662  		return nil, gensupport.WrapError(err)
  6663  	}
  6664  	ret := &Operation{
  6665  		ServerResponse: googleapi.ServerResponse{
  6666  			Header:         res.Header,
  6667  			HTTPStatusCode: res.StatusCode,
  6668  		},
  6669  	}
  6670  	target := &ret
  6671  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6672  		return nil, err
  6673  	}
  6674  	return ret, nil
  6675  }
  6676  
  6677  type ProjectsLocationsServicesBackupsDeleteCall struct {
  6678  	s          *APIService
  6679  	name       string
  6680  	urlParams_ gensupport.URLParams
  6681  	ctx_       context.Context
  6682  	header_    http.Header
  6683  }
  6684  
  6685  // Delete: Deletes a single backup.
  6686  //
  6687  //   - name: The relative resource name of the backup to delete, in the following
  6688  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  6689  //     }/backups/{backup_id}.
  6690  func (r *ProjectsLocationsServicesBackupsService) Delete(name string) *ProjectsLocationsServicesBackupsDeleteCall {
  6691  	c := &ProjectsLocationsServicesBackupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6692  	c.name = name
  6693  	return c
  6694  }
  6695  
  6696  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  6697  // unique request ID to allow the server to ignore the request if it has
  6698  // completed. The server will ignore subsequent requests that provide a
  6699  // duplicate request ID for at least 60 minutes after the first request.For
  6700  // example, if an initial request times out, followed by another request with
  6701  // the same request ID, the server ignores the second request to prevent the
  6702  // creation of duplicate commitments.The request ID must be a valid UUID
  6703  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  6704  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  6705  func (c *ProjectsLocationsServicesBackupsDeleteCall) RequestId(requestId string) *ProjectsLocationsServicesBackupsDeleteCall {
  6706  	c.urlParams_.Set("requestId", requestId)
  6707  	return c
  6708  }
  6709  
  6710  // Fields allows partial responses to be retrieved. See
  6711  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6712  // details.
  6713  func (c *ProjectsLocationsServicesBackupsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsDeleteCall {
  6714  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6715  	return c
  6716  }
  6717  
  6718  // Context sets the context to be used in this call's Do method.
  6719  func (c *ProjectsLocationsServicesBackupsDeleteCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsDeleteCall {
  6720  	c.ctx_ = ctx
  6721  	return c
  6722  }
  6723  
  6724  // Header returns a http.Header that can be modified by the caller to add
  6725  // headers to the request.
  6726  func (c *ProjectsLocationsServicesBackupsDeleteCall) Header() http.Header {
  6727  	if c.header_ == nil {
  6728  		c.header_ = make(http.Header)
  6729  	}
  6730  	return c.header_
  6731  }
  6732  
  6733  func (c *ProjectsLocationsServicesBackupsDeleteCall) doRequest(alt string) (*http.Response, error) {
  6734  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  6735  	var body io.Reader = nil
  6736  	c.urlParams_.Set("alt", alt)
  6737  	c.urlParams_.Set("prettyPrint", "false")
  6738  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  6739  	urls += "?" + c.urlParams_.Encode()
  6740  	req, err := http.NewRequest("DELETE", urls, body)
  6741  	if err != nil {
  6742  		return nil, err
  6743  	}
  6744  	req.Header = reqHeaders
  6745  	googleapi.Expand(req.URL, map[string]string{
  6746  		"name": c.name,
  6747  	})
  6748  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6749  }
  6750  
  6751  // Do executes the "metastore.projects.locations.services.backups.delete" call.
  6752  // Any non-2xx status code is an error. Response headers are in either
  6753  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  6754  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6755  // whether the returned error was because http.StatusNotModified was returned.
  6756  func (c *ProjectsLocationsServicesBackupsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  6757  	gensupport.SetOptions(c.urlParams_, opts...)
  6758  	res, err := c.doRequest("json")
  6759  	if res != nil && res.StatusCode == http.StatusNotModified {
  6760  		if res.Body != nil {
  6761  			res.Body.Close()
  6762  		}
  6763  		return nil, gensupport.WrapError(&googleapi.Error{
  6764  			Code:   res.StatusCode,
  6765  			Header: res.Header,
  6766  		})
  6767  	}
  6768  	if err != nil {
  6769  		return nil, err
  6770  	}
  6771  	defer googleapi.CloseBody(res)
  6772  	if err := googleapi.CheckResponse(res); err != nil {
  6773  		return nil, gensupport.WrapError(err)
  6774  	}
  6775  	ret := &Operation{
  6776  		ServerResponse: googleapi.ServerResponse{
  6777  			Header:         res.Header,
  6778  			HTTPStatusCode: res.StatusCode,
  6779  		},
  6780  	}
  6781  	target := &ret
  6782  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6783  		return nil, err
  6784  	}
  6785  	return ret, nil
  6786  }
  6787  
  6788  type ProjectsLocationsServicesBackupsGetCall struct {
  6789  	s            *APIService
  6790  	name         string
  6791  	urlParams_   gensupport.URLParams
  6792  	ifNoneMatch_ string
  6793  	ctx_         context.Context
  6794  	header_      http.Header
  6795  }
  6796  
  6797  // Get: Gets details of a single backup.
  6798  //
  6799  //   - name: The relative resource name of the backup to retrieve, in the
  6800  //     following
  6801  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  6802  //     }/backups/{backup_id}.
  6803  func (r *ProjectsLocationsServicesBackupsService) Get(name string) *ProjectsLocationsServicesBackupsGetCall {
  6804  	c := &ProjectsLocationsServicesBackupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6805  	c.name = name
  6806  	return c
  6807  }
  6808  
  6809  // Fields allows partial responses to be retrieved. See
  6810  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6811  // details.
  6812  func (c *ProjectsLocationsServicesBackupsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsGetCall {
  6813  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6814  	return c
  6815  }
  6816  
  6817  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  6818  // object's ETag matches the given value. This is useful for getting updates
  6819  // only after the object has changed since the last request.
  6820  func (c *ProjectsLocationsServicesBackupsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesBackupsGetCall {
  6821  	c.ifNoneMatch_ = entityTag
  6822  	return c
  6823  }
  6824  
  6825  // Context sets the context to be used in this call's Do method.
  6826  func (c *ProjectsLocationsServicesBackupsGetCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsGetCall {
  6827  	c.ctx_ = ctx
  6828  	return c
  6829  }
  6830  
  6831  // Header returns a http.Header that can be modified by the caller to add
  6832  // headers to the request.
  6833  func (c *ProjectsLocationsServicesBackupsGetCall) Header() http.Header {
  6834  	if c.header_ == nil {
  6835  		c.header_ = make(http.Header)
  6836  	}
  6837  	return c.header_
  6838  }
  6839  
  6840  func (c *ProjectsLocationsServicesBackupsGetCall) doRequest(alt string) (*http.Response, error) {
  6841  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  6842  	if c.ifNoneMatch_ != "" {
  6843  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  6844  	}
  6845  	var body io.Reader = nil
  6846  	c.urlParams_.Set("alt", alt)
  6847  	c.urlParams_.Set("prettyPrint", "false")
  6848  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  6849  	urls += "?" + c.urlParams_.Encode()
  6850  	req, err := http.NewRequest("GET", urls, body)
  6851  	if err != nil {
  6852  		return nil, err
  6853  	}
  6854  	req.Header = reqHeaders
  6855  	googleapi.Expand(req.URL, map[string]string{
  6856  		"name": c.name,
  6857  	})
  6858  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6859  }
  6860  
  6861  // Do executes the "metastore.projects.locations.services.backups.get" call.
  6862  // Any non-2xx status code is an error. Response headers are in either
  6863  // *Backup.ServerResponse.Header or (if a response was returned at all) in
  6864  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6865  // whether the returned error was because http.StatusNotModified was returned.
  6866  func (c *ProjectsLocationsServicesBackupsGetCall) Do(opts ...googleapi.CallOption) (*Backup, error) {
  6867  	gensupport.SetOptions(c.urlParams_, opts...)
  6868  	res, err := c.doRequest("json")
  6869  	if res != nil && res.StatusCode == http.StatusNotModified {
  6870  		if res.Body != nil {
  6871  			res.Body.Close()
  6872  		}
  6873  		return nil, gensupport.WrapError(&googleapi.Error{
  6874  			Code:   res.StatusCode,
  6875  			Header: res.Header,
  6876  		})
  6877  	}
  6878  	if err != nil {
  6879  		return nil, err
  6880  	}
  6881  	defer googleapi.CloseBody(res)
  6882  	if err := googleapi.CheckResponse(res); err != nil {
  6883  		return nil, gensupport.WrapError(err)
  6884  	}
  6885  	ret := &Backup{
  6886  		ServerResponse: googleapi.ServerResponse{
  6887  			Header:         res.Header,
  6888  			HTTPStatusCode: res.StatusCode,
  6889  		},
  6890  	}
  6891  	target := &ret
  6892  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6893  		return nil, err
  6894  	}
  6895  	return ret, nil
  6896  }
  6897  
  6898  type ProjectsLocationsServicesBackupsGetIamPolicyCall struct {
  6899  	s            *APIService
  6900  	resource     string
  6901  	urlParams_   gensupport.URLParams
  6902  	ifNoneMatch_ string
  6903  	ctx_         context.Context
  6904  	header_      http.Header
  6905  }
  6906  
  6907  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  6908  // empty policy if the resource exists and does not have a policy set.
  6909  //
  6910  //   - resource: REQUIRED: The resource for which the policy is being requested.
  6911  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  6912  //     for the appropriate value for this field.
  6913  func (r *ProjectsLocationsServicesBackupsService) GetIamPolicy(resource string) *ProjectsLocationsServicesBackupsGetIamPolicyCall {
  6914  	c := &ProjectsLocationsServicesBackupsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6915  	c.resource = resource
  6916  	return c
  6917  }
  6918  
  6919  // OptionsRequestedPolicyVersion sets the optional parameter
  6920  // "options.requestedPolicyVersion": The maximum policy version that will be
  6921  // used to format the policy.Valid values are 0, 1, and 3. Requests specifying
  6922  // an invalid value will be rejected.Requests for policies with any conditional
  6923  // role bindings must specify version 3. Policies with no conditional role
  6924  // bindings may specify any valid value or leave the field unset.The policy in
  6925  // the response might use the policy version that you specified, or it might
  6926  // use a lower policy version. For example, if you specify version 3, but the
  6927  // policy has no conditional role bindings, the response uses version 1.To
  6928  // learn which resources support conditions in their IAM policies, see the IAM
  6929  // documentation
  6930  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  6931  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsServicesBackupsGetIamPolicyCall {
  6932  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  6933  	return c
  6934  }
  6935  
  6936  // Fields allows partial responses to be retrieved. See
  6937  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  6938  // details.
  6939  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsGetIamPolicyCall {
  6940  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6941  	return c
  6942  }
  6943  
  6944  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  6945  // object's ETag matches the given value. This is useful for getting updates
  6946  // only after the object has changed since the last request.
  6947  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesBackupsGetIamPolicyCall {
  6948  	c.ifNoneMatch_ = entityTag
  6949  	return c
  6950  }
  6951  
  6952  // Context sets the context to be used in this call's Do method.
  6953  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsGetIamPolicyCall {
  6954  	c.ctx_ = ctx
  6955  	return c
  6956  }
  6957  
  6958  // Header returns a http.Header that can be modified by the caller to add
  6959  // headers to the request.
  6960  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) Header() http.Header {
  6961  	if c.header_ == nil {
  6962  		c.header_ = make(http.Header)
  6963  	}
  6964  	return c.header_
  6965  }
  6966  
  6967  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  6968  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  6969  	if c.ifNoneMatch_ != "" {
  6970  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  6971  	}
  6972  	var body io.Reader = nil
  6973  	c.urlParams_.Set("alt", alt)
  6974  	c.urlParams_.Set("prettyPrint", "false")
  6975  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy")
  6976  	urls += "?" + c.urlParams_.Encode()
  6977  	req, err := http.NewRequest("GET", urls, body)
  6978  	if err != nil {
  6979  		return nil, err
  6980  	}
  6981  	req.Header = reqHeaders
  6982  	googleapi.Expand(req.URL, map[string]string{
  6983  		"resource": c.resource,
  6984  	})
  6985  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6986  }
  6987  
  6988  // Do executes the "metastore.projects.locations.services.backups.getIamPolicy" call.
  6989  // Any non-2xx status code is an error. Response headers are in either
  6990  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  6991  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  6992  // whether the returned error was because http.StatusNotModified was returned.
  6993  func (c *ProjectsLocationsServicesBackupsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  6994  	gensupport.SetOptions(c.urlParams_, opts...)
  6995  	res, err := c.doRequest("json")
  6996  	if res != nil && res.StatusCode == http.StatusNotModified {
  6997  		if res.Body != nil {
  6998  			res.Body.Close()
  6999  		}
  7000  		return nil, gensupport.WrapError(&googleapi.Error{
  7001  			Code:   res.StatusCode,
  7002  			Header: res.Header,
  7003  		})
  7004  	}
  7005  	if err != nil {
  7006  		return nil, err
  7007  	}
  7008  	defer googleapi.CloseBody(res)
  7009  	if err := googleapi.CheckResponse(res); err != nil {
  7010  		return nil, gensupport.WrapError(err)
  7011  	}
  7012  	ret := &Policy{
  7013  		ServerResponse: googleapi.ServerResponse{
  7014  			Header:         res.Header,
  7015  			HTTPStatusCode: res.StatusCode,
  7016  		},
  7017  	}
  7018  	target := &ret
  7019  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7020  		return nil, err
  7021  	}
  7022  	return ret, nil
  7023  }
  7024  
  7025  type ProjectsLocationsServicesBackupsListCall struct {
  7026  	s            *APIService
  7027  	parent       string
  7028  	urlParams_   gensupport.URLParams
  7029  	ifNoneMatch_ string
  7030  	ctx_         context.Context
  7031  	header_      http.Header
  7032  }
  7033  
  7034  // List: Lists backups in a service.
  7035  //
  7036  //   - parent: The relative resource name of the service whose backups to list,
  7037  //     in the following
  7038  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  7039  //     }/backups.
  7040  func (r *ProjectsLocationsServicesBackupsService) List(parent string) *ProjectsLocationsServicesBackupsListCall {
  7041  	c := &ProjectsLocationsServicesBackupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7042  	c.parent = parent
  7043  	return c
  7044  }
  7045  
  7046  // Filter sets the optional parameter "filter": The filter to apply to list
  7047  // results.
  7048  func (c *ProjectsLocationsServicesBackupsListCall) Filter(filter string) *ProjectsLocationsServicesBackupsListCall {
  7049  	c.urlParams_.Set("filter", filter)
  7050  	return c
  7051  }
  7052  
  7053  // OrderBy sets the optional parameter "orderBy": Specify the ordering of
  7054  // results as described in Sorting Order
  7055  // (https://cloud.google.com/apis/design/design_patterns#sorting_order). If not
  7056  // specified, the results will be sorted in the default order.
  7057  func (c *ProjectsLocationsServicesBackupsListCall) OrderBy(orderBy string) *ProjectsLocationsServicesBackupsListCall {
  7058  	c.urlParams_.Set("orderBy", orderBy)
  7059  	return c
  7060  }
  7061  
  7062  // PageSize sets the optional parameter "pageSize": The maximum number of
  7063  // backups to return. The response may contain less than the maximum number. If
  7064  // unspecified, no more than 500 backups are returned. The maximum value is
  7065  // 1000; values above 1000 are changed to 1000.
  7066  func (c *ProjectsLocationsServicesBackupsListCall) PageSize(pageSize int64) *ProjectsLocationsServicesBackupsListCall {
  7067  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  7068  	return c
  7069  }
  7070  
  7071  // PageToken sets the optional parameter "pageToken": A page token, received
  7072  // from a previous DataprocMetastore.ListBackups call. Provide this token to
  7073  // retrieve the subsequent page.To retrieve the first page, supply an empty
  7074  // page token.When paginating, other parameters provided to
  7075  // DataprocMetastore.ListBackups must match the call that provided the page
  7076  // token.
  7077  func (c *ProjectsLocationsServicesBackupsListCall) PageToken(pageToken string) *ProjectsLocationsServicesBackupsListCall {
  7078  	c.urlParams_.Set("pageToken", pageToken)
  7079  	return c
  7080  }
  7081  
  7082  // Fields allows partial responses to be retrieved. See
  7083  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7084  // details.
  7085  func (c *ProjectsLocationsServicesBackupsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsListCall {
  7086  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7087  	return c
  7088  }
  7089  
  7090  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  7091  // object's ETag matches the given value. This is useful for getting updates
  7092  // only after the object has changed since the last request.
  7093  func (c *ProjectsLocationsServicesBackupsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesBackupsListCall {
  7094  	c.ifNoneMatch_ = entityTag
  7095  	return c
  7096  }
  7097  
  7098  // Context sets the context to be used in this call's Do method.
  7099  func (c *ProjectsLocationsServicesBackupsListCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsListCall {
  7100  	c.ctx_ = ctx
  7101  	return c
  7102  }
  7103  
  7104  // Header returns a http.Header that can be modified by the caller to add
  7105  // headers to the request.
  7106  func (c *ProjectsLocationsServicesBackupsListCall) Header() http.Header {
  7107  	if c.header_ == nil {
  7108  		c.header_ = make(http.Header)
  7109  	}
  7110  	return c.header_
  7111  }
  7112  
  7113  func (c *ProjectsLocationsServicesBackupsListCall) doRequest(alt string) (*http.Response, error) {
  7114  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  7115  	if c.ifNoneMatch_ != "" {
  7116  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  7117  	}
  7118  	var body io.Reader = nil
  7119  	c.urlParams_.Set("alt", alt)
  7120  	c.urlParams_.Set("prettyPrint", "false")
  7121  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/backups")
  7122  	urls += "?" + c.urlParams_.Encode()
  7123  	req, err := http.NewRequest("GET", urls, body)
  7124  	if err != nil {
  7125  		return nil, err
  7126  	}
  7127  	req.Header = reqHeaders
  7128  	googleapi.Expand(req.URL, map[string]string{
  7129  		"parent": c.parent,
  7130  	})
  7131  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7132  }
  7133  
  7134  // Do executes the "metastore.projects.locations.services.backups.list" call.
  7135  // Any non-2xx status code is an error. Response headers are in either
  7136  // *ListBackupsResponse.ServerResponse.Header or (if a response was returned at
  7137  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  7138  // check whether the returned error was because http.StatusNotModified was
  7139  // returned.
  7140  func (c *ProjectsLocationsServicesBackupsListCall) Do(opts ...googleapi.CallOption) (*ListBackupsResponse, error) {
  7141  	gensupport.SetOptions(c.urlParams_, opts...)
  7142  	res, err := c.doRequest("json")
  7143  	if res != nil && res.StatusCode == http.StatusNotModified {
  7144  		if res.Body != nil {
  7145  			res.Body.Close()
  7146  		}
  7147  		return nil, gensupport.WrapError(&googleapi.Error{
  7148  			Code:   res.StatusCode,
  7149  			Header: res.Header,
  7150  		})
  7151  	}
  7152  	if err != nil {
  7153  		return nil, err
  7154  	}
  7155  	defer googleapi.CloseBody(res)
  7156  	if err := googleapi.CheckResponse(res); err != nil {
  7157  		return nil, gensupport.WrapError(err)
  7158  	}
  7159  	ret := &ListBackupsResponse{
  7160  		ServerResponse: googleapi.ServerResponse{
  7161  			Header:         res.Header,
  7162  			HTTPStatusCode: res.StatusCode,
  7163  		},
  7164  	}
  7165  	target := &ret
  7166  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7167  		return nil, err
  7168  	}
  7169  	return ret, nil
  7170  }
  7171  
  7172  // Pages invokes f for each page of results.
  7173  // A non-nil error returned from f will halt the iteration.
  7174  // The provided context supersedes any context provided to the Context method.
  7175  func (c *ProjectsLocationsServicesBackupsListCall) Pages(ctx context.Context, f func(*ListBackupsResponse) error) error {
  7176  	c.ctx_ = ctx
  7177  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  7178  	for {
  7179  		x, err := c.Do()
  7180  		if err != nil {
  7181  			return err
  7182  		}
  7183  		if err := f(x); err != nil {
  7184  			return err
  7185  		}
  7186  		if x.NextPageToken == "" {
  7187  			return nil
  7188  		}
  7189  		c.PageToken(x.NextPageToken)
  7190  	}
  7191  }
  7192  
  7193  type ProjectsLocationsServicesBackupsSetIamPolicyCall struct {
  7194  	s                   *APIService
  7195  	resource            string
  7196  	setiampolicyrequest *SetIamPolicyRequest
  7197  	urlParams_          gensupport.URLParams
  7198  	ctx_                context.Context
  7199  	header_             http.Header
  7200  }
  7201  
  7202  // SetIamPolicy: Sets the access control policy on the specified resource.
  7203  // Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and
  7204  // PERMISSION_DENIED errors.
  7205  //
  7206  //   - resource: REQUIRED: The resource for which the policy is being specified.
  7207  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  7208  //     for the appropriate value for this field.
  7209  func (r *ProjectsLocationsServicesBackupsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsServicesBackupsSetIamPolicyCall {
  7210  	c := &ProjectsLocationsServicesBackupsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7211  	c.resource = resource
  7212  	c.setiampolicyrequest = setiampolicyrequest
  7213  	return c
  7214  }
  7215  
  7216  // Fields allows partial responses to be retrieved. See
  7217  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7218  // details.
  7219  func (c *ProjectsLocationsServicesBackupsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsSetIamPolicyCall {
  7220  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7221  	return c
  7222  }
  7223  
  7224  // Context sets the context to be used in this call's Do method.
  7225  func (c *ProjectsLocationsServicesBackupsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsSetIamPolicyCall {
  7226  	c.ctx_ = ctx
  7227  	return c
  7228  }
  7229  
  7230  // Header returns a http.Header that can be modified by the caller to add
  7231  // headers to the request.
  7232  func (c *ProjectsLocationsServicesBackupsSetIamPolicyCall) Header() http.Header {
  7233  	if c.header_ == nil {
  7234  		c.header_ = make(http.Header)
  7235  	}
  7236  	return c.header_
  7237  }
  7238  
  7239  func (c *ProjectsLocationsServicesBackupsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  7240  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  7241  	var body io.Reader = nil
  7242  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  7243  	if err != nil {
  7244  		return nil, err
  7245  	}
  7246  	c.urlParams_.Set("alt", alt)
  7247  	c.urlParams_.Set("prettyPrint", "false")
  7248  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy")
  7249  	urls += "?" + c.urlParams_.Encode()
  7250  	req, err := http.NewRequest("POST", urls, body)
  7251  	if err != nil {
  7252  		return nil, err
  7253  	}
  7254  	req.Header = reqHeaders
  7255  	googleapi.Expand(req.URL, map[string]string{
  7256  		"resource": c.resource,
  7257  	})
  7258  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7259  }
  7260  
  7261  // Do executes the "metastore.projects.locations.services.backups.setIamPolicy" call.
  7262  // Any non-2xx status code is an error. Response headers are in either
  7263  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  7264  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  7265  // whether the returned error was because http.StatusNotModified was returned.
  7266  func (c *ProjectsLocationsServicesBackupsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  7267  	gensupport.SetOptions(c.urlParams_, opts...)
  7268  	res, err := c.doRequest("json")
  7269  	if res != nil && res.StatusCode == http.StatusNotModified {
  7270  		if res.Body != nil {
  7271  			res.Body.Close()
  7272  		}
  7273  		return nil, gensupport.WrapError(&googleapi.Error{
  7274  			Code:   res.StatusCode,
  7275  			Header: res.Header,
  7276  		})
  7277  	}
  7278  	if err != nil {
  7279  		return nil, err
  7280  	}
  7281  	defer googleapi.CloseBody(res)
  7282  	if err := googleapi.CheckResponse(res); err != nil {
  7283  		return nil, gensupport.WrapError(err)
  7284  	}
  7285  	ret := &Policy{
  7286  		ServerResponse: googleapi.ServerResponse{
  7287  			Header:         res.Header,
  7288  			HTTPStatusCode: res.StatusCode,
  7289  		},
  7290  	}
  7291  	target := &ret
  7292  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7293  		return nil, err
  7294  	}
  7295  	return ret, nil
  7296  }
  7297  
  7298  type ProjectsLocationsServicesBackupsTestIamPermissionsCall struct {
  7299  	s                         *APIService
  7300  	resource                  string
  7301  	testiampermissionsrequest *TestIamPermissionsRequest
  7302  	urlParams_                gensupport.URLParams
  7303  	ctx_                      context.Context
  7304  	header_                   http.Header
  7305  }
  7306  
  7307  // TestIamPermissions: Returns permissions that a caller has on the specified
  7308  // resource. If the resource does not exist, this will return an empty set of
  7309  // permissions, not a NOT_FOUND error.Note: This operation is designed to be
  7310  // used for building permission-aware UIs and command-line tools, not for
  7311  // authorization checking. This operation may "fail open" without warning.
  7312  //
  7313  //   - resource: REQUIRED: The resource for which the policy detail is being
  7314  //     requested. See Resource names
  7315  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  7316  //     value for this field.
  7317  func (r *ProjectsLocationsServicesBackupsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsServicesBackupsTestIamPermissionsCall {
  7318  	c := &ProjectsLocationsServicesBackupsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7319  	c.resource = resource
  7320  	c.testiampermissionsrequest = testiampermissionsrequest
  7321  	return c
  7322  }
  7323  
  7324  // Fields allows partial responses to be retrieved. See
  7325  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7326  // details.
  7327  func (c *ProjectsLocationsServicesBackupsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesBackupsTestIamPermissionsCall {
  7328  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7329  	return c
  7330  }
  7331  
  7332  // Context sets the context to be used in this call's Do method.
  7333  func (c *ProjectsLocationsServicesBackupsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsServicesBackupsTestIamPermissionsCall {
  7334  	c.ctx_ = ctx
  7335  	return c
  7336  }
  7337  
  7338  // Header returns a http.Header that can be modified by the caller to add
  7339  // headers to the request.
  7340  func (c *ProjectsLocationsServicesBackupsTestIamPermissionsCall) Header() http.Header {
  7341  	if c.header_ == nil {
  7342  		c.header_ = make(http.Header)
  7343  	}
  7344  	return c.header_
  7345  }
  7346  
  7347  func (c *ProjectsLocationsServicesBackupsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  7348  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  7349  	var body io.Reader = nil
  7350  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  7351  	if err != nil {
  7352  		return nil, err
  7353  	}
  7354  	c.urlParams_.Set("alt", alt)
  7355  	c.urlParams_.Set("prettyPrint", "false")
  7356  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions")
  7357  	urls += "?" + c.urlParams_.Encode()
  7358  	req, err := http.NewRequest("POST", urls, body)
  7359  	if err != nil {
  7360  		return nil, err
  7361  	}
  7362  	req.Header = reqHeaders
  7363  	googleapi.Expand(req.URL, map[string]string{
  7364  		"resource": c.resource,
  7365  	})
  7366  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7367  }
  7368  
  7369  // Do executes the "metastore.projects.locations.services.backups.testIamPermissions" call.
  7370  // Any non-2xx status code is an error. Response headers are in either
  7371  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  7372  // returned at all) in error.(*googleapi.Error).Header. Use
  7373  // googleapi.IsNotModified to check whether the returned error was because
  7374  // http.StatusNotModified was returned.
  7375  func (c *ProjectsLocationsServicesBackupsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  7376  	gensupport.SetOptions(c.urlParams_, opts...)
  7377  	res, err := c.doRequest("json")
  7378  	if res != nil && res.StatusCode == http.StatusNotModified {
  7379  		if res.Body != nil {
  7380  			res.Body.Close()
  7381  		}
  7382  		return nil, gensupport.WrapError(&googleapi.Error{
  7383  			Code:   res.StatusCode,
  7384  			Header: res.Header,
  7385  		})
  7386  	}
  7387  	if err != nil {
  7388  		return nil, err
  7389  	}
  7390  	defer googleapi.CloseBody(res)
  7391  	if err := googleapi.CheckResponse(res); err != nil {
  7392  		return nil, gensupport.WrapError(err)
  7393  	}
  7394  	ret := &TestIamPermissionsResponse{
  7395  		ServerResponse: googleapi.ServerResponse{
  7396  			Header:         res.Header,
  7397  			HTTPStatusCode: res.StatusCode,
  7398  		},
  7399  	}
  7400  	target := &ret
  7401  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7402  		return nil, err
  7403  	}
  7404  	return ret, nil
  7405  }
  7406  
  7407  type ProjectsLocationsServicesDatabasesGetIamPolicyCall struct {
  7408  	s            *APIService
  7409  	resource     string
  7410  	urlParams_   gensupport.URLParams
  7411  	ifNoneMatch_ string
  7412  	ctx_         context.Context
  7413  	header_      http.Header
  7414  }
  7415  
  7416  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  7417  // empty policy if the resource exists and does not have a policy set.
  7418  //
  7419  //   - resource: REQUIRED: The resource for which the policy is being requested.
  7420  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  7421  //     for the appropriate value for this field.
  7422  func (r *ProjectsLocationsServicesDatabasesService) GetIamPolicy(resource string) *ProjectsLocationsServicesDatabasesGetIamPolicyCall {
  7423  	c := &ProjectsLocationsServicesDatabasesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7424  	c.resource = resource
  7425  	return c
  7426  }
  7427  
  7428  // OptionsRequestedPolicyVersion sets the optional parameter
  7429  // "options.requestedPolicyVersion": The maximum policy version that will be
  7430  // used to format the policy.Valid values are 0, 1, and 3. Requests specifying
  7431  // an invalid value will be rejected.Requests for policies with any conditional
  7432  // role bindings must specify version 3. Policies with no conditional role
  7433  // bindings may specify any valid value or leave the field unset.The policy in
  7434  // the response might use the policy version that you specified, or it might
  7435  // use a lower policy version. For example, if you specify version 3, but the
  7436  // policy has no conditional role bindings, the response uses version 1.To
  7437  // learn which resources support conditions in their IAM policies, see the IAM
  7438  // documentation
  7439  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  7440  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsServicesDatabasesGetIamPolicyCall {
  7441  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  7442  	return c
  7443  }
  7444  
  7445  // Fields allows partial responses to be retrieved. See
  7446  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7447  // details.
  7448  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesGetIamPolicyCall {
  7449  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7450  	return c
  7451  }
  7452  
  7453  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  7454  // object's ETag matches the given value. This is useful for getting updates
  7455  // only after the object has changed since the last request.
  7456  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesDatabasesGetIamPolicyCall {
  7457  	c.ifNoneMatch_ = entityTag
  7458  	return c
  7459  }
  7460  
  7461  // Context sets the context to be used in this call's Do method.
  7462  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesGetIamPolicyCall {
  7463  	c.ctx_ = ctx
  7464  	return c
  7465  }
  7466  
  7467  // Header returns a http.Header that can be modified by the caller to add
  7468  // headers to the request.
  7469  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Header() http.Header {
  7470  	if c.header_ == nil {
  7471  		c.header_ = make(http.Header)
  7472  	}
  7473  	return c.header_
  7474  }
  7475  
  7476  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  7477  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  7478  	if c.ifNoneMatch_ != "" {
  7479  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  7480  	}
  7481  	var body io.Reader = nil
  7482  	c.urlParams_.Set("alt", alt)
  7483  	c.urlParams_.Set("prettyPrint", "false")
  7484  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy")
  7485  	urls += "?" + c.urlParams_.Encode()
  7486  	req, err := http.NewRequest("GET", urls, body)
  7487  	if err != nil {
  7488  		return nil, err
  7489  	}
  7490  	req.Header = reqHeaders
  7491  	googleapi.Expand(req.URL, map[string]string{
  7492  		"resource": c.resource,
  7493  	})
  7494  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7495  }
  7496  
  7497  // Do executes the "metastore.projects.locations.services.databases.getIamPolicy" call.
  7498  // Any non-2xx status code is an error. Response headers are in either
  7499  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  7500  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  7501  // whether the returned error was because http.StatusNotModified was returned.
  7502  func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  7503  	gensupport.SetOptions(c.urlParams_, opts...)
  7504  	res, err := c.doRequest("json")
  7505  	if res != nil && res.StatusCode == http.StatusNotModified {
  7506  		if res.Body != nil {
  7507  			res.Body.Close()
  7508  		}
  7509  		return nil, gensupport.WrapError(&googleapi.Error{
  7510  			Code:   res.StatusCode,
  7511  			Header: res.Header,
  7512  		})
  7513  	}
  7514  	if err != nil {
  7515  		return nil, err
  7516  	}
  7517  	defer googleapi.CloseBody(res)
  7518  	if err := googleapi.CheckResponse(res); err != nil {
  7519  		return nil, gensupport.WrapError(err)
  7520  	}
  7521  	ret := &Policy{
  7522  		ServerResponse: googleapi.ServerResponse{
  7523  			Header:         res.Header,
  7524  			HTTPStatusCode: res.StatusCode,
  7525  		},
  7526  	}
  7527  	target := &ret
  7528  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7529  		return nil, err
  7530  	}
  7531  	return ret, nil
  7532  }
  7533  
  7534  type ProjectsLocationsServicesDatabasesSetIamPolicyCall struct {
  7535  	s                   *APIService
  7536  	resource            string
  7537  	setiampolicyrequest *SetIamPolicyRequest
  7538  	urlParams_          gensupport.URLParams
  7539  	ctx_                context.Context
  7540  	header_             http.Header
  7541  }
  7542  
  7543  // SetIamPolicy: Sets the access control policy on the specified resource.
  7544  // Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and
  7545  // PERMISSION_DENIED errors.
  7546  //
  7547  //   - resource: REQUIRED: The resource for which the policy is being specified.
  7548  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  7549  //     for the appropriate value for this field.
  7550  func (r *ProjectsLocationsServicesDatabasesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsServicesDatabasesSetIamPolicyCall {
  7551  	c := &ProjectsLocationsServicesDatabasesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7552  	c.resource = resource
  7553  	c.setiampolicyrequest = setiampolicyrequest
  7554  	return c
  7555  }
  7556  
  7557  // Fields allows partial responses to be retrieved. See
  7558  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7559  // details.
  7560  func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesSetIamPolicyCall {
  7561  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7562  	return c
  7563  }
  7564  
  7565  // Context sets the context to be used in this call's Do method.
  7566  func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesSetIamPolicyCall {
  7567  	c.ctx_ = ctx
  7568  	return c
  7569  }
  7570  
  7571  // Header returns a http.Header that can be modified by the caller to add
  7572  // headers to the request.
  7573  func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Header() http.Header {
  7574  	if c.header_ == nil {
  7575  		c.header_ = make(http.Header)
  7576  	}
  7577  	return c.header_
  7578  }
  7579  
  7580  func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  7581  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  7582  	var body io.Reader = nil
  7583  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  7584  	if err != nil {
  7585  		return nil, err
  7586  	}
  7587  	c.urlParams_.Set("alt", alt)
  7588  	c.urlParams_.Set("prettyPrint", "false")
  7589  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy")
  7590  	urls += "?" + c.urlParams_.Encode()
  7591  	req, err := http.NewRequest("POST", urls, body)
  7592  	if err != nil {
  7593  		return nil, err
  7594  	}
  7595  	req.Header = reqHeaders
  7596  	googleapi.Expand(req.URL, map[string]string{
  7597  		"resource": c.resource,
  7598  	})
  7599  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7600  }
  7601  
  7602  // Do executes the "metastore.projects.locations.services.databases.setIamPolicy" call.
  7603  // Any non-2xx status code is an error. Response headers are in either
  7604  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  7605  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  7606  // whether the returned error was because http.StatusNotModified was returned.
  7607  func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  7608  	gensupport.SetOptions(c.urlParams_, opts...)
  7609  	res, err := c.doRequest("json")
  7610  	if res != nil && res.StatusCode == http.StatusNotModified {
  7611  		if res.Body != nil {
  7612  			res.Body.Close()
  7613  		}
  7614  		return nil, gensupport.WrapError(&googleapi.Error{
  7615  			Code:   res.StatusCode,
  7616  			Header: res.Header,
  7617  		})
  7618  	}
  7619  	if err != nil {
  7620  		return nil, err
  7621  	}
  7622  	defer googleapi.CloseBody(res)
  7623  	if err := googleapi.CheckResponse(res); err != nil {
  7624  		return nil, gensupport.WrapError(err)
  7625  	}
  7626  	ret := &Policy{
  7627  		ServerResponse: googleapi.ServerResponse{
  7628  			Header:         res.Header,
  7629  			HTTPStatusCode: res.StatusCode,
  7630  		},
  7631  	}
  7632  	target := &ret
  7633  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7634  		return nil, err
  7635  	}
  7636  	return ret, nil
  7637  }
  7638  
  7639  type ProjectsLocationsServicesDatabasesTestIamPermissionsCall struct {
  7640  	s                         *APIService
  7641  	resource                  string
  7642  	testiampermissionsrequest *TestIamPermissionsRequest
  7643  	urlParams_                gensupport.URLParams
  7644  	ctx_                      context.Context
  7645  	header_                   http.Header
  7646  }
  7647  
  7648  // TestIamPermissions: Returns permissions that a caller has on the specified
  7649  // resource. If the resource does not exist, this will return an empty set of
  7650  // permissions, not a NOT_FOUND error.Note: This operation is designed to be
  7651  // used for building permission-aware UIs and command-line tools, not for
  7652  // authorization checking. This operation may "fail open" without warning.
  7653  //
  7654  //   - resource: REQUIRED: The resource for which the policy detail is being
  7655  //     requested. See Resource names
  7656  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  7657  //     value for this field.
  7658  func (r *ProjectsLocationsServicesDatabasesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsServicesDatabasesTestIamPermissionsCall {
  7659  	c := &ProjectsLocationsServicesDatabasesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7660  	c.resource = resource
  7661  	c.testiampermissionsrequest = testiampermissionsrequest
  7662  	return c
  7663  }
  7664  
  7665  // Fields allows partial responses to be retrieved. See
  7666  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7667  // details.
  7668  func (c *ProjectsLocationsServicesDatabasesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesTestIamPermissionsCall {
  7669  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7670  	return c
  7671  }
  7672  
  7673  // Context sets the context to be used in this call's Do method.
  7674  func (c *ProjectsLocationsServicesDatabasesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesTestIamPermissionsCall {
  7675  	c.ctx_ = ctx
  7676  	return c
  7677  }
  7678  
  7679  // Header returns a http.Header that can be modified by the caller to add
  7680  // headers to the request.
  7681  func (c *ProjectsLocationsServicesDatabasesTestIamPermissionsCall) Header() http.Header {
  7682  	if c.header_ == nil {
  7683  		c.header_ = make(http.Header)
  7684  	}
  7685  	return c.header_
  7686  }
  7687  
  7688  func (c *ProjectsLocationsServicesDatabasesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  7689  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  7690  	var body io.Reader = nil
  7691  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  7692  	if err != nil {
  7693  		return nil, err
  7694  	}
  7695  	c.urlParams_.Set("alt", alt)
  7696  	c.urlParams_.Set("prettyPrint", "false")
  7697  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions")
  7698  	urls += "?" + c.urlParams_.Encode()
  7699  	req, err := http.NewRequest("POST", urls, body)
  7700  	if err != nil {
  7701  		return nil, err
  7702  	}
  7703  	req.Header = reqHeaders
  7704  	googleapi.Expand(req.URL, map[string]string{
  7705  		"resource": c.resource,
  7706  	})
  7707  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7708  }
  7709  
  7710  // Do executes the "metastore.projects.locations.services.databases.testIamPermissions" call.
  7711  // Any non-2xx status code is an error. Response headers are in either
  7712  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  7713  // returned at all) in error.(*googleapi.Error).Header. Use
  7714  // googleapi.IsNotModified to check whether the returned error was because
  7715  // http.StatusNotModified was returned.
  7716  func (c *ProjectsLocationsServicesDatabasesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  7717  	gensupport.SetOptions(c.urlParams_, opts...)
  7718  	res, err := c.doRequest("json")
  7719  	if res != nil && res.StatusCode == http.StatusNotModified {
  7720  		if res.Body != nil {
  7721  			res.Body.Close()
  7722  		}
  7723  		return nil, gensupport.WrapError(&googleapi.Error{
  7724  			Code:   res.StatusCode,
  7725  			Header: res.Header,
  7726  		})
  7727  	}
  7728  	if err != nil {
  7729  		return nil, err
  7730  	}
  7731  	defer googleapi.CloseBody(res)
  7732  	if err := googleapi.CheckResponse(res); err != nil {
  7733  		return nil, gensupport.WrapError(err)
  7734  	}
  7735  	ret := &TestIamPermissionsResponse{
  7736  		ServerResponse: googleapi.ServerResponse{
  7737  			Header:         res.Header,
  7738  			HTTPStatusCode: res.StatusCode,
  7739  		},
  7740  	}
  7741  	target := &ret
  7742  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7743  		return nil, err
  7744  	}
  7745  	return ret, nil
  7746  }
  7747  
  7748  type ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall struct {
  7749  	s            *APIService
  7750  	resource     string
  7751  	urlParams_   gensupport.URLParams
  7752  	ifNoneMatch_ string
  7753  	ctx_         context.Context
  7754  	header_      http.Header
  7755  }
  7756  
  7757  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  7758  // empty policy if the resource exists and does not have a policy set.
  7759  //
  7760  //   - resource: REQUIRED: The resource for which the policy is being requested.
  7761  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  7762  //     for the appropriate value for this field.
  7763  func (r *ProjectsLocationsServicesDatabasesTablesService) GetIamPolicy(resource string) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall {
  7764  	c := &ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7765  	c.resource = resource
  7766  	return c
  7767  }
  7768  
  7769  // OptionsRequestedPolicyVersion sets the optional parameter
  7770  // "options.requestedPolicyVersion": The maximum policy version that will be
  7771  // used to format the policy.Valid values are 0, 1, and 3. Requests specifying
  7772  // an invalid value will be rejected.Requests for policies with any conditional
  7773  // role bindings must specify version 3. Policies with no conditional role
  7774  // bindings may specify any valid value or leave the field unset.The policy in
  7775  // the response might use the policy version that you specified, or it might
  7776  // use a lower policy version. For example, if you specify version 3, but the
  7777  // policy has no conditional role bindings, the response uses version 1.To
  7778  // learn which resources support conditions in their IAM policies, see the IAM
  7779  // documentation
  7780  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  7781  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall {
  7782  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  7783  	return c
  7784  }
  7785  
  7786  // Fields allows partial responses to be retrieved. See
  7787  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7788  // details.
  7789  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall {
  7790  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7791  	return c
  7792  }
  7793  
  7794  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  7795  // object's ETag matches the given value. This is useful for getting updates
  7796  // only after the object has changed since the last request.
  7797  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall {
  7798  	c.ifNoneMatch_ = entityTag
  7799  	return c
  7800  }
  7801  
  7802  // Context sets the context to be used in this call's Do method.
  7803  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall {
  7804  	c.ctx_ = ctx
  7805  	return c
  7806  }
  7807  
  7808  // Header returns a http.Header that can be modified by the caller to add
  7809  // headers to the request.
  7810  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Header() http.Header {
  7811  	if c.header_ == nil {
  7812  		c.header_ = make(http.Header)
  7813  	}
  7814  	return c.header_
  7815  }
  7816  
  7817  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  7818  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  7819  	if c.ifNoneMatch_ != "" {
  7820  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  7821  	}
  7822  	var body io.Reader = nil
  7823  	c.urlParams_.Set("alt", alt)
  7824  	c.urlParams_.Set("prettyPrint", "false")
  7825  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy")
  7826  	urls += "?" + c.urlParams_.Encode()
  7827  	req, err := http.NewRequest("GET", urls, body)
  7828  	if err != nil {
  7829  		return nil, err
  7830  	}
  7831  	req.Header = reqHeaders
  7832  	googleapi.Expand(req.URL, map[string]string{
  7833  		"resource": c.resource,
  7834  	})
  7835  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7836  }
  7837  
  7838  // Do executes the "metastore.projects.locations.services.databases.tables.getIamPolicy" call.
  7839  // Any non-2xx status code is an error. Response headers are in either
  7840  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  7841  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  7842  // whether the returned error was because http.StatusNotModified was returned.
  7843  func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  7844  	gensupport.SetOptions(c.urlParams_, opts...)
  7845  	res, err := c.doRequest("json")
  7846  	if res != nil && res.StatusCode == http.StatusNotModified {
  7847  		if res.Body != nil {
  7848  			res.Body.Close()
  7849  		}
  7850  		return nil, gensupport.WrapError(&googleapi.Error{
  7851  			Code:   res.StatusCode,
  7852  			Header: res.Header,
  7853  		})
  7854  	}
  7855  	if err != nil {
  7856  		return nil, err
  7857  	}
  7858  	defer googleapi.CloseBody(res)
  7859  	if err := googleapi.CheckResponse(res); err != nil {
  7860  		return nil, gensupport.WrapError(err)
  7861  	}
  7862  	ret := &Policy{
  7863  		ServerResponse: googleapi.ServerResponse{
  7864  			Header:         res.Header,
  7865  			HTTPStatusCode: res.StatusCode,
  7866  		},
  7867  	}
  7868  	target := &ret
  7869  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7870  		return nil, err
  7871  	}
  7872  	return ret, nil
  7873  }
  7874  
  7875  type ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall struct {
  7876  	s                   *APIService
  7877  	resource            string
  7878  	setiampolicyrequest *SetIamPolicyRequest
  7879  	urlParams_          gensupport.URLParams
  7880  	ctx_                context.Context
  7881  	header_             http.Header
  7882  }
  7883  
  7884  // SetIamPolicy: Sets the access control policy on the specified resource.
  7885  // Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and
  7886  // PERMISSION_DENIED errors.
  7887  //
  7888  //   - resource: REQUIRED: The resource for which the policy is being specified.
  7889  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  7890  //     for the appropriate value for this field.
  7891  func (r *ProjectsLocationsServicesDatabasesTablesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall {
  7892  	c := &ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  7893  	c.resource = resource
  7894  	c.setiampolicyrequest = setiampolicyrequest
  7895  	return c
  7896  }
  7897  
  7898  // Fields allows partial responses to be retrieved. See
  7899  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  7900  // details.
  7901  func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall {
  7902  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  7903  	return c
  7904  }
  7905  
  7906  // Context sets the context to be used in this call's Do method.
  7907  func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall {
  7908  	c.ctx_ = ctx
  7909  	return c
  7910  }
  7911  
  7912  // Header returns a http.Header that can be modified by the caller to add
  7913  // headers to the request.
  7914  func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Header() http.Header {
  7915  	if c.header_ == nil {
  7916  		c.header_ = make(http.Header)
  7917  	}
  7918  	return c.header_
  7919  }
  7920  
  7921  func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  7922  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  7923  	var body io.Reader = nil
  7924  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  7925  	if err != nil {
  7926  		return nil, err
  7927  	}
  7928  	c.urlParams_.Set("alt", alt)
  7929  	c.urlParams_.Set("prettyPrint", "false")
  7930  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy")
  7931  	urls += "?" + c.urlParams_.Encode()
  7932  	req, err := http.NewRequest("POST", urls, body)
  7933  	if err != nil {
  7934  		return nil, err
  7935  	}
  7936  	req.Header = reqHeaders
  7937  	googleapi.Expand(req.URL, map[string]string{
  7938  		"resource": c.resource,
  7939  	})
  7940  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  7941  }
  7942  
  7943  // Do executes the "metastore.projects.locations.services.databases.tables.setIamPolicy" call.
  7944  // Any non-2xx status code is an error. Response headers are in either
  7945  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  7946  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  7947  // whether the returned error was because http.StatusNotModified was returned.
  7948  func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  7949  	gensupport.SetOptions(c.urlParams_, opts...)
  7950  	res, err := c.doRequest("json")
  7951  	if res != nil && res.StatusCode == http.StatusNotModified {
  7952  		if res.Body != nil {
  7953  			res.Body.Close()
  7954  		}
  7955  		return nil, gensupport.WrapError(&googleapi.Error{
  7956  			Code:   res.StatusCode,
  7957  			Header: res.Header,
  7958  		})
  7959  	}
  7960  	if err != nil {
  7961  		return nil, err
  7962  	}
  7963  	defer googleapi.CloseBody(res)
  7964  	if err := googleapi.CheckResponse(res); err != nil {
  7965  		return nil, gensupport.WrapError(err)
  7966  	}
  7967  	ret := &Policy{
  7968  		ServerResponse: googleapi.ServerResponse{
  7969  			Header:         res.Header,
  7970  			HTTPStatusCode: res.StatusCode,
  7971  		},
  7972  	}
  7973  	target := &ret
  7974  	if err := gensupport.DecodeResponse(target, res); err != nil {
  7975  		return nil, err
  7976  	}
  7977  	return ret, nil
  7978  }
  7979  
  7980  type ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall struct {
  7981  	s                         *APIService
  7982  	resource                  string
  7983  	testiampermissionsrequest *TestIamPermissionsRequest
  7984  	urlParams_                gensupport.URLParams
  7985  	ctx_                      context.Context
  7986  	header_                   http.Header
  7987  }
  7988  
  7989  // TestIamPermissions: Returns permissions that a caller has on the specified
  7990  // resource. If the resource does not exist, this will return an empty set of
  7991  // permissions, not a NOT_FOUND error.Note: This operation is designed to be
  7992  // used for building permission-aware UIs and command-line tools, not for
  7993  // authorization checking. This operation may "fail open" without warning.
  7994  //
  7995  //   - resource: REQUIRED: The resource for which the policy detail is being
  7996  //     requested. See Resource names
  7997  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  7998  //     value for this field.
  7999  func (r *ProjectsLocationsServicesDatabasesTablesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall {
  8000  	c := &ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8001  	c.resource = resource
  8002  	c.testiampermissionsrequest = testiampermissionsrequest
  8003  	return c
  8004  }
  8005  
  8006  // Fields allows partial responses to be retrieved. See
  8007  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8008  // details.
  8009  func (c *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall {
  8010  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8011  	return c
  8012  }
  8013  
  8014  // Context sets the context to be used in this call's Do method.
  8015  func (c *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall {
  8016  	c.ctx_ = ctx
  8017  	return c
  8018  }
  8019  
  8020  // Header returns a http.Header that can be modified by the caller to add
  8021  // headers to the request.
  8022  func (c *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall) Header() http.Header {
  8023  	if c.header_ == nil {
  8024  		c.header_ = make(http.Header)
  8025  	}
  8026  	return c.header_
  8027  }
  8028  
  8029  func (c *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  8030  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  8031  	var body io.Reader = nil
  8032  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  8033  	if err != nil {
  8034  		return nil, err
  8035  	}
  8036  	c.urlParams_.Set("alt", alt)
  8037  	c.urlParams_.Set("prettyPrint", "false")
  8038  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions")
  8039  	urls += "?" + c.urlParams_.Encode()
  8040  	req, err := http.NewRequest("POST", urls, body)
  8041  	if err != nil {
  8042  		return nil, err
  8043  	}
  8044  	req.Header = reqHeaders
  8045  	googleapi.Expand(req.URL, map[string]string{
  8046  		"resource": c.resource,
  8047  	})
  8048  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8049  }
  8050  
  8051  // Do executes the "metastore.projects.locations.services.databases.tables.testIamPermissions" call.
  8052  // Any non-2xx status code is an error. Response headers are in either
  8053  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  8054  // returned at all) in error.(*googleapi.Error).Header. Use
  8055  // googleapi.IsNotModified to check whether the returned error was because
  8056  // http.StatusNotModified was returned.
  8057  func (c *ProjectsLocationsServicesDatabasesTablesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  8058  	gensupport.SetOptions(c.urlParams_, opts...)
  8059  	res, err := c.doRequest("json")
  8060  	if res != nil && res.StatusCode == http.StatusNotModified {
  8061  		if res.Body != nil {
  8062  			res.Body.Close()
  8063  		}
  8064  		return nil, gensupport.WrapError(&googleapi.Error{
  8065  			Code:   res.StatusCode,
  8066  			Header: res.Header,
  8067  		})
  8068  	}
  8069  	if err != nil {
  8070  		return nil, err
  8071  	}
  8072  	defer googleapi.CloseBody(res)
  8073  	if err := googleapi.CheckResponse(res); err != nil {
  8074  		return nil, gensupport.WrapError(err)
  8075  	}
  8076  	ret := &TestIamPermissionsResponse{
  8077  		ServerResponse: googleapi.ServerResponse{
  8078  			Header:         res.Header,
  8079  			HTTPStatusCode: res.StatusCode,
  8080  		},
  8081  	}
  8082  	target := &ret
  8083  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8084  		return nil, err
  8085  	}
  8086  	return ret, nil
  8087  }
  8088  
  8089  type ProjectsLocationsServicesMetadataImportsCreateCall struct {
  8090  	s              *APIService
  8091  	parent         string
  8092  	metadataimport *MetadataImport
  8093  	urlParams_     gensupport.URLParams
  8094  	ctx_           context.Context
  8095  	header_        http.Header
  8096  }
  8097  
  8098  // Create: Creates a new MetadataImport in a given project and location.
  8099  //
  8100  //   - parent: The relative resource name of the service in which to create a
  8101  //     metastore import, in the following
  8102  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8103  //     }.
  8104  func (r *ProjectsLocationsServicesMetadataImportsService) Create(parent string, metadataimport *MetadataImport) *ProjectsLocationsServicesMetadataImportsCreateCall {
  8105  	c := &ProjectsLocationsServicesMetadataImportsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8106  	c.parent = parent
  8107  	c.metadataimport = metadataimport
  8108  	return c
  8109  }
  8110  
  8111  // MetadataImportId sets the optional parameter "metadataImportId": Required.
  8112  // The ID of the metadata import, which is used as the final component of the
  8113  // metadata import's name.This value must be between 1 and 64 characters long,
  8114  // begin with a letter, end with a letter or number, and consist of
  8115  // alpha-numeric ASCII characters or hyphens.
  8116  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) MetadataImportId(metadataImportId string) *ProjectsLocationsServicesMetadataImportsCreateCall {
  8117  	c.urlParams_.Set("metadataImportId", metadataImportId)
  8118  	return c
  8119  }
  8120  
  8121  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  8122  // unique request ID to allow the server to ignore the request if it has
  8123  // completed. The server will ignore subsequent requests that provide a
  8124  // duplicate request ID for at least 60 minutes after the first request.For
  8125  // example, if an initial request times out, followed by another request with
  8126  // the same request ID, the server ignores the second request to prevent the
  8127  // creation of duplicate commitments.The request ID must be a valid UUID
  8128  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  8129  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  8130  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) RequestId(requestId string) *ProjectsLocationsServicesMetadataImportsCreateCall {
  8131  	c.urlParams_.Set("requestId", requestId)
  8132  	return c
  8133  }
  8134  
  8135  // Fields allows partial responses to be retrieved. See
  8136  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8137  // details.
  8138  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMetadataImportsCreateCall {
  8139  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8140  	return c
  8141  }
  8142  
  8143  // Context sets the context to be used in this call's Do method.
  8144  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) Context(ctx context.Context) *ProjectsLocationsServicesMetadataImportsCreateCall {
  8145  	c.ctx_ = ctx
  8146  	return c
  8147  }
  8148  
  8149  // Header returns a http.Header that can be modified by the caller to add
  8150  // headers to the request.
  8151  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) Header() http.Header {
  8152  	if c.header_ == nil {
  8153  		c.header_ = make(http.Header)
  8154  	}
  8155  	return c.header_
  8156  }
  8157  
  8158  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) doRequest(alt string) (*http.Response, error) {
  8159  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  8160  	var body io.Reader = nil
  8161  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.metadataimport)
  8162  	if err != nil {
  8163  		return nil, err
  8164  	}
  8165  	c.urlParams_.Set("alt", alt)
  8166  	c.urlParams_.Set("prettyPrint", "false")
  8167  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/metadataImports")
  8168  	urls += "?" + c.urlParams_.Encode()
  8169  	req, err := http.NewRequest("POST", urls, body)
  8170  	if err != nil {
  8171  		return nil, err
  8172  	}
  8173  	req.Header = reqHeaders
  8174  	googleapi.Expand(req.URL, map[string]string{
  8175  		"parent": c.parent,
  8176  	})
  8177  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8178  }
  8179  
  8180  // Do executes the "metastore.projects.locations.services.metadataImports.create" call.
  8181  // Any non-2xx status code is an error. Response headers are in either
  8182  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  8183  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  8184  // whether the returned error was because http.StatusNotModified was returned.
  8185  func (c *ProjectsLocationsServicesMetadataImportsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  8186  	gensupport.SetOptions(c.urlParams_, opts...)
  8187  	res, err := c.doRequest("json")
  8188  	if res != nil && res.StatusCode == http.StatusNotModified {
  8189  		if res.Body != nil {
  8190  			res.Body.Close()
  8191  		}
  8192  		return nil, gensupport.WrapError(&googleapi.Error{
  8193  			Code:   res.StatusCode,
  8194  			Header: res.Header,
  8195  		})
  8196  	}
  8197  	if err != nil {
  8198  		return nil, err
  8199  	}
  8200  	defer googleapi.CloseBody(res)
  8201  	if err := googleapi.CheckResponse(res); err != nil {
  8202  		return nil, gensupport.WrapError(err)
  8203  	}
  8204  	ret := &Operation{
  8205  		ServerResponse: googleapi.ServerResponse{
  8206  			Header:         res.Header,
  8207  			HTTPStatusCode: res.StatusCode,
  8208  		},
  8209  	}
  8210  	target := &ret
  8211  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8212  		return nil, err
  8213  	}
  8214  	return ret, nil
  8215  }
  8216  
  8217  type ProjectsLocationsServicesMetadataImportsGetCall struct {
  8218  	s            *APIService
  8219  	name         string
  8220  	urlParams_   gensupport.URLParams
  8221  	ifNoneMatch_ string
  8222  	ctx_         context.Context
  8223  	header_      http.Header
  8224  }
  8225  
  8226  // Get: Gets details of a single import.
  8227  //
  8228  //   - name: The relative resource name of the metadata import to retrieve, in
  8229  //     the following
  8230  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8231  //     }/metadataImports/{import_id}.
  8232  func (r *ProjectsLocationsServicesMetadataImportsService) Get(name string) *ProjectsLocationsServicesMetadataImportsGetCall {
  8233  	c := &ProjectsLocationsServicesMetadataImportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8234  	c.name = name
  8235  	return c
  8236  }
  8237  
  8238  // Fields allows partial responses to be retrieved. See
  8239  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8240  // details.
  8241  func (c *ProjectsLocationsServicesMetadataImportsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMetadataImportsGetCall {
  8242  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8243  	return c
  8244  }
  8245  
  8246  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  8247  // object's ETag matches the given value. This is useful for getting updates
  8248  // only after the object has changed since the last request.
  8249  func (c *ProjectsLocationsServicesMetadataImportsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesMetadataImportsGetCall {
  8250  	c.ifNoneMatch_ = entityTag
  8251  	return c
  8252  }
  8253  
  8254  // Context sets the context to be used in this call's Do method.
  8255  func (c *ProjectsLocationsServicesMetadataImportsGetCall) Context(ctx context.Context) *ProjectsLocationsServicesMetadataImportsGetCall {
  8256  	c.ctx_ = ctx
  8257  	return c
  8258  }
  8259  
  8260  // Header returns a http.Header that can be modified by the caller to add
  8261  // headers to the request.
  8262  func (c *ProjectsLocationsServicesMetadataImportsGetCall) Header() http.Header {
  8263  	if c.header_ == nil {
  8264  		c.header_ = make(http.Header)
  8265  	}
  8266  	return c.header_
  8267  }
  8268  
  8269  func (c *ProjectsLocationsServicesMetadataImportsGetCall) doRequest(alt string) (*http.Response, error) {
  8270  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  8271  	if c.ifNoneMatch_ != "" {
  8272  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  8273  	}
  8274  	var body io.Reader = nil
  8275  	c.urlParams_.Set("alt", alt)
  8276  	c.urlParams_.Set("prettyPrint", "false")
  8277  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  8278  	urls += "?" + c.urlParams_.Encode()
  8279  	req, err := http.NewRequest("GET", urls, body)
  8280  	if err != nil {
  8281  		return nil, err
  8282  	}
  8283  	req.Header = reqHeaders
  8284  	googleapi.Expand(req.URL, map[string]string{
  8285  		"name": c.name,
  8286  	})
  8287  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8288  }
  8289  
  8290  // Do executes the "metastore.projects.locations.services.metadataImports.get" call.
  8291  // Any non-2xx status code is an error. Response headers are in either
  8292  // *MetadataImport.ServerResponse.Header or (if a response was returned at all)
  8293  // in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  8294  // whether the returned error was because http.StatusNotModified was returned.
  8295  func (c *ProjectsLocationsServicesMetadataImportsGetCall) Do(opts ...googleapi.CallOption) (*MetadataImport, error) {
  8296  	gensupport.SetOptions(c.urlParams_, opts...)
  8297  	res, err := c.doRequest("json")
  8298  	if res != nil && res.StatusCode == http.StatusNotModified {
  8299  		if res.Body != nil {
  8300  			res.Body.Close()
  8301  		}
  8302  		return nil, gensupport.WrapError(&googleapi.Error{
  8303  			Code:   res.StatusCode,
  8304  			Header: res.Header,
  8305  		})
  8306  	}
  8307  	if err != nil {
  8308  		return nil, err
  8309  	}
  8310  	defer googleapi.CloseBody(res)
  8311  	if err := googleapi.CheckResponse(res); err != nil {
  8312  		return nil, gensupport.WrapError(err)
  8313  	}
  8314  	ret := &MetadataImport{
  8315  		ServerResponse: googleapi.ServerResponse{
  8316  			Header:         res.Header,
  8317  			HTTPStatusCode: res.StatusCode,
  8318  		},
  8319  	}
  8320  	target := &ret
  8321  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8322  		return nil, err
  8323  	}
  8324  	return ret, nil
  8325  }
  8326  
  8327  type ProjectsLocationsServicesMetadataImportsListCall struct {
  8328  	s            *APIService
  8329  	parent       string
  8330  	urlParams_   gensupport.URLParams
  8331  	ifNoneMatch_ string
  8332  	ctx_         context.Context
  8333  	header_      http.Header
  8334  }
  8335  
  8336  // List: Lists imports in a service.
  8337  //
  8338  //   - parent: The relative resource name of the service whose metadata imports
  8339  //     to list, in the following
  8340  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8341  //     }/metadataImports.
  8342  func (r *ProjectsLocationsServicesMetadataImportsService) List(parent string) *ProjectsLocationsServicesMetadataImportsListCall {
  8343  	c := &ProjectsLocationsServicesMetadataImportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8344  	c.parent = parent
  8345  	return c
  8346  }
  8347  
  8348  // Filter sets the optional parameter "filter": The filter to apply to list
  8349  // results.
  8350  func (c *ProjectsLocationsServicesMetadataImportsListCall) Filter(filter string) *ProjectsLocationsServicesMetadataImportsListCall {
  8351  	c.urlParams_.Set("filter", filter)
  8352  	return c
  8353  }
  8354  
  8355  // OrderBy sets the optional parameter "orderBy": Specify the ordering of
  8356  // results as described in Sorting Order
  8357  // (https://cloud.google.com/apis/design/design_patterns#sorting_order). If not
  8358  // specified, the results will be sorted in the default order.
  8359  func (c *ProjectsLocationsServicesMetadataImportsListCall) OrderBy(orderBy string) *ProjectsLocationsServicesMetadataImportsListCall {
  8360  	c.urlParams_.Set("orderBy", orderBy)
  8361  	return c
  8362  }
  8363  
  8364  // PageSize sets the optional parameter "pageSize": The maximum number of
  8365  // imports to return. The response may contain less than the maximum number. If
  8366  // unspecified, no more than 500 imports are returned. The maximum value is
  8367  // 1000; values above 1000 are changed to 1000.
  8368  func (c *ProjectsLocationsServicesMetadataImportsListCall) PageSize(pageSize int64) *ProjectsLocationsServicesMetadataImportsListCall {
  8369  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  8370  	return c
  8371  }
  8372  
  8373  // PageToken sets the optional parameter "pageToken": A page token, received
  8374  // from a previous DataprocMetastore.ListServices call. Provide this token to
  8375  // retrieve the subsequent page.To retrieve the first page, supply an empty
  8376  // page token.When paginating, other parameters provided to
  8377  // DataprocMetastore.ListServices must match the call that provided the page
  8378  // token.
  8379  func (c *ProjectsLocationsServicesMetadataImportsListCall) PageToken(pageToken string) *ProjectsLocationsServicesMetadataImportsListCall {
  8380  	c.urlParams_.Set("pageToken", pageToken)
  8381  	return c
  8382  }
  8383  
  8384  // Fields allows partial responses to be retrieved. See
  8385  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8386  // details.
  8387  func (c *ProjectsLocationsServicesMetadataImportsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMetadataImportsListCall {
  8388  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8389  	return c
  8390  }
  8391  
  8392  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  8393  // object's ETag matches the given value. This is useful for getting updates
  8394  // only after the object has changed since the last request.
  8395  func (c *ProjectsLocationsServicesMetadataImportsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesMetadataImportsListCall {
  8396  	c.ifNoneMatch_ = entityTag
  8397  	return c
  8398  }
  8399  
  8400  // Context sets the context to be used in this call's Do method.
  8401  func (c *ProjectsLocationsServicesMetadataImportsListCall) Context(ctx context.Context) *ProjectsLocationsServicesMetadataImportsListCall {
  8402  	c.ctx_ = ctx
  8403  	return c
  8404  }
  8405  
  8406  // Header returns a http.Header that can be modified by the caller to add
  8407  // headers to the request.
  8408  func (c *ProjectsLocationsServicesMetadataImportsListCall) Header() http.Header {
  8409  	if c.header_ == nil {
  8410  		c.header_ = make(http.Header)
  8411  	}
  8412  	return c.header_
  8413  }
  8414  
  8415  func (c *ProjectsLocationsServicesMetadataImportsListCall) doRequest(alt string) (*http.Response, error) {
  8416  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  8417  	if c.ifNoneMatch_ != "" {
  8418  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  8419  	}
  8420  	var body io.Reader = nil
  8421  	c.urlParams_.Set("alt", alt)
  8422  	c.urlParams_.Set("prettyPrint", "false")
  8423  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/metadataImports")
  8424  	urls += "?" + c.urlParams_.Encode()
  8425  	req, err := http.NewRequest("GET", urls, body)
  8426  	if err != nil {
  8427  		return nil, err
  8428  	}
  8429  	req.Header = reqHeaders
  8430  	googleapi.Expand(req.URL, map[string]string{
  8431  		"parent": c.parent,
  8432  	})
  8433  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8434  }
  8435  
  8436  // Do executes the "metastore.projects.locations.services.metadataImports.list" call.
  8437  // Any non-2xx status code is an error. Response headers are in either
  8438  // *ListMetadataImportsResponse.ServerResponse.Header or (if a response was
  8439  // returned at all) in error.(*googleapi.Error).Header. Use
  8440  // googleapi.IsNotModified to check whether the returned error was because
  8441  // http.StatusNotModified was returned.
  8442  func (c *ProjectsLocationsServicesMetadataImportsListCall) Do(opts ...googleapi.CallOption) (*ListMetadataImportsResponse, error) {
  8443  	gensupport.SetOptions(c.urlParams_, opts...)
  8444  	res, err := c.doRequest("json")
  8445  	if res != nil && res.StatusCode == http.StatusNotModified {
  8446  		if res.Body != nil {
  8447  			res.Body.Close()
  8448  		}
  8449  		return nil, gensupport.WrapError(&googleapi.Error{
  8450  			Code:   res.StatusCode,
  8451  			Header: res.Header,
  8452  		})
  8453  	}
  8454  	if err != nil {
  8455  		return nil, err
  8456  	}
  8457  	defer googleapi.CloseBody(res)
  8458  	if err := googleapi.CheckResponse(res); err != nil {
  8459  		return nil, gensupport.WrapError(err)
  8460  	}
  8461  	ret := &ListMetadataImportsResponse{
  8462  		ServerResponse: googleapi.ServerResponse{
  8463  			Header:         res.Header,
  8464  			HTTPStatusCode: res.StatusCode,
  8465  		},
  8466  	}
  8467  	target := &ret
  8468  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8469  		return nil, err
  8470  	}
  8471  	return ret, nil
  8472  }
  8473  
  8474  // Pages invokes f for each page of results.
  8475  // A non-nil error returned from f will halt the iteration.
  8476  // The provided context supersedes any context provided to the Context method.
  8477  func (c *ProjectsLocationsServicesMetadataImportsListCall) Pages(ctx context.Context, f func(*ListMetadataImportsResponse) error) error {
  8478  	c.ctx_ = ctx
  8479  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  8480  	for {
  8481  		x, err := c.Do()
  8482  		if err != nil {
  8483  			return err
  8484  		}
  8485  		if err := f(x); err != nil {
  8486  			return err
  8487  		}
  8488  		if x.NextPageToken == "" {
  8489  			return nil
  8490  		}
  8491  		c.PageToken(x.NextPageToken)
  8492  	}
  8493  }
  8494  
  8495  type ProjectsLocationsServicesMetadataImportsPatchCall struct {
  8496  	s              *APIService
  8497  	name           string
  8498  	metadataimport *MetadataImport
  8499  	urlParams_     gensupport.URLParams
  8500  	ctx_           context.Context
  8501  	header_        http.Header
  8502  }
  8503  
  8504  // Patch: Updates a single import. Only the description field of MetadataImport
  8505  // is supported to be updated.
  8506  //
  8507  //   - name: Immutable. The relative resource name of the metadata import, of the
  8508  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8509  //     }/metadataImports/{metadata_import_id}.
  8510  func (r *ProjectsLocationsServicesMetadataImportsService) Patch(name string, metadataimport *MetadataImport) *ProjectsLocationsServicesMetadataImportsPatchCall {
  8511  	c := &ProjectsLocationsServicesMetadataImportsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8512  	c.name = name
  8513  	c.metadataimport = metadataimport
  8514  	return c
  8515  }
  8516  
  8517  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  8518  // unique request ID to allow the server to ignore the request if it has
  8519  // completed. The server will ignore subsequent requests that provide a
  8520  // duplicate request ID for at least 60 minutes after the first request.For
  8521  // example, if an initial request times out, followed by another request with
  8522  // the same request ID, the server ignores the second request to prevent the
  8523  // creation of duplicate commitments.The request ID must be a valid UUID
  8524  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  8525  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  8526  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) RequestId(requestId string) *ProjectsLocationsServicesMetadataImportsPatchCall {
  8527  	c.urlParams_.Set("requestId", requestId)
  8528  	return c
  8529  }
  8530  
  8531  // UpdateMask sets the optional parameter "updateMask": Required. A field mask
  8532  // used to specify the fields to be overwritten in the metadata import resource
  8533  // by the update. Fields specified in the update_mask are relative to the
  8534  // resource (not to the full request). A field is overwritten if it is in the
  8535  // mask.
  8536  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsServicesMetadataImportsPatchCall {
  8537  	c.urlParams_.Set("updateMask", updateMask)
  8538  	return c
  8539  }
  8540  
  8541  // Fields allows partial responses to be retrieved. See
  8542  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8543  // details.
  8544  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMetadataImportsPatchCall {
  8545  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8546  	return c
  8547  }
  8548  
  8549  // Context sets the context to be used in this call's Do method.
  8550  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) Context(ctx context.Context) *ProjectsLocationsServicesMetadataImportsPatchCall {
  8551  	c.ctx_ = ctx
  8552  	return c
  8553  }
  8554  
  8555  // Header returns a http.Header that can be modified by the caller to add
  8556  // headers to the request.
  8557  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) Header() http.Header {
  8558  	if c.header_ == nil {
  8559  		c.header_ = make(http.Header)
  8560  	}
  8561  	return c.header_
  8562  }
  8563  
  8564  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) doRequest(alt string) (*http.Response, error) {
  8565  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  8566  	var body io.Reader = nil
  8567  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.metadataimport)
  8568  	if err != nil {
  8569  		return nil, err
  8570  	}
  8571  	c.urlParams_.Set("alt", alt)
  8572  	c.urlParams_.Set("prettyPrint", "false")
  8573  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  8574  	urls += "?" + c.urlParams_.Encode()
  8575  	req, err := http.NewRequest("PATCH", urls, body)
  8576  	if err != nil {
  8577  		return nil, err
  8578  	}
  8579  	req.Header = reqHeaders
  8580  	googleapi.Expand(req.URL, map[string]string{
  8581  		"name": c.name,
  8582  	})
  8583  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8584  }
  8585  
  8586  // Do executes the "metastore.projects.locations.services.metadataImports.patch" call.
  8587  // Any non-2xx status code is an error. Response headers are in either
  8588  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  8589  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  8590  // whether the returned error was because http.StatusNotModified was returned.
  8591  func (c *ProjectsLocationsServicesMetadataImportsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  8592  	gensupport.SetOptions(c.urlParams_, opts...)
  8593  	res, err := c.doRequest("json")
  8594  	if res != nil && res.StatusCode == http.StatusNotModified {
  8595  		if res.Body != nil {
  8596  			res.Body.Close()
  8597  		}
  8598  		return nil, gensupport.WrapError(&googleapi.Error{
  8599  			Code:   res.StatusCode,
  8600  			Header: res.Header,
  8601  		})
  8602  	}
  8603  	if err != nil {
  8604  		return nil, err
  8605  	}
  8606  	defer googleapi.CloseBody(res)
  8607  	if err := googleapi.CheckResponse(res); err != nil {
  8608  		return nil, gensupport.WrapError(err)
  8609  	}
  8610  	ret := &Operation{
  8611  		ServerResponse: googleapi.ServerResponse{
  8612  			Header:         res.Header,
  8613  			HTTPStatusCode: res.StatusCode,
  8614  		},
  8615  	}
  8616  	target := &ret
  8617  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8618  		return nil, err
  8619  	}
  8620  	return ret, nil
  8621  }
  8622  
  8623  type ProjectsLocationsServicesMigrationExecutionsDeleteCall struct {
  8624  	s          *APIService
  8625  	name       string
  8626  	urlParams_ gensupport.URLParams
  8627  	ctx_       context.Context
  8628  	header_    http.Header
  8629  }
  8630  
  8631  // Delete: Deletes a single migration execution.
  8632  //
  8633  //   - name: The relative resource name of the migrationExecution to delete, in
  8634  //     the following
  8635  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8636  //     }/migrationExecutions/{migration_execution_id}.
  8637  func (r *ProjectsLocationsServicesMigrationExecutionsService) Delete(name string) *ProjectsLocationsServicesMigrationExecutionsDeleteCall {
  8638  	c := &ProjectsLocationsServicesMigrationExecutionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8639  	c.name = name
  8640  	return c
  8641  }
  8642  
  8643  // RequestId sets the optional parameter "requestId": A request ID. Specify a
  8644  // unique request ID to allow the server to ignore the request if it has
  8645  // completed. The server will ignore subsequent requests that provide a
  8646  // duplicate request ID for at least 60 minutes after the first request.For
  8647  // example, if an initial request times out, followed by another request with
  8648  // the same request ID, the server ignores the second request to prevent the
  8649  // creation of duplicate commitments.The request ID must be a valid UUID
  8650  // (https://en.wikipedia.org/wiki/Universally_unique_identifier#Format) A zero
  8651  // UUID (00000000-0000-0000-0000-000000000000) is not supported.
  8652  func (c *ProjectsLocationsServicesMigrationExecutionsDeleteCall) RequestId(requestId string) *ProjectsLocationsServicesMigrationExecutionsDeleteCall {
  8653  	c.urlParams_.Set("requestId", requestId)
  8654  	return c
  8655  }
  8656  
  8657  // Fields allows partial responses to be retrieved. See
  8658  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8659  // details.
  8660  func (c *ProjectsLocationsServicesMigrationExecutionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMigrationExecutionsDeleteCall {
  8661  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8662  	return c
  8663  }
  8664  
  8665  // Context sets the context to be used in this call's Do method.
  8666  func (c *ProjectsLocationsServicesMigrationExecutionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsServicesMigrationExecutionsDeleteCall {
  8667  	c.ctx_ = ctx
  8668  	return c
  8669  }
  8670  
  8671  // Header returns a http.Header that can be modified by the caller to add
  8672  // headers to the request.
  8673  func (c *ProjectsLocationsServicesMigrationExecutionsDeleteCall) Header() http.Header {
  8674  	if c.header_ == nil {
  8675  		c.header_ = make(http.Header)
  8676  	}
  8677  	return c.header_
  8678  }
  8679  
  8680  func (c *ProjectsLocationsServicesMigrationExecutionsDeleteCall) doRequest(alt string) (*http.Response, error) {
  8681  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  8682  	var body io.Reader = nil
  8683  	c.urlParams_.Set("alt", alt)
  8684  	c.urlParams_.Set("prettyPrint", "false")
  8685  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  8686  	urls += "?" + c.urlParams_.Encode()
  8687  	req, err := http.NewRequest("DELETE", urls, body)
  8688  	if err != nil {
  8689  		return nil, err
  8690  	}
  8691  	req.Header = reqHeaders
  8692  	googleapi.Expand(req.URL, map[string]string{
  8693  		"name": c.name,
  8694  	})
  8695  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8696  }
  8697  
  8698  // Do executes the "metastore.projects.locations.services.migrationExecutions.delete" call.
  8699  // Any non-2xx status code is an error. Response headers are in either
  8700  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  8701  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  8702  // whether the returned error was because http.StatusNotModified was returned.
  8703  func (c *ProjectsLocationsServicesMigrationExecutionsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  8704  	gensupport.SetOptions(c.urlParams_, opts...)
  8705  	res, err := c.doRequest("json")
  8706  	if res != nil && res.StatusCode == http.StatusNotModified {
  8707  		if res.Body != nil {
  8708  			res.Body.Close()
  8709  		}
  8710  		return nil, gensupport.WrapError(&googleapi.Error{
  8711  			Code:   res.StatusCode,
  8712  			Header: res.Header,
  8713  		})
  8714  	}
  8715  	if err != nil {
  8716  		return nil, err
  8717  	}
  8718  	defer googleapi.CloseBody(res)
  8719  	if err := googleapi.CheckResponse(res); err != nil {
  8720  		return nil, gensupport.WrapError(err)
  8721  	}
  8722  	ret := &Operation{
  8723  		ServerResponse: googleapi.ServerResponse{
  8724  			Header:         res.Header,
  8725  			HTTPStatusCode: res.StatusCode,
  8726  		},
  8727  	}
  8728  	target := &ret
  8729  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8730  		return nil, err
  8731  	}
  8732  	return ret, nil
  8733  }
  8734  
  8735  type ProjectsLocationsServicesMigrationExecutionsGetCall struct {
  8736  	s            *APIService
  8737  	name         string
  8738  	urlParams_   gensupport.URLParams
  8739  	ifNoneMatch_ string
  8740  	ctx_         context.Context
  8741  	header_      http.Header
  8742  }
  8743  
  8744  // Get: Gets details of a single migration execution.
  8745  //
  8746  //   - name: The relative resource name of the migration execution to retrieve,
  8747  //     in the following
  8748  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8749  //     }/migrationExecutions/{migration_execution_id}.
  8750  func (r *ProjectsLocationsServicesMigrationExecutionsService) Get(name string) *ProjectsLocationsServicesMigrationExecutionsGetCall {
  8751  	c := &ProjectsLocationsServicesMigrationExecutionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8752  	c.name = name
  8753  	return c
  8754  }
  8755  
  8756  // Fields allows partial responses to be retrieved. See
  8757  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8758  // details.
  8759  func (c *ProjectsLocationsServicesMigrationExecutionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMigrationExecutionsGetCall {
  8760  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8761  	return c
  8762  }
  8763  
  8764  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  8765  // object's ETag matches the given value. This is useful for getting updates
  8766  // only after the object has changed since the last request.
  8767  func (c *ProjectsLocationsServicesMigrationExecutionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesMigrationExecutionsGetCall {
  8768  	c.ifNoneMatch_ = entityTag
  8769  	return c
  8770  }
  8771  
  8772  // Context sets the context to be used in this call's Do method.
  8773  func (c *ProjectsLocationsServicesMigrationExecutionsGetCall) Context(ctx context.Context) *ProjectsLocationsServicesMigrationExecutionsGetCall {
  8774  	c.ctx_ = ctx
  8775  	return c
  8776  }
  8777  
  8778  // Header returns a http.Header that can be modified by the caller to add
  8779  // headers to the request.
  8780  func (c *ProjectsLocationsServicesMigrationExecutionsGetCall) Header() http.Header {
  8781  	if c.header_ == nil {
  8782  		c.header_ = make(http.Header)
  8783  	}
  8784  	return c.header_
  8785  }
  8786  
  8787  func (c *ProjectsLocationsServicesMigrationExecutionsGetCall) doRequest(alt string) (*http.Response, error) {
  8788  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  8789  	if c.ifNoneMatch_ != "" {
  8790  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  8791  	}
  8792  	var body io.Reader = nil
  8793  	c.urlParams_.Set("alt", alt)
  8794  	c.urlParams_.Set("prettyPrint", "false")
  8795  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}")
  8796  	urls += "?" + c.urlParams_.Encode()
  8797  	req, err := http.NewRequest("GET", urls, body)
  8798  	if err != nil {
  8799  		return nil, err
  8800  	}
  8801  	req.Header = reqHeaders
  8802  	googleapi.Expand(req.URL, map[string]string{
  8803  		"name": c.name,
  8804  	})
  8805  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8806  }
  8807  
  8808  // Do executes the "metastore.projects.locations.services.migrationExecutions.get" call.
  8809  // Any non-2xx status code is an error. Response headers are in either
  8810  // *MigrationExecution.ServerResponse.Header or (if a response was returned at
  8811  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  8812  // check whether the returned error was because http.StatusNotModified was
  8813  // returned.
  8814  func (c *ProjectsLocationsServicesMigrationExecutionsGetCall) Do(opts ...googleapi.CallOption) (*MigrationExecution, error) {
  8815  	gensupport.SetOptions(c.urlParams_, opts...)
  8816  	res, err := c.doRequest("json")
  8817  	if res != nil && res.StatusCode == http.StatusNotModified {
  8818  		if res.Body != nil {
  8819  			res.Body.Close()
  8820  		}
  8821  		return nil, gensupport.WrapError(&googleapi.Error{
  8822  			Code:   res.StatusCode,
  8823  			Header: res.Header,
  8824  		})
  8825  	}
  8826  	if err != nil {
  8827  		return nil, err
  8828  	}
  8829  	defer googleapi.CloseBody(res)
  8830  	if err := googleapi.CheckResponse(res); err != nil {
  8831  		return nil, gensupport.WrapError(err)
  8832  	}
  8833  	ret := &MigrationExecution{
  8834  		ServerResponse: googleapi.ServerResponse{
  8835  			Header:         res.Header,
  8836  			HTTPStatusCode: res.StatusCode,
  8837  		},
  8838  	}
  8839  	target := &ret
  8840  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8841  		return nil, err
  8842  	}
  8843  	return ret, nil
  8844  }
  8845  
  8846  type ProjectsLocationsServicesMigrationExecutionsListCall struct {
  8847  	s            *APIService
  8848  	parent       string
  8849  	urlParams_   gensupport.URLParams
  8850  	ifNoneMatch_ string
  8851  	ctx_         context.Context
  8852  	header_      http.Header
  8853  }
  8854  
  8855  // List: Lists migration executions on a service.
  8856  //
  8857  //   - parent: The relative resource name of the service whose migration
  8858  //     executions to list, in the following
  8859  //     form:projects/{project_number}/locations/{location_id}/services/{service_id
  8860  //     }/migrationExecutions.
  8861  func (r *ProjectsLocationsServicesMigrationExecutionsService) List(parent string) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8862  	c := &ProjectsLocationsServicesMigrationExecutionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  8863  	c.parent = parent
  8864  	return c
  8865  }
  8866  
  8867  // Filter sets the optional parameter "filter": The filter to apply to list
  8868  // results.
  8869  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) Filter(filter string) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8870  	c.urlParams_.Set("filter", filter)
  8871  	return c
  8872  }
  8873  
  8874  // OrderBy sets the optional parameter "orderBy": Specify the ordering of
  8875  // results as described in Sorting Order
  8876  // (https://cloud.google.com/apis/design/design_patterns#sorting_order). If not
  8877  // specified, the results will be sorted in the default order.
  8878  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) OrderBy(orderBy string) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8879  	c.urlParams_.Set("orderBy", orderBy)
  8880  	return c
  8881  }
  8882  
  8883  // PageSize sets the optional parameter "pageSize": The maximum number of
  8884  // migration executions to return. The response may contain less than the
  8885  // maximum number. If unspecified, no more than 500 migration executions are
  8886  // returned. The maximum value is 1000; values above 1000 are changed to 1000.
  8887  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) PageSize(pageSize int64) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8888  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  8889  	return c
  8890  }
  8891  
  8892  // PageToken sets the optional parameter "pageToken": A page token, received
  8893  // from a previous DataprocMetastore.ListMigrationExecutions call. Provide this
  8894  // token to retrieve the subsequent page.To retrieve the first page, supply an
  8895  // empty page token.When paginating, other parameters provided to
  8896  // DataprocMetastore.ListMigrationExecutions must match the call that provided
  8897  // the page token.
  8898  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) PageToken(pageToken string) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8899  	c.urlParams_.Set("pageToken", pageToken)
  8900  	return c
  8901  }
  8902  
  8903  // Fields allows partial responses to be retrieved. See
  8904  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  8905  // details.
  8906  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8907  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  8908  	return c
  8909  }
  8910  
  8911  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  8912  // object's ETag matches the given value. This is useful for getting updates
  8913  // only after the object has changed since the last request.
  8914  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8915  	c.ifNoneMatch_ = entityTag
  8916  	return c
  8917  }
  8918  
  8919  // Context sets the context to be used in this call's Do method.
  8920  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) Context(ctx context.Context) *ProjectsLocationsServicesMigrationExecutionsListCall {
  8921  	c.ctx_ = ctx
  8922  	return c
  8923  }
  8924  
  8925  // Header returns a http.Header that can be modified by the caller to add
  8926  // headers to the request.
  8927  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) Header() http.Header {
  8928  	if c.header_ == nil {
  8929  		c.header_ = make(http.Header)
  8930  	}
  8931  	return c.header_
  8932  }
  8933  
  8934  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) doRequest(alt string) (*http.Response, error) {
  8935  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  8936  	if c.ifNoneMatch_ != "" {
  8937  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  8938  	}
  8939  	var body io.Reader = nil
  8940  	c.urlParams_.Set("alt", alt)
  8941  	c.urlParams_.Set("prettyPrint", "false")
  8942  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/migrationExecutions")
  8943  	urls += "?" + c.urlParams_.Encode()
  8944  	req, err := http.NewRequest("GET", urls, body)
  8945  	if err != nil {
  8946  		return nil, err
  8947  	}
  8948  	req.Header = reqHeaders
  8949  	googleapi.Expand(req.URL, map[string]string{
  8950  		"parent": c.parent,
  8951  	})
  8952  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  8953  }
  8954  
  8955  // Do executes the "metastore.projects.locations.services.migrationExecutions.list" call.
  8956  // Any non-2xx status code is an error. Response headers are in either
  8957  // *ListMigrationExecutionsResponse.ServerResponse.Header or (if a response was
  8958  // returned at all) in error.(*googleapi.Error).Header. Use
  8959  // googleapi.IsNotModified to check whether the returned error was because
  8960  // http.StatusNotModified was returned.
  8961  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) Do(opts ...googleapi.CallOption) (*ListMigrationExecutionsResponse, error) {
  8962  	gensupport.SetOptions(c.urlParams_, opts...)
  8963  	res, err := c.doRequest("json")
  8964  	if res != nil && res.StatusCode == http.StatusNotModified {
  8965  		if res.Body != nil {
  8966  			res.Body.Close()
  8967  		}
  8968  		return nil, gensupport.WrapError(&googleapi.Error{
  8969  			Code:   res.StatusCode,
  8970  			Header: res.Header,
  8971  		})
  8972  	}
  8973  	if err != nil {
  8974  		return nil, err
  8975  	}
  8976  	defer googleapi.CloseBody(res)
  8977  	if err := googleapi.CheckResponse(res); err != nil {
  8978  		return nil, gensupport.WrapError(err)
  8979  	}
  8980  	ret := &ListMigrationExecutionsResponse{
  8981  		ServerResponse: googleapi.ServerResponse{
  8982  			Header:         res.Header,
  8983  			HTTPStatusCode: res.StatusCode,
  8984  		},
  8985  	}
  8986  	target := &ret
  8987  	if err := gensupport.DecodeResponse(target, res); err != nil {
  8988  		return nil, err
  8989  	}
  8990  	return ret, nil
  8991  }
  8992  
  8993  // Pages invokes f for each page of results.
  8994  // A non-nil error returned from f will halt the iteration.
  8995  // The provided context supersedes any context provided to the Context method.
  8996  func (c *ProjectsLocationsServicesMigrationExecutionsListCall) Pages(ctx context.Context, f func(*ListMigrationExecutionsResponse) error) error {
  8997  	c.ctx_ = ctx
  8998  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  8999  	for {
  9000  		x, err := c.Do()
  9001  		if err != nil {
  9002  			return err
  9003  		}
  9004  		if err := f(x); err != nil {
  9005  			return err
  9006  		}
  9007  		if x.NextPageToken == "" {
  9008  			return nil
  9009  		}
  9010  		c.PageToken(x.NextPageToken)
  9011  	}
  9012  }
  9013  

View as plain text