...

Source file src/google.golang.org/api/osconfig/v1beta/osconfig-gen.go

Documentation: google.golang.org/api/osconfig/v1beta

     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 osconfig provides access to the OS Config API.
     8  //
     9  // For product documentation, see: https://cloud.google.com/compute/docs/osconfig/rest
    10  //
    11  // # Library status
    12  //
    13  // These client libraries are officially supported by Google. However, this
    14  // library is considered complete and is in maintenance mode. This means
    15  // that we will address critical bugs and security issues but will not add
    16  // any new features.
    17  //
    18  // When possible, we recommend using our newer
    19  // [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)
    20  // that are still actively being worked and iterated on.
    21  //
    22  // # Creating a client
    23  //
    24  // Usage example:
    25  //
    26  //	import "google.golang.org/api/osconfig/v1beta"
    27  //	...
    28  //	ctx := context.Background()
    29  //	osconfigService, err := osconfig.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  //	osconfigService, err := osconfig.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  //	osconfigService, err := osconfig.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
    49  //
    50  // See [google.golang.org/api/option.ClientOption] for details on options.
    51  package osconfig // import "google.golang.org/api/osconfig/v1beta"
    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 = "osconfig:v1beta"
    90  const apiName = "osconfig"
    91  const apiVersion = "v1beta"
    92  const basePath = "https://osconfig.googleapis.com/"
    93  const basePathTemplate = "https://osconfig.UNIVERSE_DOMAIN/"
    94  const mtlsBasePath = "https://osconfig.mtls.googleapis.com/"
    95  
    96  // OAuth2 scopes used by this API.
    97  const (
    98  	// See, edit, configure, and delete your Google Cloud data and see the email
    99  	// address for your Google Account.
   100  	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
   101  )
   102  
   103  // NewService creates a new Service.
   104  func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
   105  	scopesOption := internaloption.WithDefaultScopes(
   106  		"https://www.googleapis.com/auth/cloud-platform",
   107  	)
   108  	// NOTE: prepend, so we don't override user-specified scopes.
   109  	opts = append([]option.ClientOption{scopesOption}, opts...)
   110  	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
   111  	opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate))
   112  	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
   113  	opts = append(opts, internaloption.EnableNewAuthLibrary())
   114  	client, endpoint, err := htransport.NewClient(ctx, opts...)
   115  	if err != nil {
   116  		return nil, err
   117  	}
   118  	s, err := New(client)
   119  	if err != nil {
   120  		return nil, err
   121  	}
   122  	if endpoint != "" {
   123  		s.BasePath = endpoint
   124  	}
   125  	return s, nil
   126  }
   127  
   128  // New creates a new Service. It uses the provided http.Client for requests.
   129  //
   130  // Deprecated: please use NewService instead.
   131  // To provide a custom HTTP client, use option.WithHTTPClient.
   132  // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
   133  func New(client *http.Client) (*Service, error) {
   134  	if client == nil {
   135  		return nil, errors.New("client is nil")
   136  	}
   137  	s := &Service{client: client, BasePath: basePath}
   138  	s.Projects = NewProjectsService(s)
   139  	return s, nil
   140  }
   141  
   142  type Service struct {
   143  	client    *http.Client
   144  	BasePath  string // API endpoint base URL
   145  	UserAgent string // optional additional User-Agent fragment
   146  
   147  	Projects *ProjectsService
   148  }
   149  
   150  func (s *Service) userAgent() string {
   151  	if s.UserAgent == "" {
   152  		return googleapi.UserAgent
   153  	}
   154  	return googleapi.UserAgent + " " + s.UserAgent
   155  }
   156  
   157  func NewProjectsService(s *Service) *ProjectsService {
   158  	rs := &ProjectsService{s: s}
   159  	rs.GuestPolicies = NewProjectsGuestPoliciesService(s)
   160  	rs.PatchDeployments = NewProjectsPatchDeploymentsService(s)
   161  	rs.PatchJobs = NewProjectsPatchJobsService(s)
   162  	rs.Zones = NewProjectsZonesService(s)
   163  	return rs
   164  }
   165  
   166  type ProjectsService struct {
   167  	s *Service
   168  
   169  	GuestPolicies *ProjectsGuestPoliciesService
   170  
   171  	PatchDeployments *ProjectsPatchDeploymentsService
   172  
   173  	PatchJobs *ProjectsPatchJobsService
   174  
   175  	Zones *ProjectsZonesService
   176  }
   177  
   178  func NewProjectsGuestPoliciesService(s *Service) *ProjectsGuestPoliciesService {
   179  	rs := &ProjectsGuestPoliciesService{s: s}
   180  	return rs
   181  }
   182  
   183  type ProjectsGuestPoliciesService struct {
   184  	s *Service
   185  }
   186  
   187  func NewProjectsPatchDeploymentsService(s *Service) *ProjectsPatchDeploymentsService {
   188  	rs := &ProjectsPatchDeploymentsService{s: s}
   189  	return rs
   190  }
   191  
   192  type ProjectsPatchDeploymentsService struct {
   193  	s *Service
   194  }
   195  
   196  func NewProjectsPatchJobsService(s *Service) *ProjectsPatchJobsService {
   197  	rs := &ProjectsPatchJobsService{s: s}
   198  	rs.InstanceDetails = NewProjectsPatchJobsInstanceDetailsService(s)
   199  	return rs
   200  }
   201  
   202  type ProjectsPatchJobsService struct {
   203  	s *Service
   204  
   205  	InstanceDetails *ProjectsPatchJobsInstanceDetailsService
   206  }
   207  
   208  func NewProjectsPatchJobsInstanceDetailsService(s *Service) *ProjectsPatchJobsInstanceDetailsService {
   209  	rs := &ProjectsPatchJobsInstanceDetailsService{s: s}
   210  	return rs
   211  }
   212  
   213  type ProjectsPatchJobsInstanceDetailsService struct {
   214  	s *Service
   215  }
   216  
   217  func NewProjectsZonesService(s *Service) *ProjectsZonesService {
   218  	rs := &ProjectsZonesService{s: s}
   219  	rs.Instances = NewProjectsZonesInstancesService(s)
   220  	return rs
   221  }
   222  
   223  type ProjectsZonesService struct {
   224  	s *Service
   225  
   226  	Instances *ProjectsZonesInstancesService
   227  }
   228  
   229  func NewProjectsZonesInstancesService(s *Service) *ProjectsZonesInstancesService {
   230  	rs := &ProjectsZonesInstancesService{s: s}
   231  	return rs
   232  }
   233  
   234  type ProjectsZonesInstancesService struct {
   235  	s *Service
   236  }
   237  
   238  // AptRepository: Represents a single Apt package repository. This repository
   239  // is added to a repo file that is stored at
   240  // `/etc/apt/sources.list.d/google_osconfig.list`.
   241  type AptRepository struct {
   242  	// ArchiveType: Type of archive files in this repository. The default behavior
   243  	// is DEB.
   244  	//
   245  	// Possible values:
   246  	//   "ARCHIVE_TYPE_UNSPECIFIED" - Unspecified.
   247  	//   "DEB" - DEB indicates that the archive contains binary files.
   248  	//   "DEB_SRC" - DEB_SRC indicates that the archive contains source files.
   249  	ArchiveType string `json:"archiveType,omitempty"`
   250  	// Components: Required. List of components for this repository. Must contain
   251  	// at least one item.
   252  	Components []string `json:"components,omitempty"`
   253  	// Distribution: Required. Distribution of this repository.
   254  	Distribution string `json:"distribution,omitempty"`
   255  	// GpgKey: URI of the key file for this repository. The agent maintains a
   256  	// keyring at `/etc/apt/trusted.gpg.d/osconfig_agent_managed.gpg` containing
   257  	// all the keys in any applied guest policy.
   258  	GpgKey string `json:"gpgKey,omitempty"`
   259  	// Uri: Required. URI for this repository.
   260  	Uri string `json:"uri,omitempty"`
   261  	// ForceSendFields is a list of field names (e.g. "ArchiveType") to
   262  	// unconditionally include in API requests. By default, fields with empty or
   263  	// default values are omitted from API requests. See
   264  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   265  	// details.
   266  	ForceSendFields []string `json:"-"`
   267  	// NullFields is a list of field names (e.g. "ArchiveType") to include in API
   268  	// requests with the JSON null value. By default, fields with empty values are
   269  	// omitted from API requests. See
   270  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   271  	NullFields []string `json:"-"`
   272  }
   273  
   274  func (s *AptRepository) MarshalJSON() ([]byte, error) {
   275  	type NoMethod AptRepository
   276  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   277  }
   278  
   279  // AptSettings: Apt patching is completed by executing `apt-get update &&
   280  // apt-get upgrade`. Additional options can be set to control how this is
   281  // executed.
   282  type AptSettings struct {
   283  	// Excludes: List of packages to exclude from update. These packages will be
   284  	// excluded
   285  	Excludes []string `json:"excludes,omitempty"`
   286  	// ExclusivePackages: An exclusive list of packages to be updated. These are
   287  	// the only packages that will be updated. If these packages are not installed,
   288  	// they will be ignored. This field cannot be specified with any other patch
   289  	// configuration fields.
   290  	ExclusivePackages []string `json:"exclusivePackages,omitempty"`
   291  	// Type: By changing the type to DIST, the patching is performed using `apt-get
   292  	// dist-upgrade` instead.
   293  	//
   294  	// Possible values:
   295  	//   "TYPE_UNSPECIFIED" - By default, upgrade will be performed.
   296  	//   "DIST" - Runs `apt-get dist-upgrade`.
   297  	//   "UPGRADE" - Runs `apt-get upgrade`.
   298  	Type string `json:"type,omitempty"`
   299  	// ForceSendFields is a list of field names (e.g. "Excludes") to
   300  	// unconditionally include in API requests. By default, fields with empty or
   301  	// default values are omitted from API requests. See
   302  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   303  	// details.
   304  	ForceSendFields []string `json:"-"`
   305  	// NullFields is a list of field names (e.g. "Excludes") to include in API
   306  	// requests with the JSON null value. By default, fields with empty values are
   307  	// omitted from API requests. See
   308  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   309  	NullFields []string `json:"-"`
   310  }
   311  
   312  func (s *AptSettings) MarshalJSON() ([]byte, error) {
   313  	type NoMethod AptSettings
   314  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   315  }
   316  
   317  // Assignment: An assignment represents the group or groups of VM instances
   318  // that the policy applies to. If an assignment is empty, it applies to all VM
   319  // instances. Otherwise, the targeted VM instances must meet all the criteria
   320  // specified. So if both labels and zones are specified, the policy applies to
   321  // VM instances with those labels and in those zones.
   322  type Assignment struct {
   323  	// GroupLabels: Targets instances matching at least one of these label sets.
   324  	// This allows an assignment to target disparate groups, for example "env=prod
   325  	// or env=staging".
   326  	GroupLabels []*AssignmentGroupLabel `json:"groupLabels,omitempty"`
   327  	// InstanceNamePrefixes: Targets VM instances whose name starts with one of
   328  	// these prefixes. Like labels, this is another way to group VM instances when
   329  	// targeting configs, for example prefix="prod-". Only supported for
   330  	// project-level policies.
   331  	InstanceNamePrefixes []string `json:"instanceNamePrefixes,omitempty"`
   332  	// Instances: Targets any of the instances specified. Instances are specified
   333  	// by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`. Instance
   334  	// targeting is uncommon and is supported to facilitate the management of
   335  	// changes by the instance or to target specific VM instances for development
   336  	// and testing. Only supported for project-level policies and must reference
   337  	// instances within this project.
   338  	Instances []string `json:"instances,omitempty"`
   339  	// OsTypes: Targets VM instances matching at least one of the following OS
   340  	// types. VM instances must match all supplied criteria for a given OsType to
   341  	// be included.
   342  	OsTypes []*AssignmentOsType `json:"osTypes,omitempty"`
   343  	// Zones: Targets instances in any of these zones. Leave empty to target
   344  	// instances in any zone. Zonal targeting is uncommon and is supported to
   345  	// facilitate the management of changes by zone.
   346  	Zones []string `json:"zones,omitempty"`
   347  	// ForceSendFields is a list of field names (e.g. "GroupLabels") to
   348  	// unconditionally include in API requests. By default, fields with empty or
   349  	// default values are omitted from API requests. See
   350  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   351  	// details.
   352  	ForceSendFields []string `json:"-"`
   353  	// NullFields is a list of field names (e.g. "GroupLabels") to include in API
   354  	// requests with the JSON null value. By default, fields with empty values are
   355  	// omitted from API requests. See
   356  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   357  	NullFields []string `json:"-"`
   358  }
   359  
   360  func (s *Assignment) MarshalJSON() ([]byte, error) {
   361  	type NoMethod Assignment
   362  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   363  }
   364  
   365  // AssignmentGroupLabel: Represents a group of VM intances that can be
   366  // identified as having all these labels, for example "env=prod and app=web".
   367  type AssignmentGroupLabel struct {
   368  	// Labels: Google Compute Engine instance labels that must be present for an
   369  	// instance to be included in this assignment group.
   370  	Labels map[string]string `json:"labels,omitempty"`
   371  	// ForceSendFields is a list of field names (e.g. "Labels") to unconditionally
   372  	// include in API requests. By default, fields with empty or default values are
   373  	// omitted from API requests. See
   374  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   375  	// details.
   376  	ForceSendFields []string `json:"-"`
   377  	// NullFields is a list of field names (e.g. "Labels") to include in API
   378  	// requests with the JSON null value. By default, fields with empty values are
   379  	// omitted from API requests. See
   380  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   381  	NullFields []string `json:"-"`
   382  }
   383  
   384  func (s *AssignmentGroupLabel) MarshalJSON() ([]byte, error) {
   385  	type NoMethod AssignmentGroupLabel
   386  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   387  }
   388  
   389  // AssignmentOsType: Defines the criteria for selecting VM Instances by OS
   390  // type.
   391  type AssignmentOsType struct {
   392  	// OsArchitecture: Targets VM instances with OS Inventory enabled and having
   393  	// the following OS architecture.
   394  	OsArchitecture string `json:"osArchitecture,omitempty"`
   395  	// OsShortName: Targets VM instances with OS Inventory enabled and having the
   396  	// following OS short name, for example "debian" or "windows".
   397  	OsShortName string `json:"osShortName,omitempty"`
   398  	// OsVersion: Targets VM instances with OS Inventory enabled and having the
   399  	// following following OS version.
   400  	OsVersion string `json:"osVersion,omitempty"`
   401  	// ForceSendFields is a list of field names (e.g. "OsArchitecture") 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. "OsArchitecture") 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 *AssignmentOsType) MarshalJSON() ([]byte, error) {
   415  	type NoMethod AssignmentOsType
   416  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   417  }
   418  
   419  // CancelPatchJobRequest: Message for canceling a patch job.
   420  type CancelPatchJobRequest struct {
   421  }
   422  
   423  // EffectiveGuestPolicy: The effective guest policy that applies to a VM
   424  // instance.
   425  type EffectiveGuestPolicy struct {
   426  	// PackageRepositories: List of package repository configurations assigned to
   427  	// the VM instance.
   428  	PackageRepositories []*EffectiveGuestPolicySourcedPackageRepository `json:"packageRepositories,omitempty"`
   429  	// Packages: List of package configurations assigned to the VM instance.
   430  	Packages []*EffectiveGuestPolicySourcedPackage `json:"packages,omitempty"`
   431  	// SoftwareRecipes: List of recipes assigned to the VM instance.
   432  	SoftwareRecipes []*EffectiveGuestPolicySourcedSoftwareRecipe `json:"softwareRecipes,omitempty"`
   433  
   434  	// ServerResponse contains the HTTP response code and headers from the server.
   435  	googleapi.ServerResponse `json:"-"`
   436  	// ForceSendFields is a list of field names (e.g. "PackageRepositories") to
   437  	// unconditionally include in API requests. By default, fields with empty or
   438  	// default values are omitted from API requests. See
   439  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   440  	// details.
   441  	ForceSendFields []string `json:"-"`
   442  	// NullFields is a list of field names (e.g. "PackageRepositories") to include
   443  	// in API requests with the JSON null value. By default, fields with empty
   444  	// values are omitted from API requests. See
   445  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   446  	NullFields []string `json:"-"`
   447  }
   448  
   449  func (s *EffectiveGuestPolicy) MarshalJSON() ([]byte, error) {
   450  	type NoMethod EffectiveGuestPolicy
   451  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   452  }
   453  
   454  // EffectiveGuestPolicySourcedPackage: A guest policy package including its
   455  // source.
   456  type EffectiveGuestPolicySourcedPackage struct {
   457  	// Package: A software package to configure on the VM instance.
   458  	Package *Package `json:"package,omitempty"`
   459  	// Source: Name of the guest policy providing this config.
   460  	Source string `json:"source,omitempty"`
   461  	// ForceSendFields is a list of field names (e.g. "Package") to unconditionally
   462  	// include in API requests. By default, fields with empty or default values are
   463  	// omitted from API requests. See
   464  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   465  	// details.
   466  	ForceSendFields []string `json:"-"`
   467  	// NullFields is a list of field names (e.g. "Package") to include in API
   468  	// requests with the JSON null value. By default, fields with empty values are
   469  	// omitted from API requests. See
   470  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   471  	NullFields []string `json:"-"`
   472  }
   473  
   474  func (s *EffectiveGuestPolicySourcedPackage) MarshalJSON() ([]byte, error) {
   475  	type NoMethod EffectiveGuestPolicySourcedPackage
   476  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   477  }
   478  
   479  // EffectiveGuestPolicySourcedPackageRepository: A guest policy package
   480  // repository including its source.
   481  type EffectiveGuestPolicySourcedPackageRepository struct {
   482  	// PackageRepository: A software package repository to configure on the VM
   483  	// instance.
   484  	PackageRepository *PackageRepository `json:"packageRepository,omitempty"`
   485  	// Source: Name of the guest policy providing this config.
   486  	Source string `json:"source,omitempty"`
   487  	// ForceSendFields is a list of field names (e.g. "PackageRepository") to
   488  	// unconditionally include in API requests. By default, fields with empty or
   489  	// default values are omitted from API requests. See
   490  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   491  	// details.
   492  	ForceSendFields []string `json:"-"`
   493  	// NullFields is a list of field names (e.g. "PackageRepository") to include in
   494  	// API requests with the JSON null value. By default, fields with empty values
   495  	// are omitted from API requests. See
   496  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   497  	NullFields []string `json:"-"`
   498  }
   499  
   500  func (s *EffectiveGuestPolicySourcedPackageRepository) MarshalJSON() ([]byte, error) {
   501  	type NoMethod EffectiveGuestPolicySourcedPackageRepository
   502  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   503  }
   504  
   505  // EffectiveGuestPolicySourcedSoftwareRecipe: A guest policy recipe including
   506  // its source.
   507  type EffectiveGuestPolicySourcedSoftwareRecipe struct {
   508  	// SoftwareRecipe: A software recipe to configure on the VM instance.
   509  	SoftwareRecipe *SoftwareRecipe `json:"softwareRecipe,omitempty"`
   510  	// Source: Name of the guest policy providing this config.
   511  	Source string `json:"source,omitempty"`
   512  	// ForceSendFields is a list of field names (e.g. "SoftwareRecipe") to
   513  	// unconditionally include in API requests. By default, fields with empty or
   514  	// default values are omitted from API requests. See
   515  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   516  	// details.
   517  	ForceSendFields []string `json:"-"`
   518  	// NullFields is a list of field names (e.g. "SoftwareRecipe") to include in
   519  	// API requests with the JSON null value. By default, fields with empty values
   520  	// are omitted from API requests. See
   521  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   522  	NullFields []string `json:"-"`
   523  }
   524  
   525  func (s *EffectiveGuestPolicySourcedSoftwareRecipe) MarshalJSON() ([]byte, error) {
   526  	type NoMethod EffectiveGuestPolicySourcedSoftwareRecipe
   527  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   528  }
   529  
   530  // Empty: A generic empty message that you can re-use to avoid defining
   531  // duplicated empty messages in your APIs. A typical example is to use it as
   532  // the request or the response type of an API method. For instance: service Foo
   533  // { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
   534  type Empty struct {
   535  	// ServerResponse contains the HTTP response code and headers from the server.
   536  	googleapi.ServerResponse `json:"-"`
   537  }
   538  
   539  // ExecStep: A step that runs an executable for a PatchJob.
   540  type ExecStep struct {
   541  	// LinuxExecStepConfig: The ExecStepConfig for all Linux VMs targeted by the
   542  	// PatchJob.
   543  	LinuxExecStepConfig *ExecStepConfig `json:"linuxExecStepConfig,omitempty"`
   544  	// WindowsExecStepConfig: The ExecStepConfig for all Windows VMs targeted by
   545  	// the PatchJob.
   546  	WindowsExecStepConfig *ExecStepConfig `json:"windowsExecStepConfig,omitempty"`
   547  	// ForceSendFields is a list of field names (e.g. "LinuxExecStepConfig") to
   548  	// unconditionally include in API requests. By default, fields with empty or
   549  	// default values are omitted from API requests. See
   550  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   551  	// details.
   552  	ForceSendFields []string `json:"-"`
   553  	// NullFields is a list of field names (e.g. "LinuxExecStepConfig") to include
   554  	// in API requests with the JSON null value. By default, fields with empty
   555  	// values are omitted from API requests. See
   556  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   557  	NullFields []string `json:"-"`
   558  }
   559  
   560  func (s *ExecStep) MarshalJSON() ([]byte, error) {
   561  	type NoMethod ExecStep
   562  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   563  }
   564  
   565  // ExecStepConfig: Common configurations for an ExecStep.
   566  type ExecStepConfig struct {
   567  	// AllowedSuccessCodes: Defaults to [0]. A list of possible return values that
   568  	// the execution can return to indicate a success.
   569  	AllowedSuccessCodes []int64 `json:"allowedSuccessCodes,omitempty"`
   570  	// GcsObject: A Google Cloud Storage object containing the executable.
   571  	GcsObject *GcsObject `json:"gcsObject,omitempty"`
   572  	// Interpreter: The script interpreter to use to run the script. If no
   573  	// interpreter is specified the script will be executed directly, which will
   574  	// likely only succeed for scripts with [shebang lines]
   575  	// (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
   576  	//
   577  	// Possible values:
   578  	//   "INTERPRETER_UNSPECIFIED" - If the interpreter is not specified, the value
   579  	// defaults to `NONE`.
   580  	//   "NONE" - Indicates that the file is run as follows on each operating
   581  	// system: + For Linux VMs, the file is ran as an executable and the
   582  	// interpreter might be parsed from the [shebang
   583  	// line](https://wikipedia.org/wiki/Shebang_(Unix)) of the file. + For Windows
   584  	// VM, this value is not supported.
   585  	//   "SHELL" - Indicates that the file is run with `/bin/sh` on Linux and `cmd`
   586  	// on Windows.
   587  	//   "POWERSHELL" - Indicates that the file is run with PowerShell.
   588  	Interpreter string `json:"interpreter,omitempty"`
   589  	// LocalPath: An absolute path to the executable on the VM.
   590  	LocalPath string `json:"localPath,omitempty"`
   591  	// ForceSendFields is a list of field names (e.g. "AllowedSuccessCodes") to
   592  	// unconditionally include in API requests. By default, fields with empty or
   593  	// default values are omitted from API requests. See
   594  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   595  	// details.
   596  	ForceSendFields []string `json:"-"`
   597  	// NullFields is a list of field names (e.g. "AllowedSuccessCodes") to include
   598  	// in API requests with the JSON null value. By default, fields with empty
   599  	// values are omitted from API requests. See
   600  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   601  	NullFields []string `json:"-"`
   602  }
   603  
   604  func (s *ExecStepConfig) MarshalJSON() ([]byte, error) {
   605  	type NoMethod ExecStepConfig
   606  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   607  }
   608  
   609  // ExecutePatchJobRequest: A request message to initiate patching across
   610  // Compute Engine instances.
   611  type ExecutePatchJobRequest struct {
   612  	// Description: Description of the patch job. Length of the description is
   613  	// limited to 1024 characters.
   614  	Description string `json:"description,omitempty"`
   615  	// DisplayName: Display name for this patch job. This does not have to be
   616  	// unique.
   617  	DisplayName string `json:"displayName,omitempty"`
   618  	// DryRun: If this patch is a dry-run only, instances are contacted but will do
   619  	// nothing.
   620  	DryRun bool `json:"dryRun,omitempty"`
   621  	// Duration: Duration of the patch job. After the duration ends, the patch job
   622  	// times out.
   623  	Duration string `json:"duration,omitempty"`
   624  	// InstanceFilter: Required. Instances to patch, either explicitly or filtered
   625  	// by some criteria such as zone or labels.
   626  	InstanceFilter *PatchInstanceFilter `json:"instanceFilter,omitempty"`
   627  	// PatchConfig: Patch configuration being applied. If omitted, instances are
   628  	// patched using the default configurations.
   629  	PatchConfig *PatchConfig `json:"patchConfig,omitempty"`
   630  	// Rollout: Rollout strategy of the patch job.
   631  	Rollout *PatchRollout `json:"rollout,omitempty"`
   632  	// ForceSendFields is a list of field names (e.g. "Description") to
   633  	// unconditionally include in API requests. By default, fields with empty or
   634  	// default values are omitted from API requests. See
   635  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   636  	// details.
   637  	ForceSendFields []string `json:"-"`
   638  	// NullFields is a list of field names (e.g. "Description") to include in API
   639  	// requests with the JSON null value. By default, fields with empty values are
   640  	// omitted from API requests. See
   641  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   642  	NullFields []string `json:"-"`
   643  }
   644  
   645  func (s *ExecutePatchJobRequest) MarshalJSON() ([]byte, error) {
   646  	type NoMethod ExecutePatchJobRequest
   647  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   648  }
   649  
   650  // FixedOrPercent: Message encapsulating a value that can be either absolute
   651  // ("fixed") or relative ("percent") to a value.
   652  type FixedOrPercent struct {
   653  	// Fixed: Specifies a fixed value.
   654  	Fixed int64 `json:"fixed,omitempty"`
   655  	// Percent: Specifies the relative value defined as a percentage, which will be
   656  	// multiplied by a reference value.
   657  	Percent int64 `json:"percent,omitempty"`
   658  	// ForceSendFields is a list of field names (e.g. "Fixed") to unconditionally
   659  	// include in API requests. By default, fields with empty or default values are
   660  	// omitted from API requests. See
   661  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   662  	// details.
   663  	ForceSendFields []string `json:"-"`
   664  	// NullFields is a list of field names (e.g. "Fixed") to include in API
   665  	// requests with the JSON null value. By default, fields with empty values are
   666  	// omitted from API requests. See
   667  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   668  	NullFields []string `json:"-"`
   669  }
   670  
   671  func (s *FixedOrPercent) MarshalJSON() ([]byte, error) {
   672  	type NoMethod FixedOrPercent
   673  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   674  }
   675  
   676  // GcsObject: Google Cloud Storage object representation.
   677  type GcsObject struct {
   678  	// Bucket: Required. Bucket of the Google Cloud Storage object.
   679  	Bucket string `json:"bucket,omitempty"`
   680  	// GenerationNumber: Required. Generation number of the Google Cloud Storage
   681  	// object. This is used to ensure that the ExecStep specified by this PatchJob
   682  	// does not change.
   683  	GenerationNumber int64 `json:"generationNumber,omitempty,string"`
   684  	// Object: Required. Name of the Google Cloud Storage object.
   685  	Object string `json:"object,omitempty"`
   686  	// ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally
   687  	// include in API requests. By default, fields with empty or default values are
   688  	// omitted from API requests. See
   689  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   690  	// details.
   691  	ForceSendFields []string `json:"-"`
   692  	// NullFields is a list of field names (e.g. "Bucket") to include in API
   693  	// requests with the JSON null value. By default, fields with empty values are
   694  	// omitted from API requests. See
   695  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   696  	NullFields []string `json:"-"`
   697  }
   698  
   699  func (s *GcsObject) MarshalJSON() ([]byte, error) {
   700  	type NoMethod GcsObject
   701  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   702  }
   703  
   704  // GooRepository: Represents a Goo package repository. These is added to a repo
   705  // file that is stored at C:/ProgramData/GooGet/repos/google_osconfig.repo.
   706  type GooRepository struct {
   707  	// Name: Required. The name of the repository.
   708  	Name string `json:"name,omitempty"`
   709  	// Url: Required. The url of the repository.
   710  	Url string `json:"url,omitempty"`
   711  	// ForceSendFields is a list of field names (e.g. "Name") to unconditionally
   712  	// include in API requests. By default, fields with empty or default values are
   713  	// omitted from API requests. See
   714  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   715  	// details.
   716  	ForceSendFields []string `json:"-"`
   717  	// NullFields is a list of field names (e.g. "Name") to include in API requests
   718  	// with the JSON null value. By default, fields with empty values are omitted
   719  	// from API requests. See
   720  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   721  	NullFields []string `json:"-"`
   722  }
   723  
   724  func (s *GooRepository) MarshalJSON() ([]byte, error) {
   725  	type NoMethod GooRepository
   726  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   727  }
   728  
   729  // GooSettings: Googet patching is performed by running `googet update`.
   730  type GooSettings struct {
   731  }
   732  
   733  // GoogleCloudOsconfigV1__OSPolicyAssignmentOperationMetadata: OS policy
   734  // assignment operation metadata provided by OS policy assignment API methods
   735  // that return long running operations.
   736  type GoogleCloudOsconfigV1__OSPolicyAssignmentOperationMetadata struct {
   737  	// ApiMethod: The OS policy assignment API method.
   738  	//
   739  	// Possible values:
   740  	//   "API_METHOD_UNSPECIFIED" - Invalid value
   741  	//   "CREATE" - Create OS policy assignment API method
   742  	//   "UPDATE" - Update OS policy assignment API method
   743  	//   "DELETE" - Delete OS policy assignment API method
   744  	ApiMethod string `json:"apiMethod,omitempty"`
   745  	// OsPolicyAssignment: Reference to the `OSPolicyAssignment` API resource.
   746  	// Format:
   747  	// `projects/{project_number}/locations/{location}/osPolicyAssignments/{os_polic
   748  	// y_assignment_id@revision_id}`
   749  	OsPolicyAssignment string `json:"osPolicyAssignment,omitempty"`
   750  	// RolloutStartTime: Rollout start time
   751  	RolloutStartTime string `json:"rolloutStartTime,omitempty"`
   752  	// RolloutState: State of the rollout
   753  	//
   754  	// Possible values:
   755  	//   "ROLLOUT_STATE_UNSPECIFIED" - Invalid value
   756  	//   "IN_PROGRESS" - The rollout is in progress.
   757  	//   "CANCELLING" - The rollout is being cancelled.
   758  	//   "CANCELLED" - The rollout is cancelled.
   759  	//   "SUCCEEDED" - The rollout has completed successfully.
   760  	RolloutState string `json:"rolloutState,omitempty"`
   761  	// RolloutUpdateTime: Rollout update time
   762  	RolloutUpdateTime string `json:"rolloutUpdateTime,omitempty"`
   763  	// ForceSendFields is a list of field names (e.g. "ApiMethod") to
   764  	// unconditionally include in API requests. By default, fields with empty or
   765  	// default values are omitted from API requests. See
   766  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   767  	// details.
   768  	ForceSendFields []string `json:"-"`
   769  	// NullFields is a list of field names (e.g. "ApiMethod") to include in API
   770  	// requests with the JSON null value. By default, fields with empty values are
   771  	// omitted from API requests. See
   772  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   773  	NullFields []string `json:"-"`
   774  }
   775  
   776  func (s *GoogleCloudOsconfigV1__OSPolicyAssignmentOperationMetadata) MarshalJSON() ([]byte, error) {
   777  	type NoMethod GoogleCloudOsconfigV1__OSPolicyAssignmentOperationMetadata
   778  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   779  }
   780  
   781  // GuestPolicy: An OS Config resource representing a guest configuration
   782  // policy. These policies represent the desired state for VM instance guest
   783  // environments including packages to install or remove, package repository
   784  // configurations, and software to install.
   785  type GuestPolicy struct {
   786  	// Assignment: Required. Specifies the VM instances that are assigned to this
   787  	// policy. This allows you to target sets or groups of VM instances by
   788  	// different parameters such as labels, names, OS, or zones. If left empty, all
   789  	// VM instances underneath this policy are targeted. At the same level in the
   790  	// resource hierarchy (that is within a project), the service prevents the
   791  	// creation of multiple policies that conflict with each other. For more
   792  	// information, see how the service handles assignment conflicts
   793  	// (/compute/docs/os-config-management/create-guest-policy#handle-conflicts).
   794  	Assignment *Assignment `json:"assignment,omitempty"`
   795  	// CreateTime: Output only. Time this guest policy was created.
   796  	CreateTime string `json:"createTime,omitempty"`
   797  	// Description: Description of the guest policy. Length of the description is
   798  	// limited to 1024 characters.
   799  	Description string `json:"description,omitempty"`
   800  	// Etag: The etag for this guest policy. If this is provided on update, it must
   801  	// match the server's etag.
   802  	Etag string `json:"etag,omitempty"`
   803  	// Name: Required. Unique name of the resource in this project using one of the
   804  	// following forms:
   805  	// `projects/{project_number}/guestPolicies/{guest_policy_id}`.
   806  	Name string `json:"name,omitempty"`
   807  	// PackageRepositories: A list of package repositories to configure on the VM
   808  	// instance. This is done before any other configs are applied so they can use
   809  	// these repos. Package repositories are only configured if the corresponding
   810  	// package manager(s) are available.
   811  	PackageRepositories []*PackageRepository `json:"packageRepositories,omitempty"`
   812  	// Packages: The software packages to be managed by this policy.
   813  	Packages []*Package `json:"packages,omitempty"`
   814  	// Recipes: A list of Recipes to install on the VM instance.
   815  	Recipes []*SoftwareRecipe `json:"recipes,omitempty"`
   816  	// UpdateTime: Output only. Last time this guest policy was updated.
   817  	UpdateTime string `json:"updateTime,omitempty"`
   818  
   819  	// ServerResponse contains the HTTP response code and headers from the server.
   820  	googleapi.ServerResponse `json:"-"`
   821  	// ForceSendFields is a list of field names (e.g. "Assignment") to
   822  	// unconditionally include in API requests. By default, fields with empty or
   823  	// default values are omitted from API requests. See
   824  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   825  	// details.
   826  	ForceSendFields []string `json:"-"`
   827  	// NullFields is a list of field names (e.g. "Assignment") to include in API
   828  	// requests with the JSON null value. By default, fields with empty values are
   829  	// omitted from API requests. See
   830  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   831  	NullFields []string `json:"-"`
   832  }
   833  
   834  func (s *GuestPolicy) MarshalJSON() ([]byte, error) {
   835  	type NoMethod GuestPolicy
   836  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   837  }
   838  
   839  // ListGuestPoliciesResponse: A response message for listing guest policies.
   840  type ListGuestPoliciesResponse struct {
   841  	// GuestPolicies: The list of GuestPolicies.
   842  	GuestPolicies []*GuestPolicy `json:"guestPolicies,omitempty"`
   843  	// NextPageToken: A pagination token that can be used to get the next page of
   844  	// guest policies.
   845  	NextPageToken string `json:"nextPageToken,omitempty"`
   846  
   847  	// ServerResponse contains the HTTP response code and headers from the server.
   848  	googleapi.ServerResponse `json:"-"`
   849  	// ForceSendFields is a list of field names (e.g. "GuestPolicies") to
   850  	// unconditionally include in API requests. By default, fields with empty or
   851  	// default values are omitted from API requests. See
   852  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   853  	// details.
   854  	ForceSendFields []string `json:"-"`
   855  	// NullFields is a list of field names (e.g. "GuestPolicies") to include in API
   856  	// requests with the JSON null value. By default, fields with empty values are
   857  	// omitted from API requests. See
   858  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   859  	NullFields []string `json:"-"`
   860  }
   861  
   862  func (s *ListGuestPoliciesResponse) MarshalJSON() ([]byte, error) {
   863  	type NoMethod ListGuestPoliciesResponse
   864  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   865  }
   866  
   867  // ListPatchDeploymentsResponse: A response message for listing patch
   868  // deployments.
   869  type ListPatchDeploymentsResponse struct {
   870  	// NextPageToken: A pagination token that can be used to get the next page of
   871  	// patch deployments.
   872  	NextPageToken string `json:"nextPageToken,omitempty"`
   873  	// PatchDeployments: The list of patch deployments.
   874  	PatchDeployments []*PatchDeployment `json:"patchDeployments,omitempty"`
   875  
   876  	// ServerResponse contains the HTTP response code and headers from the server.
   877  	googleapi.ServerResponse `json:"-"`
   878  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
   879  	// unconditionally include in API requests. By default, fields with empty or
   880  	// default values are omitted from API requests. See
   881  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   882  	// details.
   883  	ForceSendFields []string `json:"-"`
   884  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
   885  	// requests with the JSON null value. By default, fields with empty values are
   886  	// omitted from API requests. See
   887  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   888  	NullFields []string `json:"-"`
   889  }
   890  
   891  func (s *ListPatchDeploymentsResponse) MarshalJSON() ([]byte, error) {
   892  	type NoMethod ListPatchDeploymentsResponse
   893  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   894  }
   895  
   896  // ListPatchJobInstanceDetailsResponse: A response message for listing the
   897  // instances details for a patch job.
   898  type ListPatchJobInstanceDetailsResponse struct {
   899  	// NextPageToken: A pagination token that can be used to get the next page of
   900  	// results.
   901  	NextPageToken string `json:"nextPageToken,omitempty"`
   902  	// PatchJobInstanceDetails: A list of instance status.
   903  	PatchJobInstanceDetails []*PatchJobInstanceDetails `json:"patchJobInstanceDetails,omitempty"`
   904  
   905  	// ServerResponse contains the HTTP response code and headers from the server.
   906  	googleapi.ServerResponse `json:"-"`
   907  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
   908  	// unconditionally include in API requests. By default, fields with empty or
   909  	// default values are omitted from API requests. See
   910  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   911  	// details.
   912  	ForceSendFields []string `json:"-"`
   913  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
   914  	// requests with the JSON null value. By default, fields with empty values are
   915  	// omitted from API requests. See
   916  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   917  	NullFields []string `json:"-"`
   918  }
   919  
   920  func (s *ListPatchJobInstanceDetailsResponse) MarshalJSON() ([]byte, error) {
   921  	type NoMethod ListPatchJobInstanceDetailsResponse
   922  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   923  }
   924  
   925  // ListPatchJobsResponse: A response message for listing patch jobs.
   926  type ListPatchJobsResponse struct {
   927  	// NextPageToken: A pagination token that can be used to get the next page of
   928  	// results.
   929  	NextPageToken string `json:"nextPageToken,omitempty"`
   930  	// PatchJobs: The list of patch jobs.
   931  	PatchJobs []*PatchJob `json:"patchJobs,omitempty"`
   932  
   933  	// ServerResponse contains the HTTP response code and headers from the server.
   934  	googleapi.ServerResponse `json:"-"`
   935  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
   936  	// unconditionally include in API requests. By default, fields with empty or
   937  	// default values are omitted from API requests. See
   938  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   939  	// details.
   940  	ForceSendFields []string `json:"-"`
   941  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
   942  	// requests with the JSON null value. By default, fields with empty values are
   943  	// omitted from API requests. See
   944  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   945  	NullFields []string `json:"-"`
   946  }
   947  
   948  func (s *ListPatchJobsResponse) MarshalJSON() ([]byte, error) {
   949  	type NoMethod ListPatchJobsResponse
   950  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   951  }
   952  
   953  // LookupEffectiveGuestPolicyRequest: A request message for getting the
   954  // effective guest policy assigned to the instance.
   955  type LookupEffectiveGuestPolicyRequest struct {
   956  	// OsArchitecture: Architecture of OS running on the instance. The OS Config
   957  	// agent only provides this field for targeting if OS Inventory is enabled for
   958  	// that instance.
   959  	OsArchitecture string `json:"osArchitecture,omitempty"`
   960  	// OsShortName: Short name of the OS running on the instance. The OS Config
   961  	// agent only provides this field for targeting if OS Inventory is enabled for
   962  	// that instance.
   963  	OsShortName string `json:"osShortName,omitempty"`
   964  	// OsVersion: Version of the OS running on the instance. The OS Config agent
   965  	// only provides this field for targeting if OS Inventory is enabled for that
   966  	// VM instance.
   967  	OsVersion string `json:"osVersion,omitempty"`
   968  	// ForceSendFields is a list of field names (e.g. "OsArchitecture") to
   969  	// unconditionally include in API requests. By default, fields with empty or
   970  	// default values are omitted from API requests. See
   971  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   972  	// details.
   973  	ForceSendFields []string `json:"-"`
   974  	// NullFields is a list of field names (e.g. "OsArchitecture") to include in
   975  	// API requests with the JSON null value. By default, fields with empty values
   976  	// are omitted from API requests. See
   977  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   978  	NullFields []string `json:"-"`
   979  }
   980  
   981  func (s *LookupEffectiveGuestPolicyRequest) MarshalJSON() ([]byte, error) {
   982  	type NoMethod LookupEffectiveGuestPolicyRequest
   983  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   984  }
   985  
   986  // MonthlySchedule: Represents a monthly schedule. An example of a valid
   987  // monthly schedule is "on the third Tuesday of the month" or "on the 15th of
   988  // the month".
   989  type MonthlySchedule struct {
   990  	// MonthDay: Required. One day of the month. 1-31 indicates the 1st to the 31st
   991  	// day. -1 indicates the last day of the month. Months without the target day
   992  	// will be skipped. For example, a schedule to run "every month on the 31st"
   993  	// will not run in February, April, June, etc.
   994  	MonthDay int64 `json:"monthDay,omitempty"`
   995  	// WeekDayOfMonth: Required. Week day in a month.
   996  	WeekDayOfMonth *WeekDayOfMonth `json:"weekDayOfMonth,omitempty"`
   997  	// ForceSendFields is a list of field names (e.g. "MonthDay") to
   998  	// unconditionally include in API requests. By default, fields with empty or
   999  	// default values are omitted from API requests. See
  1000  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1001  	// details.
  1002  	ForceSendFields []string `json:"-"`
  1003  	// NullFields is a list of field names (e.g. "MonthDay") to include in API
  1004  	// requests with the JSON null value. By default, fields with empty values are
  1005  	// omitted from API requests. See
  1006  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1007  	NullFields []string `json:"-"`
  1008  }
  1009  
  1010  func (s *MonthlySchedule) MarshalJSON() ([]byte, error) {
  1011  	type NoMethod MonthlySchedule
  1012  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1013  }
  1014  
  1015  // OSPolicyAssignmentOperationMetadata: OS policy assignment operation metadata
  1016  // provided by OS policy assignment API methods that return long running
  1017  // operations.
  1018  type OSPolicyAssignmentOperationMetadata struct {
  1019  	// ApiMethod: The OS policy assignment API method.
  1020  	//
  1021  	// Possible values:
  1022  	//   "API_METHOD_UNSPECIFIED" - Invalid value
  1023  	//   "CREATE" - Create OS policy assignment API method
  1024  	//   "UPDATE" - Update OS policy assignment API method
  1025  	//   "DELETE" - Delete OS policy assignment API method
  1026  	ApiMethod string `json:"apiMethod,omitempty"`
  1027  	// OsPolicyAssignment: Reference to the `OSPolicyAssignment` API resource.
  1028  	// Format:
  1029  	// `projects/{project_number}/locations/{location}/osPolicyAssignments/{os_polic
  1030  	// y_assignment_id@revision_id}`
  1031  	OsPolicyAssignment string `json:"osPolicyAssignment,omitempty"`
  1032  	// RolloutStartTime: Rollout start time
  1033  	RolloutStartTime string `json:"rolloutStartTime,omitempty"`
  1034  	// RolloutState: State of the rollout
  1035  	//
  1036  	// Possible values:
  1037  	//   "ROLLOUT_STATE_UNSPECIFIED" - Invalid value
  1038  	//   "IN_PROGRESS" - The rollout is in progress.
  1039  	//   "CANCELLING" - The rollout is being cancelled.
  1040  	//   "CANCELLED" - The rollout is cancelled.
  1041  	//   "SUCCEEDED" - The rollout has completed successfully.
  1042  	RolloutState string `json:"rolloutState,omitempty"`
  1043  	// RolloutUpdateTime: Rollout update time
  1044  	RolloutUpdateTime string `json:"rolloutUpdateTime,omitempty"`
  1045  	// ForceSendFields is a list of field names (e.g. "ApiMethod") to
  1046  	// unconditionally include in API requests. By default, fields with empty or
  1047  	// default values are omitted from API requests. See
  1048  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1049  	// details.
  1050  	ForceSendFields []string `json:"-"`
  1051  	// NullFields is a list of field names (e.g. "ApiMethod") to include in API
  1052  	// requests with the JSON null value. By default, fields with empty values are
  1053  	// omitted from API requests. See
  1054  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1055  	NullFields []string `json:"-"`
  1056  }
  1057  
  1058  func (s *OSPolicyAssignmentOperationMetadata) MarshalJSON() ([]byte, error) {
  1059  	type NoMethod OSPolicyAssignmentOperationMetadata
  1060  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1061  }
  1062  
  1063  // OneTimeSchedule: Sets the time for a one time patch deployment. Timestamp is
  1064  // in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text format.
  1065  type OneTimeSchedule struct {
  1066  	// ExecuteTime: Required. The desired patch job execution time.
  1067  	ExecuteTime string `json:"executeTime,omitempty"`
  1068  	// ForceSendFields is a list of field names (e.g. "ExecuteTime") to
  1069  	// unconditionally include in API requests. By default, fields with empty or
  1070  	// default values are omitted from API requests. See
  1071  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1072  	// details.
  1073  	ForceSendFields []string `json:"-"`
  1074  	// NullFields is a list of field names (e.g. "ExecuteTime") to include in API
  1075  	// requests with the JSON null value. By default, fields with empty values are
  1076  	// omitted from API requests. See
  1077  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1078  	NullFields []string `json:"-"`
  1079  }
  1080  
  1081  func (s *OneTimeSchedule) MarshalJSON() ([]byte, error) {
  1082  	type NoMethod OneTimeSchedule
  1083  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1084  }
  1085  
  1086  // Package: Package is a reference to the software package to be installed or
  1087  // removed. The agent on the VM instance uses the system package manager to
  1088  // apply the config. These are the commands that the agent uses to install or
  1089  // remove packages. Apt install: `apt-get update && apt-get -y install package1
  1090  // package2 package3` remove: `apt-get -y remove package1 package2 package3`
  1091  // Yum install: `yum -y install package1 package2 package3` remove: `yum -y
  1092  // remove package1 package2 package3` Zypper install: `zypper install package1
  1093  // package2 package3` remove: `zypper rm package1 package2` Googet install:
  1094  // `googet -noconfirm install package1 package2 package3` remove: `googet
  1095  // -noconfirm remove package1 package2 package3`
  1096  type Package struct {
  1097  	// DesiredState: The desired_state the agent should maintain for this package.
  1098  	// The default is to ensure the package is installed.
  1099  	//
  1100  	// Possible values:
  1101  	//   "DESIRED_STATE_UNSPECIFIED" - The default is to ensure the package is
  1102  	// installed.
  1103  	//   "INSTALLED" - The agent ensures that the package is installed.
  1104  	//   "UPDATED" - The agent ensures that the package is installed and
  1105  	// periodically checks for and install any updates.
  1106  	//   "REMOVED" - The agent ensures that the package is not installed and
  1107  	// uninstall it if detected.
  1108  	DesiredState string `json:"desiredState,omitempty"`
  1109  	// Manager: Type of package manager that can be used to install this package.
  1110  	// If a system does not have the package manager, the package is not installed
  1111  	// or removed no error message is returned. By default, or if you specify
  1112  	// `ANY`, the agent attempts to install and remove this package using the
  1113  	// default package manager. This is useful when creating a policy that applies
  1114  	// to different types of systems. The default behavior is ANY.
  1115  	//
  1116  	// Possible values:
  1117  	//   "MANAGER_UNSPECIFIED" - The default behavior is ANY.
  1118  	//   "ANY" - Apply this package config using the default system package
  1119  	// manager.
  1120  	//   "APT" - Apply this package config only if Apt is available on the system.
  1121  	//   "YUM" - Apply this package config only if Yum is available on the system.
  1122  	//   "ZYPPER" - Apply this package config only if Zypper is available on the
  1123  	// system.
  1124  	//   "GOO" - Apply this package config only if GooGet is available on the
  1125  	// system.
  1126  	Manager string `json:"manager,omitempty"`
  1127  	// Name: Required. The name of the package. A package is uniquely identified
  1128  	// for conflict validation by checking the package name and the manager(s) that
  1129  	// the package targets.
  1130  	Name string `json:"name,omitempty"`
  1131  	// ForceSendFields is a list of field names (e.g. "DesiredState") to
  1132  	// unconditionally include in API requests. By default, fields with empty or
  1133  	// default values are omitted from API requests. See
  1134  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1135  	// details.
  1136  	ForceSendFields []string `json:"-"`
  1137  	// NullFields is a list of field names (e.g. "DesiredState") to include in API
  1138  	// requests with the JSON null value. By default, fields with empty values are
  1139  	// omitted from API requests. See
  1140  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1141  	NullFields []string `json:"-"`
  1142  }
  1143  
  1144  func (s *Package) MarshalJSON() ([]byte, error) {
  1145  	type NoMethod Package
  1146  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1147  }
  1148  
  1149  // PackageRepository: A package repository.
  1150  type PackageRepository struct {
  1151  	// Apt: An Apt Repository.
  1152  	Apt *AptRepository `json:"apt,omitempty"`
  1153  	// Goo: A Goo Repository.
  1154  	Goo *GooRepository `json:"goo,omitempty"`
  1155  	// Yum: A Yum Repository.
  1156  	Yum *YumRepository `json:"yum,omitempty"`
  1157  	// Zypper: A Zypper Repository.
  1158  	Zypper *ZypperRepository `json:"zypper,omitempty"`
  1159  	// ForceSendFields is a list of field names (e.g. "Apt") to unconditionally
  1160  	// include in API requests. By default, fields with empty or default values are
  1161  	// omitted from API requests. See
  1162  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1163  	// details.
  1164  	ForceSendFields []string `json:"-"`
  1165  	// NullFields is a list of field names (e.g. "Apt") to include in API requests
  1166  	// with the JSON null value. By default, fields with empty values are omitted
  1167  	// from API requests. See
  1168  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1169  	NullFields []string `json:"-"`
  1170  }
  1171  
  1172  func (s *PackageRepository) MarshalJSON() ([]byte, error) {
  1173  	type NoMethod PackageRepository
  1174  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1175  }
  1176  
  1177  // PatchConfig: Patch configuration specifications. Contains details on how to
  1178  // apply the patch(es) to a VM instance.
  1179  type PatchConfig struct {
  1180  	// Apt: Apt update settings. Use this setting to override the default `apt`
  1181  	// patch rules.
  1182  	Apt *AptSettings `json:"apt,omitempty"`
  1183  	// Goo: Goo update settings. Use this setting to override the default `goo`
  1184  	// patch rules.
  1185  	Goo *GooSettings `json:"goo,omitempty"`
  1186  	// MigInstancesAllowed: Allows the patch job to run on Managed instance groups
  1187  	// (MIGs).
  1188  	MigInstancesAllowed bool `json:"migInstancesAllowed,omitempty"`
  1189  	// PostStep: The `ExecStep` to run after the patch update.
  1190  	PostStep *ExecStep `json:"postStep,omitempty"`
  1191  	// PreStep: The `ExecStep` to run before the patch update.
  1192  	PreStep *ExecStep `json:"preStep,omitempty"`
  1193  	// RebootConfig: Post-patch reboot settings.
  1194  	//
  1195  	// Possible values:
  1196  	//   "REBOOT_CONFIG_UNSPECIFIED" - The default behavior is DEFAULT.
  1197  	//   "DEFAULT" - The agent decides if a reboot is necessary by checking signals
  1198  	// such as registry keys on Windows or `/var/run/reboot-required` on APT based
  1199  	// systems. On RPM based systems, a set of core system package install times
  1200  	// are compared with system boot time.
  1201  	//   "ALWAYS" - Always reboot the machine after the update completes.
  1202  	//   "NEVER" - Never reboot the machine after the update completes.
  1203  	RebootConfig string `json:"rebootConfig,omitempty"`
  1204  	// WindowsUpdate: Windows update settings. Use this override the default
  1205  	// windows patch rules.
  1206  	WindowsUpdate *WindowsUpdateSettings `json:"windowsUpdate,omitempty"`
  1207  	// Yum: Yum update settings. Use this setting to override the default `yum`
  1208  	// patch rules.
  1209  	Yum *YumSettings `json:"yum,omitempty"`
  1210  	// Zypper: Zypper update settings. Use this setting to override the default
  1211  	// `zypper` patch rules.
  1212  	Zypper *ZypperSettings `json:"zypper,omitempty"`
  1213  	// ForceSendFields is a list of field names (e.g. "Apt") to unconditionally
  1214  	// include in API requests. By default, fields with empty or default values are
  1215  	// omitted from API requests. See
  1216  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1217  	// details.
  1218  	ForceSendFields []string `json:"-"`
  1219  	// NullFields is a list of field names (e.g. "Apt") to include in API requests
  1220  	// with the JSON null value. By default, fields with empty values are omitted
  1221  	// from API requests. See
  1222  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1223  	NullFields []string `json:"-"`
  1224  }
  1225  
  1226  func (s *PatchConfig) MarshalJSON() ([]byte, error) {
  1227  	type NoMethod PatchConfig
  1228  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1229  }
  1230  
  1231  // PatchDeployment: Patch deployments are configurations that individual patch
  1232  // jobs use to complete a patch. These configurations include instance filter,
  1233  // package repository settings, and a schedule. For more information about
  1234  // creating and managing patch deployments, see Scheduling patch jobs
  1235  // (https://cloud.google.com/compute/docs/os-patch-management/schedule-patch-jobs).
  1236  type PatchDeployment struct {
  1237  	// CreateTime: Output only. Time the patch deployment was created. Timestamp is
  1238  	// in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text format.
  1239  	CreateTime string `json:"createTime,omitempty"`
  1240  	// Description: Optional. Description of the patch deployment. Length of the
  1241  	// description is limited to 1024 characters.
  1242  	Description string `json:"description,omitempty"`
  1243  	// Duration: Optional. Duration of the patch. After the duration ends, the
  1244  	// patch times out.
  1245  	Duration string `json:"duration,omitempty"`
  1246  	// InstanceFilter: Required. VM instances to patch.
  1247  	InstanceFilter *PatchInstanceFilter `json:"instanceFilter,omitempty"`
  1248  	// LastExecuteTime: Output only. The last time a patch job was started by this
  1249  	// deployment. Timestamp is in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt)
  1250  	// text format.
  1251  	LastExecuteTime string `json:"lastExecuteTime,omitempty"`
  1252  	// Name: Unique name for the patch deployment resource in a project. The patch
  1253  	// deployment name is in the form:
  1254  	// `projects/{project_id}/patchDeployments/{patch_deployment_id}`. This field
  1255  	// is ignored when you create a new patch deployment.
  1256  	Name string `json:"name,omitempty"`
  1257  	// OneTimeSchedule: Required. Schedule a one-time execution.
  1258  	OneTimeSchedule *OneTimeSchedule `json:"oneTimeSchedule,omitempty"`
  1259  	// PatchConfig: Optional. Patch configuration that is applied.
  1260  	PatchConfig *PatchConfig `json:"patchConfig,omitempty"`
  1261  	// RecurringSchedule: Required. Schedule recurring executions.
  1262  	RecurringSchedule *RecurringSchedule `json:"recurringSchedule,omitempty"`
  1263  	// Rollout: Optional. Rollout strategy of the patch job.
  1264  	Rollout *PatchRollout `json:"rollout,omitempty"`
  1265  	// State: Output only. Current state of the patch deployment.
  1266  	//
  1267  	// Possible values:
  1268  	//   "STATE_UNSPECIFIED" - The default value. This value is used if the state
  1269  	// is omitted.
  1270  	//   "ACTIVE" - Active value means that patch deployment generates Patch Jobs.
  1271  	//   "PAUSED" - Paused value means that patch deployment does not generate
  1272  	// Patch jobs. Requires user action to move in and out from this state.
  1273  	State string `json:"state,omitempty"`
  1274  	// UpdateTime: Output only. Time the patch deployment was last updated.
  1275  	// Timestamp is in RFC3339 (https://www.ietf.org/rfc/rfc3339.txt) text format.
  1276  	UpdateTime string `json:"updateTime,omitempty"`
  1277  
  1278  	// ServerResponse contains the HTTP response code and headers from the server.
  1279  	googleapi.ServerResponse `json:"-"`
  1280  	// ForceSendFields is a list of field names (e.g. "CreateTime") to
  1281  	// unconditionally include in API requests. By default, fields with empty or
  1282  	// default values are omitted from API requests. See
  1283  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1284  	// details.
  1285  	ForceSendFields []string `json:"-"`
  1286  	// NullFields is a list of field names (e.g. "CreateTime") to include in API
  1287  	// requests with the JSON null value. By default, fields with empty values are
  1288  	// omitted from API requests. See
  1289  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1290  	NullFields []string `json:"-"`
  1291  }
  1292  
  1293  func (s *PatchDeployment) MarshalJSON() ([]byte, error) {
  1294  	type NoMethod PatchDeployment
  1295  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1296  }
  1297  
  1298  // PatchInstanceFilter: A filter to target VM instances for patching. The
  1299  // targeted VMs must meet all criteria specified. So if both labels and zones
  1300  // are specified, the patch job targets only VMs with those labels and in those
  1301  // zones.
  1302  type PatchInstanceFilter struct {
  1303  	// All: Target all VM instances in the project. If true, no other criteria is
  1304  	// permitted.
  1305  	All bool `json:"all,omitempty"`
  1306  	// GroupLabels: Targets VM instances matching at least one of these label sets.
  1307  	// This allows targeting of disparate groups, for example "env=prod or
  1308  	// env=staging".
  1309  	GroupLabels []*PatchInstanceFilterGroupLabel `json:"groupLabels,omitempty"`
  1310  	// InstanceNamePrefixes: Targets VMs whose name starts with one of these
  1311  	// prefixes. Similar to labels, this is another way to group VMs when targeting
  1312  	// configs, for example prefix="prod-".
  1313  	InstanceNamePrefixes []string `json:"instanceNamePrefixes,omitempty"`
  1314  	// Instances: Targets any of the VM instances specified. Instances are
  1315  	// specified by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`,
  1316  	// `projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`, or
  1317  	// `https://www.googleapis.com/compute/v1/projects/[PROJECT_ID]/zones/[ZONE]/ins
  1318  	// tances/[INSTANCE_NAME]`
  1319  	Instances []string `json:"instances,omitempty"`
  1320  	// Zones: Targets VM instances in ANY of these zones. Leave empty to target VM
  1321  	// instances in any zone.
  1322  	Zones []string `json:"zones,omitempty"`
  1323  	// ForceSendFields is a list of field names (e.g. "All") to unconditionally
  1324  	// include in API requests. By default, fields with empty or default values are
  1325  	// omitted from API requests. See
  1326  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1327  	// details.
  1328  	ForceSendFields []string `json:"-"`
  1329  	// NullFields is a list of field names (e.g. "All") to include in API requests
  1330  	// with the JSON null value. By default, fields with empty values are omitted
  1331  	// from API requests. See
  1332  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1333  	NullFields []string `json:"-"`
  1334  }
  1335  
  1336  func (s *PatchInstanceFilter) MarshalJSON() ([]byte, error) {
  1337  	type NoMethod PatchInstanceFilter
  1338  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1339  }
  1340  
  1341  // PatchInstanceFilterGroupLabel: Represents a group of VMs that can be
  1342  // identified as having all these labels, for example "env=prod and app=web".
  1343  type PatchInstanceFilterGroupLabel struct {
  1344  	// Labels: Compute Engine instance labels that must be present for a VM
  1345  	// instance to be targeted by this filter.
  1346  	Labels map[string]string `json:"labels,omitempty"`
  1347  	// ForceSendFields is a list of field names (e.g. "Labels") to unconditionally
  1348  	// include in API requests. By default, fields with empty or default values are
  1349  	// omitted from API requests. See
  1350  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1351  	// details.
  1352  	ForceSendFields []string `json:"-"`
  1353  	// NullFields is a list of field names (e.g. "Labels") to include in API
  1354  	// requests with the JSON null value. By default, fields with empty values are
  1355  	// omitted from API requests. See
  1356  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1357  	NullFields []string `json:"-"`
  1358  }
  1359  
  1360  func (s *PatchInstanceFilterGroupLabel) MarshalJSON() ([]byte, error) {
  1361  	type NoMethod PatchInstanceFilterGroupLabel
  1362  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1363  }
  1364  
  1365  // PatchJob: A high level representation of a patch job that is either in
  1366  // progress or has completed. Instance details are not included in the job. To
  1367  // paginate through instance details, use `ListPatchJobInstanceDetails`. For
  1368  // more information about patch jobs, see Creating patch jobs
  1369  // (https://cloud.google.com/compute/docs/os-patch-management/create-patch-job).
  1370  type PatchJob struct {
  1371  	// CreateTime: Time this patch job was created.
  1372  	CreateTime string `json:"createTime,omitempty"`
  1373  	// Description: Description of the patch job. Length of the description is
  1374  	// limited to 1024 characters.
  1375  	Description string `json:"description,omitempty"`
  1376  	// DisplayName: Display name for this patch job. This is not a unique
  1377  	// identifier.
  1378  	DisplayName string `json:"displayName,omitempty"`
  1379  	// DryRun: If this patch job is a dry run, the agent reports that it has
  1380  	// finished without running any updates on the VM instance.
  1381  	DryRun bool `json:"dryRun,omitempty"`
  1382  	// Duration: Duration of the patch job. After the duration ends, the patch job
  1383  	// times out.
  1384  	Duration string `json:"duration,omitempty"`
  1385  	// ErrorMessage: If this patch job failed, this message provides information
  1386  	// about the failure.
  1387  	ErrorMessage string `json:"errorMessage,omitempty"`
  1388  	// InstanceDetailsSummary: Summary of instance details.
  1389  	InstanceDetailsSummary *PatchJobInstanceDetailsSummary `json:"instanceDetailsSummary,omitempty"`
  1390  	// InstanceFilter: Instances to patch.
  1391  	InstanceFilter *PatchInstanceFilter `json:"instanceFilter,omitempty"`
  1392  	// Name: Unique identifier for this patch job in the form
  1393  	// `projects/*/patchJobs/*`
  1394  	Name string `json:"name,omitempty"`
  1395  	// PatchConfig: Patch configuration being applied.
  1396  	PatchConfig *PatchConfig `json:"patchConfig,omitempty"`
  1397  	// PatchDeployment: Output only. Name of the patch deployment that created this
  1398  	// patch job.
  1399  	PatchDeployment string `json:"patchDeployment,omitempty"`
  1400  	// PercentComplete: Reflects the overall progress of the patch job in the range
  1401  	// of 0.0 being no progress to 100.0 being complete.
  1402  	PercentComplete float64 `json:"percentComplete,omitempty"`
  1403  	// Rollout: Rollout strategy being applied.
  1404  	Rollout *PatchRollout `json:"rollout,omitempty"`
  1405  	// State: The current state of the PatchJob.
  1406  	//
  1407  	// Possible values:
  1408  	//   "STATE_UNSPECIFIED" - State must be specified.
  1409  	//   "STARTED" - The patch job was successfully initiated.
  1410  	//   "INSTANCE_LOOKUP" - The patch job is looking up instances to run the patch
  1411  	// on.
  1412  	//   "PATCHING" - Instances are being patched.
  1413  	//   "SUCCEEDED" - Patch job completed successfully.
  1414  	//   "COMPLETED_WITH_ERRORS" - Patch job completed but there were errors.
  1415  	//   "CANCELED" - The patch job was canceled.
  1416  	//   "TIMED_OUT" - The patch job timed out.
  1417  	State string `json:"state,omitempty"`
  1418  	// UpdateTime: Last time this patch job was updated.
  1419  	UpdateTime string `json:"updateTime,omitempty"`
  1420  
  1421  	// ServerResponse contains the HTTP response code and headers from the server.
  1422  	googleapi.ServerResponse `json:"-"`
  1423  	// ForceSendFields is a list of field names (e.g. "CreateTime") to
  1424  	// unconditionally include in API requests. By default, fields with empty or
  1425  	// default values are omitted from API requests. See
  1426  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1427  	// details.
  1428  	ForceSendFields []string `json:"-"`
  1429  	// NullFields is a list of field names (e.g. "CreateTime") to include in API
  1430  	// requests with the JSON null value. By default, fields with empty values are
  1431  	// omitted from API requests. See
  1432  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1433  	NullFields []string `json:"-"`
  1434  }
  1435  
  1436  func (s *PatchJob) MarshalJSON() ([]byte, error) {
  1437  	type NoMethod PatchJob
  1438  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1439  }
  1440  
  1441  func (s *PatchJob) UnmarshalJSON(data []byte) error {
  1442  	type NoMethod PatchJob
  1443  	var s1 struct {
  1444  		PercentComplete gensupport.JSONFloat64 `json:"percentComplete"`
  1445  		*NoMethod
  1446  	}
  1447  	s1.NoMethod = (*NoMethod)(s)
  1448  	if err := json.Unmarshal(data, &s1); err != nil {
  1449  		return err
  1450  	}
  1451  	s.PercentComplete = float64(s1.PercentComplete)
  1452  	return nil
  1453  }
  1454  
  1455  // PatchJobInstanceDetails: Patch details for a VM instance. For more
  1456  // information about reviewing VM instance details, see Listing all VM instance
  1457  // details for a specific patch job
  1458  // (https://cloud.google.com/compute/docs/os-patch-management/manage-patch-jobs#list-instance-details).
  1459  type PatchJobInstanceDetails struct {
  1460  	// AttemptCount: The number of times the agent that the agent attempts to apply
  1461  	// the patch.
  1462  	AttemptCount int64 `json:"attemptCount,omitempty,string"`
  1463  	// FailureReason: If the patch fails, this field provides the reason.
  1464  	FailureReason string `json:"failureReason,omitempty"`
  1465  	// InstanceSystemId: The unique identifier for the instance. This identifier is
  1466  	// defined by the server.
  1467  	InstanceSystemId string `json:"instanceSystemId,omitempty"`
  1468  	// Name: The instance name in the form `projects/*/zones/*/instances/*`
  1469  	Name string `json:"name,omitempty"`
  1470  	// State: Current state of instance patch.
  1471  	//
  1472  	// Possible values:
  1473  	//   "PATCH_STATE_UNSPECIFIED" - Unspecified.
  1474  	//   "PENDING" - The instance is not yet notified.
  1475  	//   "INACTIVE" - Instance is inactive and cannot be patched.
  1476  	//   "NOTIFIED" - The instance is notified that it should be patched.
  1477  	//   "STARTED" - The instance has started the patching process.
  1478  	//   "DOWNLOADING_PATCHES" - The instance is downloading patches.
  1479  	//   "APPLYING_PATCHES" - The instance is applying patches.
  1480  	//   "REBOOTING" - The instance is rebooting.
  1481  	//   "SUCCEEDED" - The instance has completed applying patches.
  1482  	//   "SUCCEEDED_REBOOT_REQUIRED" - The instance has completed applying patches
  1483  	// but a reboot is required.
  1484  	//   "FAILED" - The instance has failed to apply the patch.
  1485  	//   "ACKED" - The instance acked the notification and will start shortly.
  1486  	//   "TIMED_OUT" - The instance exceeded the time out while applying the patch.
  1487  	//   "RUNNING_PRE_PATCH_STEP" - The instance is running the pre-patch step.
  1488  	//   "RUNNING_POST_PATCH_STEP" - The instance is running the post-patch step.
  1489  	//   "NO_AGENT_DETECTED" - The service could not detect the presence of the
  1490  	// agent. Check to ensure that the agent is installed, running, and able to
  1491  	// communicate with the service.
  1492  	State string `json:"state,omitempty"`
  1493  	// ForceSendFields is a list of field names (e.g. "AttemptCount") to
  1494  	// unconditionally include in API requests. By default, fields with empty or
  1495  	// default values are omitted from API requests. See
  1496  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1497  	// details.
  1498  	ForceSendFields []string `json:"-"`
  1499  	// NullFields is a list of field names (e.g. "AttemptCount") to include in API
  1500  	// requests with the JSON null value. By default, fields with empty values are
  1501  	// omitted from API requests. See
  1502  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1503  	NullFields []string `json:"-"`
  1504  }
  1505  
  1506  func (s *PatchJobInstanceDetails) MarshalJSON() ([]byte, error) {
  1507  	type NoMethod PatchJobInstanceDetails
  1508  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1509  }
  1510  
  1511  // PatchJobInstanceDetailsSummary: A summary of the current patch state across
  1512  // all instances that this patch job affects. Contains counts of instances in
  1513  // different states. These states map to `InstancePatchState`. List patch job
  1514  // instance details to see the specific states of each instance.
  1515  type PatchJobInstanceDetailsSummary struct {
  1516  	// AckedInstanceCount: Number of instances that have acked and will start
  1517  	// shortly.
  1518  	AckedInstanceCount int64 `json:"ackedInstanceCount,omitempty,string"`
  1519  	// ApplyingPatchesInstanceCount: Number of instances that are applying patches.
  1520  	ApplyingPatchesInstanceCount int64 `json:"applyingPatchesInstanceCount,omitempty,string"`
  1521  	// DownloadingPatchesInstanceCount: Number of instances that are downloading
  1522  	// patches.
  1523  	DownloadingPatchesInstanceCount int64 `json:"downloadingPatchesInstanceCount,omitempty,string"`
  1524  	// FailedInstanceCount: Number of instances that failed.
  1525  	FailedInstanceCount int64 `json:"failedInstanceCount,omitempty,string"`
  1526  	// InactiveInstanceCount: Number of instances that are inactive.
  1527  	InactiveInstanceCount int64 `json:"inactiveInstanceCount,omitempty,string"`
  1528  	// NoAgentDetectedInstanceCount: Number of instances that do not appear to be
  1529  	// running the agent. Check to ensure that the agent is installed, running, and
  1530  	// able to communicate with the service.
  1531  	NoAgentDetectedInstanceCount int64 `json:"noAgentDetectedInstanceCount,omitempty,string"`
  1532  	// NotifiedInstanceCount: Number of instances notified about patch job.
  1533  	NotifiedInstanceCount int64 `json:"notifiedInstanceCount,omitempty,string"`
  1534  	// PendingInstanceCount: Number of instances pending patch job.
  1535  	PendingInstanceCount int64 `json:"pendingInstanceCount,omitempty,string"`
  1536  	// PostPatchStepInstanceCount: Number of instances that are running the
  1537  	// post-patch step.
  1538  	PostPatchStepInstanceCount int64 `json:"postPatchStepInstanceCount,omitempty,string"`
  1539  	// PrePatchStepInstanceCount: Number of instances that are running the
  1540  	// pre-patch step.
  1541  	PrePatchStepInstanceCount int64 `json:"prePatchStepInstanceCount,omitempty,string"`
  1542  	// RebootingInstanceCount: Number of instances rebooting.
  1543  	RebootingInstanceCount int64 `json:"rebootingInstanceCount,omitempty,string"`
  1544  	// StartedInstanceCount: Number of instances that have started.
  1545  	StartedInstanceCount int64 `json:"startedInstanceCount,omitempty,string"`
  1546  	// SucceededInstanceCount: Number of instances that have completed
  1547  	// successfully.
  1548  	SucceededInstanceCount int64 `json:"succeededInstanceCount,omitempty,string"`
  1549  	// SucceededRebootRequiredInstanceCount: Number of instances that require
  1550  	// reboot.
  1551  	SucceededRebootRequiredInstanceCount int64 `json:"succeededRebootRequiredInstanceCount,omitempty,string"`
  1552  	// TimedOutInstanceCount: Number of instances that exceeded the time out while
  1553  	// applying the patch.
  1554  	TimedOutInstanceCount int64 `json:"timedOutInstanceCount,omitempty,string"`
  1555  	// ForceSendFields is a list of field names (e.g. "AckedInstanceCount") to
  1556  	// unconditionally include in API requests. By default, fields with empty or
  1557  	// default values are omitted from API requests. See
  1558  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1559  	// details.
  1560  	ForceSendFields []string `json:"-"`
  1561  	// NullFields is a list of field names (e.g. "AckedInstanceCount") to include
  1562  	// in API requests with the JSON null value. By default, fields with empty
  1563  	// values are omitted from API requests. See
  1564  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1565  	NullFields []string `json:"-"`
  1566  }
  1567  
  1568  func (s *PatchJobInstanceDetailsSummary) MarshalJSON() ([]byte, error) {
  1569  	type NoMethod PatchJobInstanceDetailsSummary
  1570  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1571  }
  1572  
  1573  // PatchRollout: Patch rollout configuration specifications. Contains details
  1574  // on the concurrency control when applying patch(es) to all targeted VMs.
  1575  type PatchRollout struct {
  1576  	// DisruptionBudget: The maximum number (or percentage) of VMs per zone to
  1577  	// disrupt at any given moment. The number of VMs calculated from multiplying
  1578  	// the percentage by the total number of VMs in a zone is rounded up. During
  1579  	// patching, a VM is considered disrupted from the time the agent is notified
  1580  	// to begin until patching has completed. This disruption time includes the
  1581  	// time to complete reboot and any post-patch steps. A VM contributes to the
  1582  	// disruption budget if its patching operation fails either when applying the
  1583  	// patches, running pre or post patch steps, or if it fails to respond with a
  1584  	// success notification before timing out. VMs that are not running or do not
  1585  	// have an active agent do not count toward this disruption budget. For
  1586  	// zone-by-zone rollouts, if the disruption budget in a zone is exceeded, the
  1587  	// patch job stops, because continuing to the next zone requires completion of
  1588  	// the patch process in the previous zone. For example, if the disruption
  1589  	// budget has a fixed value of `10`, and 8 VMs fail to patch in the current
  1590  	// zone, the patch job continues to patch 2 VMs at a time until the zone is
  1591  	// completed. When that zone is completed successfully, patching begins with 10
  1592  	// VMs at a time in the next zone. If 10 VMs in the next zone fail to patch,
  1593  	// the patch job stops.
  1594  	DisruptionBudget *FixedOrPercent `json:"disruptionBudget,omitempty"`
  1595  	// Mode: Mode of the patch rollout.
  1596  	//
  1597  	// Possible values:
  1598  	//   "MODE_UNSPECIFIED" - Mode must be specified.
  1599  	//   "ZONE_BY_ZONE" - Patches are applied one zone at a time. The patch job
  1600  	// begins in the region with the lowest number of targeted VMs. Within the
  1601  	// region, patching begins in the zone with the lowest number of targeted VMs.
  1602  	// If multiple regions (or zones within a region) have the same number of
  1603  	// targeted VMs, a tie-breaker is achieved by sorting the regions or zones in
  1604  	// alphabetical order.
  1605  	//   "CONCURRENT_ZONES" - Patches are applied to VMs in all zones at the same
  1606  	// time.
  1607  	Mode string `json:"mode,omitempty"`
  1608  	// ForceSendFields is a list of field names (e.g. "DisruptionBudget") to
  1609  	// unconditionally include in API requests. By default, fields with empty or
  1610  	// default values are omitted from API requests. See
  1611  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1612  	// details.
  1613  	ForceSendFields []string `json:"-"`
  1614  	// NullFields is a list of field names (e.g. "DisruptionBudget") to include in
  1615  	// API requests with the JSON null value. By default, fields with empty values
  1616  	// are omitted from API requests. See
  1617  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1618  	NullFields []string `json:"-"`
  1619  }
  1620  
  1621  func (s *PatchRollout) MarshalJSON() ([]byte, error) {
  1622  	type NoMethod PatchRollout
  1623  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1624  }
  1625  
  1626  // PausePatchDeploymentRequest: A request message for pausing a patch
  1627  // deployment.
  1628  type PausePatchDeploymentRequest struct {
  1629  }
  1630  
  1631  // RecurringSchedule: Sets the time for recurring patch deployments.
  1632  type RecurringSchedule struct {
  1633  	// EndTime: Optional. The end time at which a recurring patch deployment
  1634  	// schedule is no longer active.
  1635  	EndTime string `json:"endTime,omitempty"`
  1636  	// Frequency: Required. The frequency unit of this recurring schedule.
  1637  	//
  1638  	// Possible values:
  1639  	//   "FREQUENCY_UNSPECIFIED" - Invalid. A frequency must be specified.
  1640  	//   "WEEKLY" - Indicates that the frequency of recurrence should be expressed
  1641  	// in terms of weeks.
  1642  	//   "MONTHLY" - Indicates that the frequency of recurrence should be expressed
  1643  	// in terms of months.
  1644  	//   "DAILY" - Indicates that the frequency of recurrence should be expressed
  1645  	// in terms of days.
  1646  	Frequency string `json:"frequency,omitempty"`
  1647  	// LastExecuteTime: Output only. The time the last patch job ran successfully.
  1648  	LastExecuteTime string `json:"lastExecuteTime,omitempty"`
  1649  	// Monthly: Required. Schedule with monthly executions.
  1650  	Monthly *MonthlySchedule `json:"monthly,omitempty"`
  1651  	// NextExecuteTime: Output only. The time the next patch job is scheduled to
  1652  	// run.
  1653  	NextExecuteTime string `json:"nextExecuteTime,omitempty"`
  1654  	// StartTime: Optional. The time that the recurring schedule becomes effective.
  1655  	// Defaults to `create_time` of the patch deployment.
  1656  	StartTime string `json:"startTime,omitempty"`
  1657  	// TimeOfDay: Required. Time of the day to run a recurring deployment.
  1658  	TimeOfDay *TimeOfDay `json:"timeOfDay,omitempty"`
  1659  	// TimeZone: Required. Defines the time zone that `time_of_day` is relative to.
  1660  	// The rules for daylight saving time are determined by the chosen time zone.
  1661  	TimeZone *TimeZone `json:"timeZone,omitempty"`
  1662  	// Weekly: Required. Schedule with weekly executions.
  1663  	Weekly *WeeklySchedule `json:"weekly,omitempty"`
  1664  	// ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally
  1665  	// include in API requests. By default, fields with empty or default values are
  1666  	// omitted from API requests. See
  1667  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1668  	// details.
  1669  	ForceSendFields []string `json:"-"`
  1670  	// NullFields is a list of field names (e.g. "EndTime") to include in API
  1671  	// requests with the JSON null value. By default, fields with empty values are
  1672  	// omitted from API requests. See
  1673  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1674  	NullFields []string `json:"-"`
  1675  }
  1676  
  1677  func (s *RecurringSchedule) MarshalJSON() ([]byte, error) {
  1678  	type NoMethod RecurringSchedule
  1679  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1680  }
  1681  
  1682  // ResumePatchDeploymentRequest: A request message for resuming a patch
  1683  // deployment.
  1684  type ResumePatchDeploymentRequest struct {
  1685  }
  1686  
  1687  // SoftwareRecipe: A software recipe is a set of instructions for installing
  1688  // and configuring a piece of software. It consists of a set of artifacts that
  1689  // are downloaded, and a set of steps that install, configure, and/or update
  1690  // the software. Recipes support installing and updating software from
  1691  // artifacts in the following formats: Zip archive, Tar archive, Windows MSI,
  1692  // Debian package, and RPM package. Additionally, recipes support executing a
  1693  // script (either defined in a file or directly in this api) in bash, sh, cmd,
  1694  // and powershell. Updating a software recipe If a recipe is assigned to an
  1695  // instance and there is a recipe with the same name but a lower version
  1696  // already installed and the assigned state of the recipe is `UPDATED`, then
  1697  // the recipe is updated to the new version. Script Working Directories Each
  1698  // script or execution step is run in its own temporary directory which is
  1699  // deleted after completing the step.
  1700  type SoftwareRecipe struct {
  1701  	// Artifacts: Resources available to be used in the steps in the recipe.
  1702  	Artifacts []*SoftwareRecipeArtifact `json:"artifacts,omitempty"`
  1703  	// DesiredState: Default is INSTALLED. The desired state the agent should
  1704  	// maintain for this recipe. INSTALLED: The software recipe is installed on the
  1705  	// instance but won't be updated to new versions. UPDATED: The software recipe
  1706  	// is installed on the instance. The recipe is updated to a higher version, if
  1707  	// a higher version of the recipe is assigned to this instance. REMOVE: Remove
  1708  	// is unsupported for software recipes and attempts to create or update a
  1709  	// recipe to the REMOVE state is rejected.
  1710  	//
  1711  	// Possible values:
  1712  	//   "DESIRED_STATE_UNSPECIFIED" - The default is to ensure the package is
  1713  	// installed.
  1714  	//   "INSTALLED" - The agent ensures that the package is installed.
  1715  	//   "UPDATED" - The agent ensures that the package is installed and
  1716  	// periodically checks for and install any updates.
  1717  	//   "REMOVED" - The agent ensures that the package is not installed and
  1718  	// uninstall it if detected.
  1719  	DesiredState string `json:"desiredState,omitempty"`
  1720  	// InstallSteps: Actions to be taken for installing this recipe. On failure it
  1721  	// stops executing steps and does not attempt another installation. Any steps
  1722  	// taken (including partially completed steps) are not rolled back.
  1723  	InstallSteps []*SoftwareRecipeStep `json:"installSteps,omitempty"`
  1724  	// Name: Required. Unique identifier for the recipe. Only one recipe with a
  1725  	// given name is installed on an instance. Names are also used to identify
  1726  	// resources which helps to determine whether guest policies have conflicts.
  1727  	// This means that requests to create multiple recipes with the same name and
  1728  	// version are rejected since they could potentially have conflicting
  1729  	// assignments.
  1730  	Name string `json:"name,omitempty"`
  1731  	// UpdateSteps: Actions to be taken for updating this recipe. On failure it
  1732  	// stops executing steps and does not attempt another update for this recipe.
  1733  	// Any steps taken (including partially completed steps) are not rolled back.
  1734  	UpdateSteps []*SoftwareRecipeStep `json:"updateSteps,omitempty"`
  1735  	// Version: The version of this software recipe. Version can be up to 4 period
  1736  	// separated numbers (e.g. 12.34.56.78).
  1737  	Version string `json:"version,omitempty"`
  1738  	// ForceSendFields is a list of field names (e.g. "Artifacts") to
  1739  	// unconditionally include in API requests. By default, fields with empty or
  1740  	// default values are omitted from API requests. See
  1741  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1742  	// details.
  1743  	ForceSendFields []string `json:"-"`
  1744  	// NullFields is a list of field names (e.g. "Artifacts") to include in API
  1745  	// requests with the JSON null value. By default, fields with empty values are
  1746  	// omitted from API requests. See
  1747  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1748  	NullFields []string `json:"-"`
  1749  }
  1750  
  1751  func (s *SoftwareRecipe) MarshalJSON() ([]byte, error) {
  1752  	type NoMethod SoftwareRecipe
  1753  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1754  }
  1755  
  1756  // SoftwareRecipeArtifact: Specifies a resource to be used in the recipe.
  1757  type SoftwareRecipeArtifact struct {
  1758  	// AllowInsecure: Defaults to false. When false, recipes are subject to
  1759  	// validations based on the artifact type: Remote: A checksum must be
  1760  	// specified, and only protocols with transport-layer security are permitted.
  1761  	// GCS: An object generation number must be specified.
  1762  	AllowInsecure bool `json:"allowInsecure,omitempty"`
  1763  	// Gcs: A Google Cloud Storage artifact.
  1764  	Gcs *SoftwareRecipeArtifactGcs `json:"gcs,omitempty"`
  1765  	// Id: Required. Id of the artifact, which the installation and update steps of
  1766  	// this recipe can reference. Artifacts in a recipe cannot have the same id.
  1767  	Id string `json:"id,omitempty"`
  1768  	// Remote: A generic remote artifact.
  1769  	Remote *SoftwareRecipeArtifactRemote `json:"remote,omitempty"`
  1770  	// ForceSendFields is a list of field names (e.g. "AllowInsecure") to
  1771  	// unconditionally include in API requests. By default, fields with empty or
  1772  	// default values are omitted from API requests. See
  1773  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1774  	// details.
  1775  	ForceSendFields []string `json:"-"`
  1776  	// NullFields is a list of field names (e.g. "AllowInsecure") to include in API
  1777  	// requests with the JSON null value. By default, fields with empty values are
  1778  	// omitted from API requests. See
  1779  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1780  	NullFields []string `json:"-"`
  1781  }
  1782  
  1783  func (s *SoftwareRecipeArtifact) MarshalJSON() ([]byte, error) {
  1784  	type NoMethod SoftwareRecipeArtifact
  1785  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1786  }
  1787  
  1788  // SoftwareRecipeArtifactGcs: Specifies an artifact available as a Google Cloud
  1789  // Storage object.
  1790  type SoftwareRecipeArtifactGcs struct {
  1791  	// Bucket: Bucket of the Google Cloud Storage object. Given an example URL:
  1792  	// `https://storage.googleapis.com/my-bucket/foo/bar#1234567` this value would
  1793  	// be `my-bucket`.
  1794  	Bucket string `json:"bucket,omitempty"`
  1795  	// Generation: Must be provided if allow_insecure is false. Generation number
  1796  	// of the Google Cloud Storage object.
  1797  	// `https://storage.googleapis.com/my-bucket/foo/bar#1234567` this value would
  1798  	// be `1234567`.
  1799  	Generation int64 `json:"generation,omitempty,string"`
  1800  	// Object: Name of the Google Cloud Storage object. As specified [here]
  1801  	// (https://cloud.google.com/storage/docs/naming#objectnames) Given an example
  1802  	// URL: `https://storage.googleapis.com/my-bucket/foo/bar#1234567` this value
  1803  	// would be `foo/bar`.
  1804  	Object string `json:"object,omitempty"`
  1805  	// ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally
  1806  	// include in API requests. By default, fields with empty or default values are
  1807  	// omitted from API requests. See
  1808  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1809  	// details.
  1810  	ForceSendFields []string `json:"-"`
  1811  	// NullFields is a list of field names (e.g. "Bucket") to include in API
  1812  	// requests with the JSON null value. By default, fields with empty values are
  1813  	// omitted from API requests. See
  1814  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1815  	NullFields []string `json:"-"`
  1816  }
  1817  
  1818  func (s *SoftwareRecipeArtifactGcs) MarshalJSON() ([]byte, error) {
  1819  	type NoMethod SoftwareRecipeArtifactGcs
  1820  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1821  }
  1822  
  1823  // SoftwareRecipeArtifactRemote: Specifies an artifact available via some URI.
  1824  type SoftwareRecipeArtifactRemote struct {
  1825  	// Checksum: Must be provided if `allow_insecure` is `false`. SHA256 checksum
  1826  	// in hex format, to compare to the checksum of the artifact. If the checksum
  1827  	// is not empty and it doesn't match the artifact then the recipe installation
  1828  	// fails before running any of the steps.
  1829  	Checksum string `json:"checksum,omitempty"`
  1830  	// Uri: URI from which to fetch the object. It should contain both the protocol
  1831  	// and path following the format {protocol}://{location}.
  1832  	Uri string `json:"uri,omitempty"`
  1833  	// ForceSendFields is a list of field names (e.g. "Checksum") to
  1834  	// unconditionally include in API requests. By default, fields with empty or
  1835  	// default values are omitted from API requests. See
  1836  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1837  	// details.
  1838  	ForceSendFields []string `json:"-"`
  1839  	// NullFields is a list of field names (e.g. "Checksum") to include in API
  1840  	// requests with the JSON null value. By default, fields with empty values are
  1841  	// omitted from API requests. See
  1842  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1843  	NullFields []string `json:"-"`
  1844  }
  1845  
  1846  func (s *SoftwareRecipeArtifactRemote) MarshalJSON() ([]byte, error) {
  1847  	type NoMethod SoftwareRecipeArtifactRemote
  1848  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1849  }
  1850  
  1851  // SoftwareRecipeStep: An action that can be taken as part of installing or
  1852  // updating a recipe.
  1853  type SoftwareRecipeStep struct {
  1854  	// ArchiveExtraction: Extracts an archive into the specified directory.
  1855  	ArchiveExtraction *SoftwareRecipeStepExtractArchive `json:"archiveExtraction,omitempty"`
  1856  	// DpkgInstallation: Installs a deb file via dpkg.
  1857  	DpkgInstallation *SoftwareRecipeStepInstallDpkg `json:"dpkgInstallation,omitempty"`
  1858  	// FileCopy: Copies a file onto the instance.
  1859  	FileCopy *SoftwareRecipeStepCopyFile `json:"fileCopy,omitempty"`
  1860  	// FileExec: Executes an artifact or local file.
  1861  	FileExec *SoftwareRecipeStepExecFile `json:"fileExec,omitempty"`
  1862  	// MsiInstallation: Installs an MSI file.
  1863  	MsiInstallation *SoftwareRecipeStepInstallMsi `json:"msiInstallation,omitempty"`
  1864  	// RpmInstallation: Installs an rpm file via the rpm utility.
  1865  	RpmInstallation *SoftwareRecipeStepInstallRpm `json:"rpmInstallation,omitempty"`
  1866  	// ScriptRun: Runs commands in a shell.
  1867  	ScriptRun *SoftwareRecipeStepRunScript `json:"scriptRun,omitempty"`
  1868  	// ForceSendFields is a list of field names (e.g. "ArchiveExtraction") to
  1869  	// unconditionally include in API requests. By default, fields with empty or
  1870  	// default values are omitted from API requests. See
  1871  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1872  	// details.
  1873  	ForceSendFields []string `json:"-"`
  1874  	// NullFields is a list of field names (e.g. "ArchiveExtraction") to include in
  1875  	// API requests with the JSON null value. By default, fields with empty values
  1876  	// are omitted from API requests. See
  1877  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1878  	NullFields []string `json:"-"`
  1879  }
  1880  
  1881  func (s *SoftwareRecipeStep) MarshalJSON() ([]byte, error) {
  1882  	type NoMethod SoftwareRecipeStep
  1883  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1884  }
  1885  
  1886  // SoftwareRecipeStepCopyFile: Copies the artifact to the specified path on the
  1887  // instance.
  1888  type SoftwareRecipeStepCopyFile struct {
  1889  	// ArtifactId: Required. The id of the relevant artifact in the recipe.
  1890  	ArtifactId string `json:"artifactId,omitempty"`
  1891  	// Destination: Required. The absolute path on the instance to put the file.
  1892  	Destination string `json:"destination,omitempty"`
  1893  	// Overwrite: Whether to allow this step to overwrite existing files. If this
  1894  	// is false and the file already exists the file is not overwritten and the
  1895  	// step is considered a success. Defaults to false.
  1896  	Overwrite bool `json:"overwrite,omitempty"`
  1897  	// Permissions: Consists of three octal digits which represent, in order, the
  1898  	// permissions of the owner, group, and other users for the file (similarly to
  1899  	// the numeric mode used in the linux chmod utility). Each digit represents a
  1900  	// three bit number with the 4 bit corresponding to the read permissions, the 2
  1901  	// bit corresponds to the write bit, and the one bit corresponds to the execute
  1902  	// permission. Default behavior is 755. Below are some examples of permissions
  1903  	// and their associated values: read, write, and execute: 7 read and execute: 5
  1904  	// read and write: 6 read only: 4
  1905  	Permissions string `json:"permissions,omitempty"`
  1906  	// ForceSendFields is a list of field names (e.g. "ArtifactId") to
  1907  	// unconditionally include in API requests. By default, fields with empty or
  1908  	// default values are omitted from API requests. See
  1909  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1910  	// details.
  1911  	ForceSendFields []string `json:"-"`
  1912  	// NullFields is a list of field names (e.g. "ArtifactId") to include in API
  1913  	// requests with the JSON null value. By default, fields with empty values are
  1914  	// omitted from API requests. See
  1915  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1916  	NullFields []string `json:"-"`
  1917  }
  1918  
  1919  func (s *SoftwareRecipeStepCopyFile) MarshalJSON() ([]byte, error) {
  1920  	type NoMethod SoftwareRecipeStepCopyFile
  1921  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1922  }
  1923  
  1924  // SoftwareRecipeStepExecFile: Executes an artifact or local file.
  1925  type SoftwareRecipeStepExecFile struct {
  1926  	// AllowedExitCodes: Defaults to [0]. A list of possible return values that the
  1927  	// program can return to indicate a success.
  1928  	AllowedExitCodes []int64 `json:"allowedExitCodes,omitempty"`
  1929  	// Args: Arguments to be passed to the provided executable.
  1930  	Args []string `json:"args,omitempty"`
  1931  	// ArtifactId: The id of the relevant artifact in the recipe.
  1932  	ArtifactId string `json:"artifactId,omitempty"`
  1933  	// LocalPath: The absolute path of the file on the local filesystem.
  1934  	LocalPath string `json:"localPath,omitempty"`
  1935  	// ForceSendFields is a list of field names (e.g. "AllowedExitCodes") to
  1936  	// unconditionally include in API requests. By default, fields with empty or
  1937  	// default values are omitted from API requests. See
  1938  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1939  	// details.
  1940  	ForceSendFields []string `json:"-"`
  1941  	// NullFields is a list of field names (e.g. "AllowedExitCodes") to include in
  1942  	// API requests with the JSON null value. By default, fields with empty values
  1943  	// are omitted from API requests. See
  1944  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1945  	NullFields []string `json:"-"`
  1946  }
  1947  
  1948  func (s *SoftwareRecipeStepExecFile) MarshalJSON() ([]byte, error) {
  1949  	type NoMethod SoftwareRecipeStepExecFile
  1950  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1951  }
  1952  
  1953  // SoftwareRecipeStepExtractArchive: Extracts an archive of the type specified
  1954  // in the specified directory.
  1955  type SoftwareRecipeStepExtractArchive struct {
  1956  	// ArtifactId: Required. The id of the relevant artifact in the recipe.
  1957  	ArtifactId string `json:"artifactId,omitempty"`
  1958  	// Destination: Directory to extract archive to. Defaults to `/` on Linux or
  1959  	// `C:\` on Windows.
  1960  	Destination string `json:"destination,omitempty"`
  1961  	// Type: Required. The type of the archive to extract.
  1962  	//
  1963  	// Possible values:
  1964  	//   "ARCHIVE_TYPE_UNSPECIFIED" - Indicates that the archive type isn't
  1965  	// specified.
  1966  	//   "TAR" - Indicates that the archive is a tar archive with no encryption.
  1967  	//   "TAR_GZIP" - Indicates that the archive is a tar archive with gzip
  1968  	// encryption.
  1969  	//   "TAR_BZIP" - Indicates that the archive is a tar archive with bzip
  1970  	// encryption.
  1971  	//   "TAR_LZMA" - Indicates that the archive is a tar archive with lzma
  1972  	// encryption.
  1973  	//   "TAR_XZ" - Indicates that the archive is a tar archive with xz encryption.
  1974  	//   "ZIP" - Indicates that the archive is a zip archive.
  1975  	Type string `json:"type,omitempty"`
  1976  	// ForceSendFields is a list of field names (e.g. "ArtifactId") to
  1977  	// unconditionally include in API requests. By default, fields with empty or
  1978  	// default values are omitted from API requests. See
  1979  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1980  	// details.
  1981  	ForceSendFields []string `json:"-"`
  1982  	// NullFields is a list of field names (e.g. "ArtifactId") to include in API
  1983  	// requests with the JSON null value. By default, fields with empty values are
  1984  	// omitted from API requests. See
  1985  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1986  	NullFields []string `json:"-"`
  1987  }
  1988  
  1989  func (s *SoftwareRecipeStepExtractArchive) MarshalJSON() ([]byte, error) {
  1990  	type NoMethod SoftwareRecipeStepExtractArchive
  1991  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1992  }
  1993  
  1994  // SoftwareRecipeStepInstallDpkg: Installs a deb via dpkg.
  1995  type SoftwareRecipeStepInstallDpkg struct {
  1996  	// ArtifactId: Required. The id of the relevant artifact in the recipe.
  1997  	ArtifactId string `json:"artifactId,omitempty"`
  1998  	// ForceSendFields is a list of field names (e.g. "ArtifactId") to
  1999  	// unconditionally include in API requests. By default, fields with empty or
  2000  	// default values are omitted from API requests. See
  2001  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2002  	// details.
  2003  	ForceSendFields []string `json:"-"`
  2004  	// NullFields is a list of field names (e.g. "ArtifactId") to include in API
  2005  	// requests with the JSON null value. By default, fields with empty values are
  2006  	// omitted from API requests. See
  2007  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2008  	NullFields []string `json:"-"`
  2009  }
  2010  
  2011  func (s *SoftwareRecipeStepInstallDpkg) MarshalJSON() ([]byte, error) {
  2012  	type NoMethod SoftwareRecipeStepInstallDpkg
  2013  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2014  }
  2015  
  2016  // SoftwareRecipeStepInstallMsi: Installs an MSI file.
  2017  type SoftwareRecipeStepInstallMsi struct {
  2018  	// AllowedExitCodes: Return codes that indicate that the software installed or
  2019  	// updated successfully. Behaviour defaults to [0]
  2020  	AllowedExitCodes []int64 `json:"allowedExitCodes,omitempty"`
  2021  	// ArtifactId: Required. The id of the relevant artifact in the recipe.
  2022  	ArtifactId string `json:"artifactId,omitempty"`
  2023  	// Flags: The flags to use when installing the MSI defaults to ["/i"] (i.e. the
  2024  	// install flag).
  2025  	Flags []string `json:"flags,omitempty"`
  2026  	// ForceSendFields is a list of field names (e.g. "AllowedExitCodes") to
  2027  	// unconditionally include in API requests. By default, fields with empty or
  2028  	// default values are omitted from API requests. See
  2029  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2030  	// details.
  2031  	ForceSendFields []string `json:"-"`
  2032  	// NullFields is a list of field names (e.g. "AllowedExitCodes") to include in
  2033  	// API requests with the JSON null value. By default, fields with empty values
  2034  	// are omitted from API requests. See
  2035  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2036  	NullFields []string `json:"-"`
  2037  }
  2038  
  2039  func (s *SoftwareRecipeStepInstallMsi) MarshalJSON() ([]byte, error) {
  2040  	type NoMethod SoftwareRecipeStepInstallMsi
  2041  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2042  }
  2043  
  2044  // SoftwareRecipeStepInstallRpm: Installs an rpm file via the rpm utility.
  2045  type SoftwareRecipeStepInstallRpm struct {
  2046  	// ArtifactId: Required. The id of the relevant artifact in the recipe.
  2047  	ArtifactId string `json:"artifactId,omitempty"`
  2048  	// ForceSendFields is a list of field names (e.g. "ArtifactId") to
  2049  	// unconditionally include in API requests. By default, fields with empty or
  2050  	// default values are omitted from API requests. See
  2051  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2052  	// details.
  2053  	ForceSendFields []string `json:"-"`
  2054  	// NullFields is a list of field names (e.g. "ArtifactId") to include in API
  2055  	// requests with the JSON null value. By default, fields with empty values are
  2056  	// omitted from API requests. See
  2057  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2058  	NullFields []string `json:"-"`
  2059  }
  2060  
  2061  func (s *SoftwareRecipeStepInstallRpm) MarshalJSON() ([]byte, error) {
  2062  	type NoMethod SoftwareRecipeStepInstallRpm
  2063  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2064  }
  2065  
  2066  // SoftwareRecipeStepRunScript: Runs a script through an interpreter.
  2067  type SoftwareRecipeStepRunScript struct {
  2068  	// AllowedExitCodes: Return codes that indicate that the software installed or
  2069  	// updated successfully. Behaviour defaults to [0]
  2070  	AllowedExitCodes []int64 `json:"allowedExitCodes,omitempty"`
  2071  	// Interpreter: The script interpreter to use to run the script. If no
  2072  	// interpreter is specified the script is executed directly, which likely only
  2073  	// succeed for scripts with shebang lines
  2074  	// (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
  2075  	//
  2076  	// Possible values:
  2077  	//   "INTERPRETER_UNSPECIFIED" - Default value for ScriptType.
  2078  	//   "SHELL" - Indicates that the script is run with `/bin/sh` on Linux and
  2079  	// `cmd` on windows.
  2080  	//   "POWERSHELL" - Indicates that the script is run with powershell.
  2081  	Interpreter string `json:"interpreter,omitempty"`
  2082  	// Script: Required. The shell script to be executed.
  2083  	Script string `json:"script,omitempty"`
  2084  	// ForceSendFields is a list of field names (e.g. "AllowedExitCodes") to
  2085  	// unconditionally include in API requests. By default, fields with empty or
  2086  	// default values are omitted from API requests. See
  2087  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2088  	// details.
  2089  	ForceSendFields []string `json:"-"`
  2090  	// NullFields is a list of field names (e.g. "AllowedExitCodes") to include in
  2091  	// API requests with the JSON null value. By default, fields with empty values
  2092  	// are omitted from API requests. See
  2093  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2094  	NullFields []string `json:"-"`
  2095  }
  2096  
  2097  func (s *SoftwareRecipeStepRunScript) MarshalJSON() ([]byte, error) {
  2098  	type NoMethod SoftwareRecipeStepRunScript
  2099  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2100  }
  2101  
  2102  // TimeOfDay: Represents a time of day. The date and time zone are either not
  2103  // significant or are specified elsewhere. An API may choose to allow leap
  2104  // seconds. Related types are google.type.Date and `google.protobuf.Timestamp`.
  2105  type TimeOfDay struct {
  2106  	// Hours: Hours of day in 24 hour format. Should be from 0 to 23. An API may
  2107  	// choose to allow the value "24:00:00" for scenarios like business closing
  2108  	// time.
  2109  	Hours int64 `json:"hours,omitempty"`
  2110  	// Minutes: Minutes of hour of day. Must be from 0 to 59.
  2111  	Minutes int64 `json:"minutes,omitempty"`
  2112  	// Nanos: Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.
  2113  	Nanos int64 `json:"nanos,omitempty"`
  2114  	// Seconds: Seconds of minutes of the time. Must normally be from 0 to 59. An
  2115  	// API may allow the value 60 if it allows leap-seconds.
  2116  	Seconds int64 `json:"seconds,omitempty"`
  2117  	// ForceSendFields is a list of field names (e.g. "Hours") to unconditionally
  2118  	// include in API requests. By default, fields with empty or default values are
  2119  	// omitted from API requests. See
  2120  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2121  	// details.
  2122  	ForceSendFields []string `json:"-"`
  2123  	// NullFields is a list of field names (e.g. "Hours") to include in API
  2124  	// requests with the JSON null value. By default, fields with empty values are
  2125  	// omitted from API requests. See
  2126  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2127  	NullFields []string `json:"-"`
  2128  }
  2129  
  2130  func (s *TimeOfDay) MarshalJSON() ([]byte, error) {
  2131  	type NoMethod TimeOfDay
  2132  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2133  }
  2134  
  2135  // TimeZone: Represents a time zone from the IANA Time Zone Database
  2136  // (https://www.iana.org/time-zones).
  2137  type TimeZone struct {
  2138  	// Id: IANA Time Zone Database time zone, e.g. "America/New_York".
  2139  	Id string `json:"id,omitempty"`
  2140  	// Version: Optional. IANA Time Zone Database version number, e.g. "2019a".
  2141  	Version string `json:"version,omitempty"`
  2142  	// ForceSendFields is a list of field names (e.g. "Id") to unconditionally
  2143  	// include in API requests. By default, fields with empty or default values are
  2144  	// omitted from API requests. See
  2145  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2146  	// details.
  2147  	ForceSendFields []string `json:"-"`
  2148  	// NullFields is a list of field names (e.g. "Id") to include in API requests
  2149  	// with the JSON null value. By default, fields with empty values are omitted
  2150  	// from API requests. See
  2151  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2152  	NullFields []string `json:"-"`
  2153  }
  2154  
  2155  func (s *TimeZone) MarshalJSON() ([]byte, error) {
  2156  	type NoMethod TimeZone
  2157  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2158  }
  2159  
  2160  // WeekDayOfMonth: Represents one week day in a month. An example is "the 4th
  2161  // Sunday".
  2162  type WeekDayOfMonth struct {
  2163  	// DayOfWeek: Required. A day of the week.
  2164  	//
  2165  	// Possible values:
  2166  	//   "DAY_OF_WEEK_UNSPECIFIED" - The day of the week is unspecified.
  2167  	//   "MONDAY" - Monday
  2168  	//   "TUESDAY" - Tuesday
  2169  	//   "WEDNESDAY" - Wednesday
  2170  	//   "THURSDAY" - Thursday
  2171  	//   "FRIDAY" - Friday
  2172  	//   "SATURDAY" - Saturday
  2173  	//   "SUNDAY" - Sunday
  2174  	DayOfWeek string `json:"dayOfWeek,omitempty"`
  2175  	// DayOffset: Optional. Represents the number of days before or after the given
  2176  	// week day of month that the patch deployment is scheduled for. For example if
  2177  	// `week_ordinal` and `day_of_week` values point to the second day of the month
  2178  	// and this `day_offset` value is set to `3`, the patch deployment takes place
  2179  	// three days after the second Tuesday of the month. If this value is negative,
  2180  	// for example -5, the patches are deployed five days before before the second
  2181  	// Tuesday of the month. Allowed values are in range [-30, 30].
  2182  	DayOffset int64 `json:"dayOffset,omitempty"`
  2183  	// WeekOrdinal: Required. Week number in a month. 1-4 indicates the 1st to 4th
  2184  	// week of the month. -1 indicates the last week of the month.
  2185  	WeekOrdinal int64 `json:"weekOrdinal,omitempty"`
  2186  	// ForceSendFields is a list of field names (e.g. "DayOfWeek") to
  2187  	// unconditionally include in API requests. By default, fields with empty or
  2188  	// default values are omitted from API requests. See
  2189  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2190  	// details.
  2191  	ForceSendFields []string `json:"-"`
  2192  	// NullFields is a list of field names (e.g. "DayOfWeek") to include in API
  2193  	// requests with the JSON null value. By default, fields with empty values are
  2194  	// omitted from API requests. See
  2195  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2196  	NullFields []string `json:"-"`
  2197  }
  2198  
  2199  func (s *WeekDayOfMonth) MarshalJSON() ([]byte, error) {
  2200  	type NoMethod WeekDayOfMonth
  2201  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2202  }
  2203  
  2204  // WeeklySchedule: Represents a weekly schedule.
  2205  type WeeklySchedule struct {
  2206  	// DayOfWeek: Required. Day of the week.
  2207  	//
  2208  	// Possible values:
  2209  	//   "DAY_OF_WEEK_UNSPECIFIED" - The day of the week is unspecified.
  2210  	//   "MONDAY" - Monday
  2211  	//   "TUESDAY" - Tuesday
  2212  	//   "WEDNESDAY" - Wednesday
  2213  	//   "THURSDAY" - Thursday
  2214  	//   "FRIDAY" - Friday
  2215  	//   "SATURDAY" - Saturday
  2216  	//   "SUNDAY" - Sunday
  2217  	DayOfWeek string `json:"dayOfWeek,omitempty"`
  2218  	// ForceSendFields is a list of field names (e.g. "DayOfWeek") to
  2219  	// unconditionally include in API requests. By default, fields with empty or
  2220  	// default values are omitted from API requests. See
  2221  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2222  	// details.
  2223  	ForceSendFields []string `json:"-"`
  2224  	// NullFields is a list of field names (e.g. "DayOfWeek") to include in API
  2225  	// requests with the JSON null value. By default, fields with empty values are
  2226  	// omitted from API requests. See
  2227  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2228  	NullFields []string `json:"-"`
  2229  }
  2230  
  2231  func (s *WeeklySchedule) MarshalJSON() ([]byte, error) {
  2232  	type NoMethod WeeklySchedule
  2233  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2234  }
  2235  
  2236  // WindowsUpdateSettings: Windows patching is performed using the Windows
  2237  // Update Agent.
  2238  type WindowsUpdateSettings struct {
  2239  	// Classifications: Only apply updates of these windows update classifications.
  2240  	// If empty, all updates are applied.
  2241  	//
  2242  	// Possible values:
  2243  	//   "CLASSIFICATION_UNSPECIFIED" - Invalid. If classifications are included,
  2244  	// they must be specified.
  2245  	//   "CRITICAL" - "A widely released fix for a specific problem that addresses
  2246  	// a critical, non-security-related bug." [1]
  2247  	//   "SECURITY" - "A widely released fix for a product-specific,
  2248  	// security-related vulnerability. Security vulnerabilities are rated by their
  2249  	// severity. The severity rating is indicated in the Microsoft security
  2250  	// bulletin as critical, important, moderate, or low." [1]
  2251  	//   "DEFINITION" - "A widely released and frequent software update that
  2252  	// contains additions to a product's definition database. Definition databases
  2253  	// are often used to detect objects that have specific attributes, such as
  2254  	// malicious code, phishing websites, or junk mail." [1]
  2255  	//   "DRIVER" - "Software that controls the input and output of a device." [1]
  2256  	//   "FEATURE_PACK" - "New product functionality that is first distributed
  2257  	// outside the context of a product release and that is typically included in
  2258  	// the next full product release." [1]
  2259  	//   "SERVICE_PACK" - "A tested, cumulative set of all hotfixes, security
  2260  	// updates, critical updates, and updates. Additionally, service packs may
  2261  	// contain additional fixes for problems that are found internally since the
  2262  	// release of the product. Service packs my also contain a limited number of
  2263  	// customer-requested design changes or features." [1]
  2264  	//   "TOOL" - "A utility or feature that helps complete a task or set of
  2265  	// tasks." [1]
  2266  	//   "UPDATE_ROLLUP" - "A tested, cumulative set of hotfixes, security updates,
  2267  	// critical updates, and updates that are packaged together for easy
  2268  	// deployment. A rollup generally targets a specific area, such as security, or
  2269  	// a component of a product, such as Internet Information Services (IIS)." [1]
  2270  	//   "UPDATE" - "A widely released fix for a specific problem. An update
  2271  	// addresses a noncritical, non-security-related bug." [1]
  2272  	Classifications []string `json:"classifications,omitempty"`
  2273  	// Excludes: List of KBs to exclude from update.
  2274  	Excludes []string `json:"excludes,omitempty"`
  2275  	// ExclusivePatches: An exclusive list of kbs to be updated. These are the only
  2276  	// patches that will be updated. This field must not be used with other patch
  2277  	// configurations.
  2278  	ExclusivePatches []string `json:"exclusivePatches,omitempty"`
  2279  	// ForceSendFields is a list of field names (e.g. "Classifications") to
  2280  	// unconditionally include in API requests. By default, fields with empty or
  2281  	// default values are 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. "Classifications") to include in
  2286  	// API requests with the JSON null value. By default, fields with empty values
  2287  	// are 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 *WindowsUpdateSettings) MarshalJSON() ([]byte, error) {
  2293  	type NoMethod WindowsUpdateSettings
  2294  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2295  }
  2296  
  2297  // YumRepository: Represents a single Yum package repository. This repository
  2298  // is added to a repo file that is stored at
  2299  // `/etc/yum.repos.d/google_osconfig.repo`.
  2300  type YumRepository struct {
  2301  	// BaseUrl: Required. The location of the repository directory.
  2302  	BaseUrl string `json:"baseUrl,omitempty"`
  2303  	// DisplayName: The display name of the repository.
  2304  	DisplayName string `json:"displayName,omitempty"`
  2305  	// GpgKeys: URIs of GPG keys.
  2306  	GpgKeys []string `json:"gpgKeys,omitempty"`
  2307  	// Id: Required. A one word, unique name for this repository. This is the `repo
  2308  	// id` in the Yum config file and also the `display_name` if `display_name` is
  2309  	// omitted. This id is also used as the unique identifier when checking for
  2310  	// guest policy conflicts.
  2311  	Id string `json:"id,omitempty"`
  2312  	// ForceSendFields is a list of field names (e.g. "BaseUrl") to unconditionally
  2313  	// include in API requests. By default, fields with empty or default values are
  2314  	// omitted from API requests. See
  2315  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2316  	// details.
  2317  	ForceSendFields []string `json:"-"`
  2318  	// NullFields is a list of field names (e.g. "BaseUrl") to include in API
  2319  	// requests with the JSON null value. By default, fields with empty values are
  2320  	// omitted from API requests. See
  2321  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2322  	NullFields []string `json:"-"`
  2323  }
  2324  
  2325  func (s *YumRepository) MarshalJSON() ([]byte, error) {
  2326  	type NoMethod YumRepository
  2327  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2328  }
  2329  
  2330  // YumSettings: Yum patching is performed by executing `yum update`. Additional
  2331  // options can be set to control how this is executed. Note that not all
  2332  // settings are supported on all platforms.
  2333  type YumSettings struct {
  2334  	// Excludes: List of packages to exclude from update. These packages are
  2335  	// excluded by using the yum `--exclude` flag.
  2336  	Excludes []string `json:"excludes,omitempty"`
  2337  	// ExclusivePackages: An exclusive list of packages to be updated. These are
  2338  	// the only packages that will be updated. If these packages are not installed,
  2339  	// they will be ignored. This field must not be specified with any other patch
  2340  	// configuration fields.
  2341  	ExclusivePackages []string `json:"exclusivePackages,omitempty"`
  2342  	// Minimal: Will cause patch to run `yum update-minimal` instead.
  2343  	Minimal bool `json:"minimal,omitempty"`
  2344  	// Security: Adds the `--security` flag to `yum update`. Not supported on all
  2345  	// platforms.
  2346  	Security bool `json:"security,omitempty"`
  2347  	// ForceSendFields is a list of field names (e.g. "Excludes") to
  2348  	// unconditionally include in API requests. By default, fields with empty or
  2349  	// default values are omitted from API requests. See
  2350  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2351  	// details.
  2352  	ForceSendFields []string `json:"-"`
  2353  	// NullFields is a list of field names (e.g. "Excludes") to include in API
  2354  	// requests with the JSON null value. By default, fields with empty values are
  2355  	// omitted from API requests. See
  2356  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2357  	NullFields []string `json:"-"`
  2358  }
  2359  
  2360  func (s *YumSettings) MarshalJSON() ([]byte, error) {
  2361  	type NoMethod YumSettings
  2362  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2363  }
  2364  
  2365  // ZypperRepository: Represents a single Zypper package repository. This
  2366  // repository is added to a repo file that is stored at
  2367  // `/etc/zypp/repos.d/google_osconfig.repo`.
  2368  type ZypperRepository struct {
  2369  	// BaseUrl: Required. The location of the repository directory.
  2370  	BaseUrl string `json:"baseUrl,omitempty"`
  2371  	// DisplayName: The display name of the repository.
  2372  	DisplayName string `json:"displayName,omitempty"`
  2373  	// GpgKeys: URIs of GPG keys.
  2374  	GpgKeys []string `json:"gpgKeys,omitempty"`
  2375  	// Id: Required. A one word, unique name for this repository. This is the `repo
  2376  	// id` in the zypper config file and also the `display_name` if `display_name`
  2377  	// is omitted. This id is also used as the unique identifier when checking for
  2378  	// guest policy conflicts.
  2379  	Id string `json:"id,omitempty"`
  2380  	// ForceSendFields is a list of field names (e.g. "BaseUrl") to unconditionally
  2381  	// include in API requests. By default, fields with empty or default values are
  2382  	// omitted from API requests. See
  2383  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2384  	// details.
  2385  	ForceSendFields []string `json:"-"`
  2386  	// NullFields is a list of field names (e.g. "BaseUrl") to include in API
  2387  	// requests with the JSON null value. By default, fields with empty values are
  2388  	// omitted from API requests. See
  2389  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2390  	NullFields []string `json:"-"`
  2391  }
  2392  
  2393  func (s *ZypperRepository) MarshalJSON() ([]byte, error) {
  2394  	type NoMethod ZypperRepository
  2395  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2396  }
  2397  
  2398  // ZypperSettings: Zypper patching is performed by running `zypper patch`. See
  2399  // also https://en.opensuse.org/SDB:Zypper_manual.
  2400  type ZypperSettings struct {
  2401  	// Categories: Install only patches with these categories. Common categories
  2402  	// include security, recommended, and feature.
  2403  	Categories []string `json:"categories,omitempty"`
  2404  	// Excludes: List of patches to exclude from update.
  2405  	Excludes []string `json:"excludes,omitempty"`
  2406  	// ExclusivePatches: An exclusive list of patches to be updated. These are the
  2407  	// only patches that will be installed using 'zypper patch patch:' command.
  2408  	// This field must not be used with any other patch configuration fields.
  2409  	ExclusivePatches []string `json:"exclusivePatches,omitempty"`
  2410  	// Severities: Install only patches with these severities. Common severities
  2411  	// include critical, important, moderate, and low.
  2412  	Severities []string `json:"severities,omitempty"`
  2413  	// WithOptional: Adds the `--with-optional` flag to `zypper patch`.
  2414  	WithOptional bool `json:"withOptional,omitempty"`
  2415  	// WithUpdate: Adds the `--with-update` flag, to `zypper patch`.
  2416  	WithUpdate bool `json:"withUpdate,omitempty"`
  2417  	// ForceSendFields is a list of field names (e.g. "Categories") to
  2418  	// unconditionally include in API requests. By default, fields with empty or
  2419  	// default values are omitted from API requests. See
  2420  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  2421  	// details.
  2422  	ForceSendFields []string `json:"-"`
  2423  	// NullFields is a list of field names (e.g. "Categories") to include in API
  2424  	// requests with the JSON null value. By default, fields with empty values are
  2425  	// omitted from API requests. See
  2426  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  2427  	NullFields []string `json:"-"`
  2428  }
  2429  
  2430  func (s *ZypperSettings) MarshalJSON() ([]byte, error) {
  2431  	type NoMethod ZypperSettings
  2432  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  2433  }
  2434  
  2435  type ProjectsGuestPoliciesCreateCall struct {
  2436  	s           *Service
  2437  	parent      string
  2438  	guestpolicy *GuestPolicy
  2439  	urlParams_  gensupport.URLParams
  2440  	ctx_        context.Context
  2441  	header_     http.Header
  2442  }
  2443  
  2444  // Create: Create an OS Config guest policy.
  2445  //
  2446  //   - parent: The resource name of the parent using one of the following forms:
  2447  //     `projects/{project_number}`.
  2448  func (r *ProjectsGuestPoliciesService) Create(parent string, guestpolicy *GuestPolicy) *ProjectsGuestPoliciesCreateCall {
  2449  	c := &ProjectsGuestPoliciesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2450  	c.parent = parent
  2451  	c.guestpolicy = guestpolicy
  2452  	return c
  2453  }
  2454  
  2455  // GuestPolicyId sets the optional parameter "guestPolicyId": Required. The
  2456  // logical name of the guest policy in the project with the following
  2457  // restrictions: * Must contain only lowercase letters, numbers, and hyphens. *
  2458  // Must start with a letter. * Must be between 1-63 characters. * Must end with
  2459  // a number or a letter. * Must be unique within the project.
  2460  func (c *ProjectsGuestPoliciesCreateCall) GuestPolicyId(guestPolicyId string) *ProjectsGuestPoliciesCreateCall {
  2461  	c.urlParams_.Set("guestPolicyId", guestPolicyId)
  2462  	return c
  2463  }
  2464  
  2465  // Fields allows partial responses to be retrieved. See
  2466  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2467  // details.
  2468  func (c *ProjectsGuestPoliciesCreateCall) Fields(s ...googleapi.Field) *ProjectsGuestPoliciesCreateCall {
  2469  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2470  	return c
  2471  }
  2472  
  2473  // Context sets the context to be used in this call's Do method.
  2474  func (c *ProjectsGuestPoliciesCreateCall) Context(ctx context.Context) *ProjectsGuestPoliciesCreateCall {
  2475  	c.ctx_ = ctx
  2476  	return c
  2477  }
  2478  
  2479  // Header returns a http.Header that can be modified by the caller to add
  2480  // headers to the request.
  2481  func (c *ProjectsGuestPoliciesCreateCall) Header() http.Header {
  2482  	if c.header_ == nil {
  2483  		c.header_ = make(http.Header)
  2484  	}
  2485  	return c.header_
  2486  }
  2487  
  2488  func (c *ProjectsGuestPoliciesCreateCall) doRequest(alt string) (*http.Response, error) {
  2489  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2490  	var body io.Reader = nil
  2491  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.guestpolicy)
  2492  	if err != nil {
  2493  		return nil, err
  2494  	}
  2495  	c.urlParams_.Set("alt", alt)
  2496  	c.urlParams_.Set("prettyPrint", "false")
  2497  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/guestPolicies")
  2498  	urls += "?" + c.urlParams_.Encode()
  2499  	req, err := http.NewRequest("POST", urls, body)
  2500  	if err != nil {
  2501  		return nil, err
  2502  	}
  2503  	req.Header = reqHeaders
  2504  	googleapi.Expand(req.URL, map[string]string{
  2505  		"parent": c.parent,
  2506  	})
  2507  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2508  }
  2509  
  2510  // Do executes the "osconfig.projects.guestPolicies.create" call.
  2511  // Any non-2xx status code is an error. Response headers are in either
  2512  // *GuestPolicy.ServerResponse.Header or (if a response was returned at all) in
  2513  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2514  // whether the returned error was because http.StatusNotModified was returned.
  2515  func (c *ProjectsGuestPoliciesCreateCall) Do(opts ...googleapi.CallOption) (*GuestPolicy, error) {
  2516  	gensupport.SetOptions(c.urlParams_, opts...)
  2517  	res, err := c.doRequest("json")
  2518  	if res != nil && res.StatusCode == http.StatusNotModified {
  2519  		if res.Body != nil {
  2520  			res.Body.Close()
  2521  		}
  2522  		return nil, gensupport.WrapError(&googleapi.Error{
  2523  			Code:   res.StatusCode,
  2524  			Header: res.Header,
  2525  		})
  2526  	}
  2527  	if err != nil {
  2528  		return nil, err
  2529  	}
  2530  	defer googleapi.CloseBody(res)
  2531  	if err := googleapi.CheckResponse(res); err != nil {
  2532  		return nil, gensupport.WrapError(err)
  2533  	}
  2534  	ret := &GuestPolicy{
  2535  		ServerResponse: googleapi.ServerResponse{
  2536  			Header:         res.Header,
  2537  			HTTPStatusCode: res.StatusCode,
  2538  		},
  2539  	}
  2540  	target := &ret
  2541  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2542  		return nil, err
  2543  	}
  2544  	return ret, nil
  2545  }
  2546  
  2547  type ProjectsGuestPoliciesDeleteCall struct {
  2548  	s          *Service
  2549  	name       string
  2550  	urlParams_ gensupport.URLParams
  2551  	ctx_       context.Context
  2552  	header_    http.Header
  2553  }
  2554  
  2555  // Delete: Delete an OS Config guest policy.
  2556  //
  2557  //   - name: The resource name of the guest policy using one of the following
  2558  //     forms: `projects/{project_number}/guestPolicies/{guest_policy_id}`.
  2559  func (r *ProjectsGuestPoliciesService) Delete(name string) *ProjectsGuestPoliciesDeleteCall {
  2560  	c := &ProjectsGuestPoliciesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2561  	c.name = name
  2562  	return c
  2563  }
  2564  
  2565  // Fields allows partial responses to be retrieved. See
  2566  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2567  // details.
  2568  func (c *ProjectsGuestPoliciesDeleteCall) Fields(s ...googleapi.Field) *ProjectsGuestPoliciesDeleteCall {
  2569  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2570  	return c
  2571  }
  2572  
  2573  // Context sets the context to be used in this call's Do method.
  2574  func (c *ProjectsGuestPoliciesDeleteCall) Context(ctx context.Context) *ProjectsGuestPoliciesDeleteCall {
  2575  	c.ctx_ = ctx
  2576  	return c
  2577  }
  2578  
  2579  // Header returns a http.Header that can be modified by the caller to add
  2580  // headers to the request.
  2581  func (c *ProjectsGuestPoliciesDeleteCall) Header() http.Header {
  2582  	if c.header_ == nil {
  2583  		c.header_ = make(http.Header)
  2584  	}
  2585  	return c.header_
  2586  }
  2587  
  2588  func (c *ProjectsGuestPoliciesDeleteCall) doRequest(alt string) (*http.Response, error) {
  2589  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2590  	var body io.Reader = nil
  2591  	c.urlParams_.Set("alt", alt)
  2592  	c.urlParams_.Set("prettyPrint", "false")
  2593  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2594  	urls += "?" + c.urlParams_.Encode()
  2595  	req, err := http.NewRequest("DELETE", urls, body)
  2596  	if err != nil {
  2597  		return nil, err
  2598  	}
  2599  	req.Header = reqHeaders
  2600  	googleapi.Expand(req.URL, map[string]string{
  2601  		"name": c.name,
  2602  	})
  2603  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2604  }
  2605  
  2606  // Do executes the "osconfig.projects.guestPolicies.delete" call.
  2607  // Any non-2xx status code is an error. Response headers are in either
  2608  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  2609  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2610  // whether the returned error was because http.StatusNotModified was returned.
  2611  func (c *ProjectsGuestPoliciesDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  2612  	gensupport.SetOptions(c.urlParams_, opts...)
  2613  	res, err := c.doRequest("json")
  2614  	if res != nil && res.StatusCode == http.StatusNotModified {
  2615  		if res.Body != nil {
  2616  			res.Body.Close()
  2617  		}
  2618  		return nil, gensupport.WrapError(&googleapi.Error{
  2619  			Code:   res.StatusCode,
  2620  			Header: res.Header,
  2621  		})
  2622  	}
  2623  	if err != nil {
  2624  		return nil, err
  2625  	}
  2626  	defer googleapi.CloseBody(res)
  2627  	if err := googleapi.CheckResponse(res); err != nil {
  2628  		return nil, gensupport.WrapError(err)
  2629  	}
  2630  	ret := &Empty{
  2631  		ServerResponse: googleapi.ServerResponse{
  2632  			Header:         res.Header,
  2633  			HTTPStatusCode: res.StatusCode,
  2634  		},
  2635  	}
  2636  	target := &ret
  2637  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2638  		return nil, err
  2639  	}
  2640  	return ret, nil
  2641  }
  2642  
  2643  type ProjectsGuestPoliciesGetCall struct {
  2644  	s            *Service
  2645  	name         string
  2646  	urlParams_   gensupport.URLParams
  2647  	ifNoneMatch_ string
  2648  	ctx_         context.Context
  2649  	header_      http.Header
  2650  }
  2651  
  2652  // Get: Get an OS Config guest policy.
  2653  //
  2654  //   - name: The resource name of the guest policy using one of the following
  2655  //     forms: `projects/{project_number}/guestPolicies/{guest_policy_id}`.
  2656  func (r *ProjectsGuestPoliciesService) Get(name string) *ProjectsGuestPoliciesGetCall {
  2657  	c := &ProjectsGuestPoliciesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2658  	c.name = name
  2659  	return c
  2660  }
  2661  
  2662  // Fields allows partial responses to be retrieved. See
  2663  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2664  // details.
  2665  func (c *ProjectsGuestPoliciesGetCall) Fields(s ...googleapi.Field) *ProjectsGuestPoliciesGetCall {
  2666  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2667  	return c
  2668  }
  2669  
  2670  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2671  // object's ETag matches the given value. This is useful for getting updates
  2672  // only after the object has changed since the last request.
  2673  func (c *ProjectsGuestPoliciesGetCall) IfNoneMatch(entityTag string) *ProjectsGuestPoliciesGetCall {
  2674  	c.ifNoneMatch_ = entityTag
  2675  	return c
  2676  }
  2677  
  2678  // Context sets the context to be used in this call's Do method.
  2679  func (c *ProjectsGuestPoliciesGetCall) Context(ctx context.Context) *ProjectsGuestPoliciesGetCall {
  2680  	c.ctx_ = ctx
  2681  	return c
  2682  }
  2683  
  2684  // Header returns a http.Header that can be modified by the caller to add
  2685  // headers to the request.
  2686  func (c *ProjectsGuestPoliciesGetCall) Header() http.Header {
  2687  	if c.header_ == nil {
  2688  		c.header_ = make(http.Header)
  2689  	}
  2690  	return c.header_
  2691  }
  2692  
  2693  func (c *ProjectsGuestPoliciesGetCall) doRequest(alt string) (*http.Response, error) {
  2694  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2695  	if c.ifNoneMatch_ != "" {
  2696  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2697  	}
  2698  	var body io.Reader = nil
  2699  	c.urlParams_.Set("alt", alt)
  2700  	c.urlParams_.Set("prettyPrint", "false")
  2701  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2702  	urls += "?" + c.urlParams_.Encode()
  2703  	req, err := http.NewRequest("GET", urls, body)
  2704  	if err != nil {
  2705  		return nil, err
  2706  	}
  2707  	req.Header = reqHeaders
  2708  	googleapi.Expand(req.URL, map[string]string{
  2709  		"name": c.name,
  2710  	})
  2711  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2712  }
  2713  
  2714  // Do executes the "osconfig.projects.guestPolicies.get" call.
  2715  // Any non-2xx status code is an error. Response headers are in either
  2716  // *GuestPolicy.ServerResponse.Header or (if a response was returned at all) in
  2717  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2718  // whether the returned error was because http.StatusNotModified was returned.
  2719  func (c *ProjectsGuestPoliciesGetCall) Do(opts ...googleapi.CallOption) (*GuestPolicy, error) {
  2720  	gensupport.SetOptions(c.urlParams_, opts...)
  2721  	res, err := c.doRequest("json")
  2722  	if res != nil && res.StatusCode == http.StatusNotModified {
  2723  		if res.Body != nil {
  2724  			res.Body.Close()
  2725  		}
  2726  		return nil, gensupport.WrapError(&googleapi.Error{
  2727  			Code:   res.StatusCode,
  2728  			Header: res.Header,
  2729  		})
  2730  	}
  2731  	if err != nil {
  2732  		return nil, err
  2733  	}
  2734  	defer googleapi.CloseBody(res)
  2735  	if err := googleapi.CheckResponse(res); err != nil {
  2736  		return nil, gensupport.WrapError(err)
  2737  	}
  2738  	ret := &GuestPolicy{
  2739  		ServerResponse: googleapi.ServerResponse{
  2740  			Header:         res.Header,
  2741  			HTTPStatusCode: res.StatusCode,
  2742  		},
  2743  	}
  2744  	target := &ret
  2745  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2746  		return nil, err
  2747  	}
  2748  	return ret, nil
  2749  }
  2750  
  2751  type ProjectsGuestPoliciesListCall struct {
  2752  	s            *Service
  2753  	parent       string
  2754  	urlParams_   gensupport.URLParams
  2755  	ifNoneMatch_ string
  2756  	ctx_         context.Context
  2757  	header_      http.Header
  2758  }
  2759  
  2760  // List: Get a page of OS Config guest policies.
  2761  //
  2762  //   - parent: The resource name of the parent using one of the following forms:
  2763  //     `projects/{project_number}`.
  2764  func (r *ProjectsGuestPoliciesService) List(parent string) *ProjectsGuestPoliciesListCall {
  2765  	c := &ProjectsGuestPoliciesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2766  	c.parent = parent
  2767  	return c
  2768  }
  2769  
  2770  // PageSize sets the optional parameter "pageSize": The maximum number of guest
  2771  // policies to return.
  2772  func (c *ProjectsGuestPoliciesListCall) PageSize(pageSize int64) *ProjectsGuestPoliciesListCall {
  2773  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  2774  	return c
  2775  }
  2776  
  2777  // PageToken sets the optional parameter "pageToken": A pagination token
  2778  // returned from a previous call to `ListGuestPolicies` that indicates where
  2779  // this listing should continue from.
  2780  func (c *ProjectsGuestPoliciesListCall) PageToken(pageToken string) *ProjectsGuestPoliciesListCall {
  2781  	c.urlParams_.Set("pageToken", pageToken)
  2782  	return c
  2783  }
  2784  
  2785  // Fields allows partial responses to be retrieved. See
  2786  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2787  // details.
  2788  func (c *ProjectsGuestPoliciesListCall) Fields(s ...googleapi.Field) *ProjectsGuestPoliciesListCall {
  2789  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2790  	return c
  2791  }
  2792  
  2793  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2794  // object's ETag matches the given value. This is useful for getting updates
  2795  // only after the object has changed since the last request.
  2796  func (c *ProjectsGuestPoliciesListCall) IfNoneMatch(entityTag string) *ProjectsGuestPoliciesListCall {
  2797  	c.ifNoneMatch_ = entityTag
  2798  	return c
  2799  }
  2800  
  2801  // Context sets the context to be used in this call's Do method.
  2802  func (c *ProjectsGuestPoliciesListCall) Context(ctx context.Context) *ProjectsGuestPoliciesListCall {
  2803  	c.ctx_ = ctx
  2804  	return c
  2805  }
  2806  
  2807  // Header returns a http.Header that can be modified by the caller to add
  2808  // headers to the request.
  2809  func (c *ProjectsGuestPoliciesListCall) Header() http.Header {
  2810  	if c.header_ == nil {
  2811  		c.header_ = make(http.Header)
  2812  	}
  2813  	return c.header_
  2814  }
  2815  
  2816  func (c *ProjectsGuestPoliciesListCall) doRequest(alt string) (*http.Response, error) {
  2817  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2818  	if c.ifNoneMatch_ != "" {
  2819  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2820  	}
  2821  	var body io.Reader = nil
  2822  	c.urlParams_.Set("alt", alt)
  2823  	c.urlParams_.Set("prettyPrint", "false")
  2824  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/guestPolicies")
  2825  	urls += "?" + c.urlParams_.Encode()
  2826  	req, err := http.NewRequest("GET", urls, body)
  2827  	if err != nil {
  2828  		return nil, err
  2829  	}
  2830  	req.Header = reqHeaders
  2831  	googleapi.Expand(req.URL, map[string]string{
  2832  		"parent": c.parent,
  2833  	})
  2834  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2835  }
  2836  
  2837  // Do executes the "osconfig.projects.guestPolicies.list" call.
  2838  // Any non-2xx status code is an error. Response headers are in either
  2839  // *ListGuestPoliciesResponse.ServerResponse.Header or (if a response was
  2840  // returned at all) in error.(*googleapi.Error).Header. Use
  2841  // googleapi.IsNotModified to check whether the returned error was because
  2842  // http.StatusNotModified was returned.
  2843  func (c *ProjectsGuestPoliciesListCall) Do(opts ...googleapi.CallOption) (*ListGuestPoliciesResponse, error) {
  2844  	gensupport.SetOptions(c.urlParams_, opts...)
  2845  	res, err := c.doRequest("json")
  2846  	if res != nil && res.StatusCode == http.StatusNotModified {
  2847  		if res.Body != nil {
  2848  			res.Body.Close()
  2849  		}
  2850  		return nil, gensupport.WrapError(&googleapi.Error{
  2851  			Code:   res.StatusCode,
  2852  			Header: res.Header,
  2853  		})
  2854  	}
  2855  	if err != nil {
  2856  		return nil, err
  2857  	}
  2858  	defer googleapi.CloseBody(res)
  2859  	if err := googleapi.CheckResponse(res); err != nil {
  2860  		return nil, gensupport.WrapError(err)
  2861  	}
  2862  	ret := &ListGuestPoliciesResponse{
  2863  		ServerResponse: googleapi.ServerResponse{
  2864  			Header:         res.Header,
  2865  			HTTPStatusCode: res.StatusCode,
  2866  		},
  2867  	}
  2868  	target := &ret
  2869  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2870  		return nil, err
  2871  	}
  2872  	return ret, nil
  2873  }
  2874  
  2875  // Pages invokes f for each page of results.
  2876  // A non-nil error returned from f will halt the iteration.
  2877  // The provided context supersedes any context provided to the Context method.
  2878  func (c *ProjectsGuestPoliciesListCall) Pages(ctx context.Context, f func(*ListGuestPoliciesResponse) error) error {
  2879  	c.ctx_ = ctx
  2880  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  2881  	for {
  2882  		x, err := c.Do()
  2883  		if err != nil {
  2884  			return err
  2885  		}
  2886  		if err := f(x); err != nil {
  2887  			return err
  2888  		}
  2889  		if x.NextPageToken == "" {
  2890  			return nil
  2891  		}
  2892  		c.PageToken(x.NextPageToken)
  2893  	}
  2894  }
  2895  
  2896  type ProjectsGuestPoliciesPatchCall struct {
  2897  	s           *Service
  2898  	name        string
  2899  	guestpolicy *GuestPolicy
  2900  	urlParams_  gensupport.URLParams
  2901  	ctx_        context.Context
  2902  	header_     http.Header
  2903  }
  2904  
  2905  // Patch: Update an OS Config guest policy.
  2906  //
  2907  //   - name: Unique name of the resource in this project using one of the
  2908  //     following forms:
  2909  //     `projects/{project_number}/guestPolicies/{guest_policy_id}`.
  2910  func (r *ProjectsGuestPoliciesService) Patch(name string, guestpolicy *GuestPolicy) *ProjectsGuestPoliciesPatchCall {
  2911  	c := &ProjectsGuestPoliciesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2912  	c.name = name
  2913  	c.guestpolicy = guestpolicy
  2914  	return c
  2915  }
  2916  
  2917  // UpdateMask sets the optional parameter "updateMask": Field mask that
  2918  // controls which fields of the guest policy should be updated.
  2919  func (c *ProjectsGuestPoliciesPatchCall) UpdateMask(updateMask string) *ProjectsGuestPoliciesPatchCall {
  2920  	c.urlParams_.Set("updateMask", updateMask)
  2921  	return c
  2922  }
  2923  
  2924  // Fields allows partial responses to be retrieved. See
  2925  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2926  // details.
  2927  func (c *ProjectsGuestPoliciesPatchCall) Fields(s ...googleapi.Field) *ProjectsGuestPoliciesPatchCall {
  2928  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2929  	return c
  2930  }
  2931  
  2932  // Context sets the context to be used in this call's Do method.
  2933  func (c *ProjectsGuestPoliciesPatchCall) Context(ctx context.Context) *ProjectsGuestPoliciesPatchCall {
  2934  	c.ctx_ = ctx
  2935  	return c
  2936  }
  2937  
  2938  // Header returns a http.Header that can be modified by the caller to add
  2939  // headers to the request.
  2940  func (c *ProjectsGuestPoliciesPatchCall) Header() http.Header {
  2941  	if c.header_ == nil {
  2942  		c.header_ = make(http.Header)
  2943  	}
  2944  	return c.header_
  2945  }
  2946  
  2947  func (c *ProjectsGuestPoliciesPatchCall) doRequest(alt string) (*http.Response, error) {
  2948  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2949  	var body io.Reader = nil
  2950  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.guestpolicy)
  2951  	if err != nil {
  2952  		return nil, err
  2953  	}
  2954  	c.urlParams_.Set("alt", alt)
  2955  	c.urlParams_.Set("prettyPrint", "false")
  2956  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2957  	urls += "?" + c.urlParams_.Encode()
  2958  	req, err := http.NewRequest("PATCH", urls, body)
  2959  	if err != nil {
  2960  		return nil, err
  2961  	}
  2962  	req.Header = reqHeaders
  2963  	googleapi.Expand(req.URL, map[string]string{
  2964  		"name": c.name,
  2965  	})
  2966  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2967  }
  2968  
  2969  // Do executes the "osconfig.projects.guestPolicies.patch" call.
  2970  // Any non-2xx status code is an error. Response headers are in either
  2971  // *GuestPolicy.ServerResponse.Header or (if a response was returned at all) in
  2972  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2973  // whether the returned error was because http.StatusNotModified was returned.
  2974  func (c *ProjectsGuestPoliciesPatchCall) Do(opts ...googleapi.CallOption) (*GuestPolicy, error) {
  2975  	gensupport.SetOptions(c.urlParams_, opts...)
  2976  	res, err := c.doRequest("json")
  2977  	if res != nil && res.StatusCode == http.StatusNotModified {
  2978  		if res.Body != nil {
  2979  			res.Body.Close()
  2980  		}
  2981  		return nil, gensupport.WrapError(&googleapi.Error{
  2982  			Code:   res.StatusCode,
  2983  			Header: res.Header,
  2984  		})
  2985  	}
  2986  	if err != nil {
  2987  		return nil, err
  2988  	}
  2989  	defer googleapi.CloseBody(res)
  2990  	if err := googleapi.CheckResponse(res); err != nil {
  2991  		return nil, gensupport.WrapError(err)
  2992  	}
  2993  	ret := &GuestPolicy{
  2994  		ServerResponse: googleapi.ServerResponse{
  2995  			Header:         res.Header,
  2996  			HTTPStatusCode: res.StatusCode,
  2997  		},
  2998  	}
  2999  	target := &ret
  3000  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3001  		return nil, err
  3002  	}
  3003  	return ret, nil
  3004  }
  3005  
  3006  type ProjectsPatchDeploymentsCreateCall struct {
  3007  	s               *Service
  3008  	parent          string
  3009  	patchdeployment *PatchDeployment
  3010  	urlParams_      gensupport.URLParams
  3011  	ctx_            context.Context
  3012  	header_         http.Header
  3013  }
  3014  
  3015  // Create: Create an OS Config patch deployment.
  3016  //
  3017  //   - parent: The project to apply this patch deployment to in the form
  3018  //     `projects/*`.
  3019  func (r *ProjectsPatchDeploymentsService) Create(parent string, patchdeployment *PatchDeployment) *ProjectsPatchDeploymentsCreateCall {
  3020  	c := &ProjectsPatchDeploymentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3021  	c.parent = parent
  3022  	c.patchdeployment = patchdeployment
  3023  	return c
  3024  }
  3025  
  3026  // PatchDeploymentId sets the optional parameter "patchDeploymentId": Required.
  3027  // A name for the patch deployment in the project. When creating a name the
  3028  // following rules apply: * Must contain only lowercase letters, numbers, and
  3029  // hyphens. * Must start with a letter. * Must be between 1-63 characters. *
  3030  // Must end with a number or a letter. * Must be unique within the project.
  3031  func (c *ProjectsPatchDeploymentsCreateCall) PatchDeploymentId(patchDeploymentId string) *ProjectsPatchDeploymentsCreateCall {
  3032  	c.urlParams_.Set("patchDeploymentId", patchDeploymentId)
  3033  	return c
  3034  }
  3035  
  3036  // Fields allows partial responses to be retrieved. See
  3037  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3038  // details.
  3039  func (c *ProjectsPatchDeploymentsCreateCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsCreateCall {
  3040  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3041  	return c
  3042  }
  3043  
  3044  // Context sets the context to be used in this call's Do method.
  3045  func (c *ProjectsPatchDeploymentsCreateCall) Context(ctx context.Context) *ProjectsPatchDeploymentsCreateCall {
  3046  	c.ctx_ = ctx
  3047  	return c
  3048  }
  3049  
  3050  // Header returns a http.Header that can be modified by the caller to add
  3051  // headers to the request.
  3052  func (c *ProjectsPatchDeploymentsCreateCall) Header() http.Header {
  3053  	if c.header_ == nil {
  3054  		c.header_ = make(http.Header)
  3055  	}
  3056  	return c.header_
  3057  }
  3058  
  3059  func (c *ProjectsPatchDeploymentsCreateCall) doRequest(alt string) (*http.Response, error) {
  3060  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3061  	var body io.Reader = nil
  3062  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.patchdeployment)
  3063  	if err != nil {
  3064  		return nil, err
  3065  	}
  3066  	c.urlParams_.Set("alt", alt)
  3067  	c.urlParams_.Set("prettyPrint", "false")
  3068  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/patchDeployments")
  3069  	urls += "?" + c.urlParams_.Encode()
  3070  	req, err := http.NewRequest("POST", urls, body)
  3071  	if err != nil {
  3072  		return nil, err
  3073  	}
  3074  	req.Header = reqHeaders
  3075  	googleapi.Expand(req.URL, map[string]string{
  3076  		"parent": c.parent,
  3077  	})
  3078  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3079  }
  3080  
  3081  // Do executes the "osconfig.projects.patchDeployments.create" call.
  3082  // Any non-2xx status code is an error. Response headers are in either
  3083  // *PatchDeployment.ServerResponse.Header or (if a response was returned at
  3084  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3085  // check whether the returned error was because http.StatusNotModified was
  3086  // returned.
  3087  func (c *ProjectsPatchDeploymentsCreateCall) Do(opts ...googleapi.CallOption) (*PatchDeployment, error) {
  3088  	gensupport.SetOptions(c.urlParams_, opts...)
  3089  	res, err := c.doRequest("json")
  3090  	if res != nil && res.StatusCode == http.StatusNotModified {
  3091  		if res.Body != nil {
  3092  			res.Body.Close()
  3093  		}
  3094  		return nil, gensupport.WrapError(&googleapi.Error{
  3095  			Code:   res.StatusCode,
  3096  			Header: res.Header,
  3097  		})
  3098  	}
  3099  	if err != nil {
  3100  		return nil, err
  3101  	}
  3102  	defer googleapi.CloseBody(res)
  3103  	if err := googleapi.CheckResponse(res); err != nil {
  3104  		return nil, gensupport.WrapError(err)
  3105  	}
  3106  	ret := &PatchDeployment{
  3107  		ServerResponse: googleapi.ServerResponse{
  3108  			Header:         res.Header,
  3109  			HTTPStatusCode: res.StatusCode,
  3110  		},
  3111  	}
  3112  	target := &ret
  3113  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3114  		return nil, err
  3115  	}
  3116  	return ret, nil
  3117  }
  3118  
  3119  type ProjectsPatchDeploymentsDeleteCall struct {
  3120  	s          *Service
  3121  	name       string
  3122  	urlParams_ gensupport.URLParams
  3123  	ctx_       context.Context
  3124  	header_    http.Header
  3125  }
  3126  
  3127  // Delete: Delete an OS Config patch deployment.
  3128  //
  3129  //   - name: The resource name of the patch deployment in the form
  3130  //     `projects/*/patchDeployments/*`.
  3131  func (r *ProjectsPatchDeploymentsService) Delete(name string) *ProjectsPatchDeploymentsDeleteCall {
  3132  	c := &ProjectsPatchDeploymentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3133  	c.name = name
  3134  	return c
  3135  }
  3136  
  3137  // Fields allows partial responses to be retrieved. See
  3138  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3139  // details.
  3140  func (c *ProjectsPatchDeploymentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsDeleteCall {
  3141  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3142  	return c
  3143  }
  3144  
  3145  // Context sets the context to be used in this call's Do method.
  3146  func (c *ProjectsPatchDeploymentsDeleteCall) Context(ctx context.Context) *ProjectsPatchDeploymentsDeleteCall {
  3147  	c.ctx_ = ctx
  3148  	return c
  3149  }
  3150  
  3151  // Header returns a http.Header that can be modified by the caller to add
  3152  // headers to the request.
  3153  func (c *ProjectsPatchDeploymentsDeleteCall) Header() http.Header {
  3154  	if c.header_ == nil {
  3155  		c.header_ = make(http.Header)
  3156  	}
  3157  	return c.header_
  3158  }
  3159  
  3160  func (c *ProjectsPatchDeploymentsDeleteCall) doRequest(alt string) (*http.Response, error) {
  3161  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3162  	var body io.Reader = nil
  3163  	c.urlParams_.Set("alt", alt)
  3164  	c.urlParams_.Set("prettyPrint", "false")
  3165  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  3166  	urls += "?" + c.urlParams_.Encode()
  3167  	req, err := http.NewRequest("DELETE", urls, body)
  3168  	if err != nil {
  3169  		return nil, err
  3170  	}
  3171  	req.Header = reqHeaders
  3172  	googleapi.Expand(req.URL, map[string]string{
  3173  		"name": c.name,
  3174  	})
  3175  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3176  }
  3177  
  3178  // Do executes the "osconfig.projects.patchDeployments.delete" call.
  3179  // Any non-2xx status code is an error. Response headers are in either
  3180  // *Empty.ServerResponse.Header or (if a response was returned at all) in
  3181  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3182  // whether the returned error was because http.StatusNotModified was returned.
  3183  func (c *ProjectsPatchDeploymentsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  3184  	gensupport.SetOptions(c.urlParams_, opts...)
  3185  	res, err := c.doRequest("json")
  3186  	if res != nil && res.StatusCode == http.StatusNotModified {
  3187  		if res.Body != nil {
  3188  			res.Body.Close()
  3189  		}
  3190  		return nil, gensupport.WrapError(&googleapi.Error{
  3191  			Code:   res.StatusCode,
  3192  			Header: res.Header,
  3193  		})
  3194  	}
  3195  	if err != nil {
  3196  		return nil, err
  3197  	}
  3198  	defer googleapi.CloseBody(res)
  3199  	if err := googleapi.CheckResponse(res); err != nil {
  3200  		return nil, gensupport.WrapError(err)
  3201  	}
  3202  	ret := &Empty{
  3203  		ServerResponse: googleapi.ServerResponse{
  3204  			Header:         res.Header,
  3205  			HTTPStatusCode: res.StatusCode,
  3206  		},
  3207  	}
  3208  	target := &ret
  3209  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3210  		return nil, err
  3211  	}
  3212  	return ret, nil
  3213  }
  3214  
  3215  type ProjectsPatchDeploymentsGetCall struct {
  3216  	s            *Service
  3217  	name         string
  3218  	urlParams_   gensupport.URLParams
  3219  	ifNoneMatch_ string
  3220  	ctx_         context.Context
  3221  	header_      http.Header
  3222  }
  3223  
  3224  // Get: Get an OS Config patch deployment.
  3225  //
  3226  //   - name: The resource name of the patch deployment in the form
  3227  //     `projects/*/patchDeployments/*`.
  3228  func (r *ProjectsPatchDeploymentsService) Get(name string) *ProjectsPatchDeploymentsGetCall {
  3229  	c := &ProjectsPatchDeploymentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3230  	c.name = name
  3231  	return c
  3232  }
  3233  
  3234  // Fields allows partial responses to be retrieved. See
  3235  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3236  // details.
  3237  func (c *ProjectsPatchDeploymentsGetCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsGetCall {
  3238  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3239  	return c
  3240  }
  3241  
  3242  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3243  // object's ETag matches the given value. This is useful for getting updates
  3244  // only after the object has changed since the last request.
  3245  func (c *ProjectsPatchDeploymentsGetCall) IfNoneMatch(entityTag string) *ProjectsPatchDeploymentsGetCall {
  3246  	c.ifNoneMatch_ = entityTag
  3247  	return c
  3248  }
  3249  
  3250  // Context sets the context to be used in this call's Do method.
  3251  func (c *ProjectsPatchDeploymentsGetCall) Context(ctx context.Context) *ProjectsPatchDeploymentsGetCall {
  3252  	c.ctx_ = ctx
  3253  	return c
  3254  }
  3255  
  3256  // Header returns a http.Header that can be modified by the caller to add
  3257  // headers to the request.
  3258  func (c *ProjectsPatchDeploymentsGetCall) Header() http.Header {
  3259  	if c.header_ == nil {
  3260  		c.header_ = make(http.Header)
  3261  	}
  3262  	return c.header_
  3263  }
  3264  
  3265  func (c *ProjectsPatchDeploymentsGetCall) doRequest(alt string) (*http.Response, error) {
  3266  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3267  	if c.ifNoneMatch_ != "" {
  3268  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3269  	}
  3270  	var body io.Reader = nil
  3271  	c.urlParams_.Set("alt", alt)
  3272  	c.urlParams_.Set("prettyPrint", "false")
  3273  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  3274  	urls += "?" + c.urlParams_.Encode()
  3275  	req, err := http.NewRequest("GET", urls, body)
  3276  	if err != nil {
  3277  		return nil, err
  3278  	}
  3279  	req.Header = reqHeaders
  3280  	googleapi.Expand(req.URL, map[string]string{
  3281  		"name": c.name,
  3282  	})
  3283  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3284  }
  3285  
  3286  // Do executes the "osconfig.projects.patchDeployments.get" call.
  3287  // Any non-2xx status code is an error. Response headers are in either
  3288  // *PatchDeployment.ServerResponse.Header or (if a response was returned at
  3289  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3290  // check whether the returned error was because http.StatusNotModified was
  3291  // returned.
  3292  func (c *ProjectsPatchDeploymentsGetCall) Do(opts ...googleapi.CallOption) (*PatchDeployment, error) {
  3293  	gensupport.SetOptions(c.urlParams_, opts...)
  3294  	res, err := c.doRequest("json")
  3295  	if res != nil && res.StatusCode == http.StatusNotModified {
  3296  		if res.Body != nil {
  3297  			res.Body.Close()
  3298  		}
  3299  		return nil, gensupport.WrapError(&googleapi.Error{
  3300  			Code:   res.StatusCode,
  3301  			Header: res.Header,
  3302  		})
  3303  	}
  3304  	if err != nil {
  3305  		return nil, err
  3306  	}
  3307  	defer googleapi.CloseBody(res)
  3308  	if err := googleapi.CheckResponse(res); err != nil {
  3309  		return nil, gensupport.WrapError(err)
  3310  	}
  3311  	ret := &PatchDeployment{
  3312  		ServerResponse: googleapi.ServerResponse{
  3313  			Header:         res.Header,
  3314  			HTTPStatusCode: res.StatusCode,
  3315  		},
  3316  	}
  3317  	target := &ret
  3318  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3319  		return nil, err
  3320  	}
  3321  	return ret, nil
  3322  }
  3323  
  3324  type ProjectsPatchDeploymentsListCall struct {
  3325  	s            *Service
  3326  	parent       string
  3327  	urlParams_   gensupport.URLParams
  3328  	ifNoneMatch_ string
  3329  	ctx_         context.Context
  3330  	header_      http.Header
  3331  }
  3332  
  3333  // List: Get a page of OS Config patch deployments.
  3334  //
  3335  // - parent: The resource name of the parent in the form `projects/*`.
  3336  func (r *ProjectsPatchDeploymentsService) List(parent string) *ProjectsPatchDeploymentsListCall {
  3337  	c := &ProjectsPatchDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3338  	c.parent = parent
  3339  	return c
  3340  }
  3341  
  3342  // PageSize sets the optional parameter "pageSize": The maximum number of patch
  3343  // deployments to return. Default is 100.
  3344  func (c *ProjectsPatchDeploymentsListCall) PageSize(pageSize int64) *ProjectsPatchDeploymentsListCall {
  3345  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3346  	return c
  3347  }
  3348  
  3349  // PageToken sets the optional parameter "pageToken": A pagination token
  3350  // returned from a previous call to ListPatchDeployments that indicates where
  3351  // this listing should continue from.
  3352  func (c *ProjectsPatchDeploymentsListCall) PageToken(pageToken string) *ProjectsPatchDeploymentsListCall {
  3353  	c.urlParams_.Set("pageToken", pageToken)
  3354  	return c
  3355  }
  3356  
  3357  // Fields allows partial responses to be retrieved. See
  3358  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3359  // details.
  3360  func (c *ProjectsPatchDeploymentsListCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsListCall {
  3361  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3362  	return c
  3363  }
  3364  
  3365  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3366  // object's ETag matches the given value. This is useful for getting updates
  3367  // only after the object has changed since the last request.
  3368  func (c *ProjectsPatchDeploymentsListCall) IfNoneMatch(entityTag string) *ProjectsPatchDeploymentsListCall {
  3369  	c.ifNoneMatch_ = entityTag
  3370  	return c
  3371  }
  3372  
  3373  // Context sets the context to be used in this call's Do method.
  3374  func (c *ProjectsPatchDeploymentsListCall) Context(ctx context.Context) *ProjectsPatchDeploymentsListCall {
  3375  	c.ctx_ = ctx
  3376  	return c
  3377  }
  3378  
  3379  // Header returns a http.Header that can be modified by the caller to add
  3380  // headers to the request.
  3381  func (c *ProjectsPatchDeploymentsListCall) Header() http.Header {
  3382  	if c.header_ == nil {
  3383  		c.header_ = make(http.Header)
  3384  	}
  3385  	return c.header_
  3386  }
  3387  
  3388  func (c *ProjectsPatchDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
  3389  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3390  	if c.ifNoneMatch_ != "" {
  3391  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3392  	}
  3393  	var body io.Reader = nil
  3394  	c.urlParams_.Set("alt", alt)
  3395  	c.urlParams_.Set("prettyPrint", "false")
  3396  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/patchDeployments")
  3397  	urls += "?" + c.urlParams_.Encode()
  3398  	req, err := http.NewRequest("GET", urls, body)
  3399  	if err != nil {
  3400  		return nil, err
  3401  	}
  3402  	req.Header = reqHeaders
  3403  	googleapi.Expand(req.URL, map[string]string{
  3404  		"parent": c.parent,
  3405  	})
  3406  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3407  }
  3408  
  3409  // Do executes the "osconfig.projects.patchDeployments.list" call.
  3410  // Any non-2xx status code is an error. Response headers are in either
  3411  // *ListPatchDeploymentsResponse.ServerResponse.Header or (if a response was
  3412  // returned at all) in error.(*googleapi.Error).Header. Use
  3413  // googleapi.IsNotModified to check whether the returned error was because
  3414  // http.StatusNotModified was returned.
  3415  func (c *ProjectsPatchDeploymentsListCall) Do(opts ...googleapi.CallOption) (*ListPatchDeploymentsResponse, error) {
  3416  	gensupport.SetOptions(c.urlParams_, opts...)
  3417  	res, err := c.doRequest("json")
  3418  	if res != nil && res.StatusCode == http.StatusNotModified {
  3419  		if res.Body != nil {
  3420  			res.Body.Close()
  3421  		}
  3422  		return nil, gensupport.WrapError(&googleapi.Error{
  3423  			Code:   res.StatusCode,
  3424  			Header: res.Header,
  3425  		})
  3426  	}
  3427  	if err != nil {
  3428  		return nil, err
  3429  	}
  3430  	defer googleapi.CloseBody(res)
  3431  	if err := googleapi.CheckResponse(res); err != nil {
  3432  		return nil, gensupport.WrapError(err)
  3433  	}
  3434  	ret := &ListPatchDeploymentsResponse{
  3435  		ServerResponse: googleapi.ServerResponse{
  3436  			Header:         res.Header,
  3437  			HTTPStatusCode: res.StatusCode,
  3438  		},
  3439  	}
  3440  	target := &ret
  3441  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3442  		return nil, err
  3443  	}
  3444  	return ret, nil
  3445  }
  3446  
  3447  // Pages invokes f for each page of results.
  3448  // A non-nil error returned from f will halt the iteration.
  3449  // The provided context supersedes any context provided to the Context method.
  3450  func (c *ProjectsPatchDeploymentsListCall) Pages(ctx context.Context, f func(*ListPatchDeploymentsResponse) error) error {
  3451  	c.ctx_ = ctx
  3452  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3453  	for {
  3454  		x, err := c.Do()
  3455  		if err != nil {
  3456  			return err
  3457  		}
  3458  		if err := f(x); err != nil {
  3459  			return err
  3460  		}
  3461  		if x.NextPageToken == "" {
  3462  			return nil
  3463  		}
  3464  		c.PageToken(x.NextPageToken)
  3465  	}
  3466  }
  3467  
  3468  type ProjectsPatchDeploymentsPatchCall struct {
  3469  	s               *Service
  3470  	name            string
  3471  	patchdeployment *PatchDeployment
  3472  	urlParams_      gensupport.URLParams
  3473  	ctx_            context.Context
  3474  	header_         http.Header
  3475  }
  3476  
  3477  // Patch: Update an OS Config patch deployment.
  3478  //
  3479  //   - name: Unique name for the patch deployment resource in a project. The
  3480  //     patch deployment name is in the form:
  3481  //     `projects/{project_id}/patchDeployments/{patch_deployment_id}`. This field
  3482  //     is ignored when you create a new patch deployment.
  3483  func (r *ProjectsPatchDeploymentsService) Patch(name string, patchdeployment *PatchDeployment) *ProjectsPatchDeploymentsPatchCall {
  3484  	c := &ProjectsPatchDeploymentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3485  	c.name = name
  3486  	c.patchdeployment = patchdeployment
  3487  	return c
  3488  }
  3489  
  3490  // UpdateMask sets the optional parameter "updateMask": Field mask that
  3491  // controls which fields of the patch deployment should be updated.
  3492  func (c *ProjectsPatchDeploymentsPatchCall) UpdateMask(updateMask string) *ProjectsPatchDeploymentsPatchCall {
  3493  	c.urlParams_.Set("updateMask", updateMask)
  3494  	return c
  3495  }
  3496  
  3497  // Fields allows partial responses to be retrieved. See
  3498  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3499  // details.
  3500  func (c *ProjectsPatchDeploymentsPatchCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsPatchCall {
  3501  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3502  	return c
  3503  }
  3504  
  3505  // Context sets the context to be used in this call's Do method.
  3506  func (c *ProjectsPatchDeploymentsPatchCall) Context(ctx context.Context) *ProjectsPatchDeploymentsPatchCall {
  3507  	c.ctx_ = ctx
  3508  	return c
  3509  }
  3510  
  3511  // Header returns a http.Header that can be modified by the caller to add
  3512  // headers to the request.
  3513  func (c *ProjectsPatchDeploymentsPatchCall) Header() http.Header {
  3514  	if c.header_ == nil {
  3515  		c.header_ = make(http.Header)
  3516  	}
  3517  	return c.header_
  3518  }
  3519  
  3520  func (c *ProjectsPatchDeploymentsPatchCall) doRequest(alt string) (*http.Response, error) {
  3521  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3522  	var body io.Reader = nil
  3523  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.patchdeployment)
  3524  	if err != nil {
  3525  		return nil, err
  3526  	}
  3527  	c.urlParams_.Set("alt", alt)
  3528  	c.urlParams_.Set("prettyPrint", "false")
  3529  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  3530  	urls += "?" + c.urlParams_.Encode()
  3531  	req, err := http.NewRequest("PATCH", urls, body)
  3532  	if err != nil {
  3533  		return nil, err
  3534  	}
  3535  	req.Header = reqHeaders
  3536  	googleapi.Expand(req.URL, map[string]string{
  3537  		"name": c.name,
  3538  	})
  3539  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3540  }
  3541  
  3542  // Do executes the "osconfig.projects.patchDeployments.patch" call.
  3543  // Any non-2xx status code is an error. Response headers are in either
  3544  // *PatchDeployment.ServerResponse.Header or (if a response was returned at
  3545  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3546  // check whether the returned error was because http.StatusNotModified was
  3547  // returned.
  3548  func (c *ProjectsPatchDeploymentsPatchCall) Do(opts ...googleapi.CallOption) (*PatchDeployment, error) {
  3549  	gensupport.SetOptions(c.urlParams_, opts...)
  3550  	res, err := c.doRequest("json")
  3551  	if res != nil && res.StatusCode == http.StatusNotModified {
  3552  		if res.Body != nil {
  3553  			res.Body.Close()
  3554  		}
  3555  		return nil, gensupport.WrapError(&googleapi.Error{
  3556  			Code:   res.StatusCode,
  3557  			Header: res.Header,
  3558  		})
  3559  	}
  3560  	if err != nil {
  3561  		return nil, err
  3562  	}
  3563  	defer googleapi.CloseBody(res)
  3564  	if err := googleapi.CheckResponse(res); err != nil {
  3565  		return nil, gensupport.WrapError(err)
  3566  	}
  3567  	ret := &PatchDeployment{
  3568  		ServerResponse: googleapi.ServerResponse{
  3569  			Header:         res.Header,
  3570  			HTTPStatusCode: res.StatusCode,
  3571  		},
  3572  	}
  3573  	target := &ret
  3574  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3575  		return nil, err
  3576  	}
  3577  	return ret, nil
  3578  }
  3579  
  3580  type ProjectsPatchDeploymentsPauseCall struct {
  3581  	s                           *Service
  3582  	name                        string
  3583  	pausepatchdeploymentrequest *PausePatchDeploymentRequest
  3584  	urlParams_                  gensupport.URLParams
  3585  	ctx_                        context.Context
  3586  	header_                     http.Header
  3587  }
  3588  
  3589  // Pause: Change state of patch deployment to "PAUSED". Patch deployment in
  3590  // paused state doesn't generate patch jobs.
  3591  //
  3592  //   - name: The resource name of the patch deployment in the form
  3593  //     `projects/*/patchDeployments/*`.
  3594  func (r *ProjectsPatchDeploymentsService) Pause(name string, pausepatchdeploymentrequest *PausePatchDeploymentRequest) *ProjectsPatchDeploymentsPauseCall {
  3595  	c := &ProjectsPatchDeploymentsPauseCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3596  	c.name = name
  3597  	c.pausepatchdeploymentrequest = pausepatchdeploymentrequest
  3598  	return c
  3599  }
  3600  
  3601  // Fields allows partial responses to be retrieved. See
  3602  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3603  // details.
  3604  func (c *ProjectsPatchDeploymentsPauseCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsPauseCall {
  3605  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3606  	return c
  3607  }
  3608  
  3609  // Context sets the context to be used in this call's Do method.
  3610  func (c *ProjectsPatchDeploymentsPauseCall) Context(ctx context.Context) *ProjectsPatchDeploymentsPauseCall {
  3611  	c.ctx_ = ctx
  3612  	return c
  3613  }
  3614  
  3615  // Header returns a http.Header that can be modified by the caller to add
  3616  // headers to the request.
  3617  func (c *ProjectsPatchDeploymentsPauseCall) Header() http.Header {
  3618  	if c.header_ == nil {
  3619  		c.header_ = make(http.Header)
  3620  	}
  3621  	return c.header_
  3622  }
  3623  
  3624  func (c *ProjectsPatchDeploymentsPauseCall) doRequest(alt string) (*http.Response, error) {
  3625  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3626  	var body io.Reader = nil
  3627  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.pausepatchdeploymentrequest)
  3628  	if err != nil {
  3629  		return nil, err
  3630  	}
  3631  	c.urlParams_.Set("alt", alt)
  3632  	c.urlParams_.Set("prettyPrint", "false")
  3633  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:pause")
  3634  	urls += "?" + c.urlParams_.Encode()
  3635  	req, err := http.NewRequest("POST", urls, body)
  3636  	if err != nil {
  3637  		return nil, err
  3638  	}
  3639  	req.Header = reqHeaders
  3640  	googleapi.Expand(req.URL, map[string]string{
  3641  		"name": c.name,
  3642  	})
  3643  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3644  }
  3645  
  3646  // Do executes the "osconfig.projects.patchDeployments.pause" call.
  3647  // Any non-2xx status code is an error. Response headers are in either
  3648  // *PatchDeployment.ServerResponse.Header or (if a response was returned at
  3649  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3650  // check whether the returned error was because http.StatusNotModified was
  3651  // returned.
  3652  func (c *ProjectsPatchDeploymentsPauseCall) Do(opts ...googleapi.CallOption) (*PatchDeployment, error) {
  3653  	gensupport.SetOptions(c.urlParams_, opts...)
  3654  	res, err := c.doRequest("json")
  3655  	if res != nil && res.StatusCode == http.StatusNotModified {
  3656  		if res.Body != nil {
  3657  			res.Body.Close()
  3658  		}
  3659  		return nil, gensupport.WrapError(&googleapi.Error{
  3660  			Code:   res.StatusCode,
  3661  			Header: res.Header,
  3662  		})
  3663  	}
  3664  	if err != nil {
  3665  		return nil, err
  3666  	}
  3667  	defer googleapi.CloseBody(res)
  3668  	if err := googleapi.CheckResponse(res); err != nil {
  3669  		return nil, gensupport.WrapError(err)
  3670  	}
  3671  	ret := &PatchDeployment{
  3672  		ServerResponse: googleapi.ServerResponse{
  3673  			Header:         res.Header,
  3674  			HTTPStatusCode: res.StatusCode,
  3675  		},
  3676  	}
  3677  	target := &ret
  3678  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3679  		return nil, err
  3680  	}
  3681  	return ret, nil
  3682  }
  3683  
  3684  type ProjectsPatchDeploymentsResumeCall struct {
  3685  	s                            *Service
  3686  	name                         string
  3687  	resumepatchdeploymentrequest *ResumePatchDeploymentRequest
  3688  	urlParams_                   gensupport.URLParams
  3689  	ctx_                         context.Context
  3690  	header_                      http.Header
  3691  }
  3692  
  3693  // Resume: Change state of patch deployment back to "ACTIVE". Patch deployment
  3694  // in active state continues to generate patch jobs.
  3695  //
  3696  //   - name: The resource name of the patch deployment in the form
  3697  //     `projects/*/patchDeployments/*`.
  3698  func (r *ProjectsPatchDeploymentsService) Resume(name string, resumepatchdeploymentrequest *ResumePatchDeploymentRequest) *ProjectsPatchDeploymentsResumeCall {
  3699  	c := &ProjectsPatchDeploymentsResumeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3700  	c.name = name
  3701  	c.resumepatchdeploymentrequest = resumepatchdeploymentrequest
  3702  	return c
  3703  }
  3704  
  3705  // Fields allows partial responses to be retrieved. See
  3706  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3707  // details.
  3708  func (c *ProjectsPatchDeploymentsResumeCall) Fields(s ...googleapi.Field) *ProjectsPatchDeploymentsResumeCall {
  3709  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3710  	return c
  3711  }
  3712  
  3713  // Context sets the context to be used in this call's Do method.
  3714  func (c *ProjectsPatchDeploymentsResumeCall) Context(ctx context.Context) *ProjectsPatchDeploymentsResumeCall {
  3715  	c.ctx_ = ctx
  3716  	return c
  3717  }
  3718  
  3719  // Header returns a http.Header that can be modified by the caller to add
  3720  // headers to the request.
  3721  func (c *ProjectsPatchDeploymentsResumeCall) Header() http.Header {
  3722  	if c.header_ == nil {
  3723  		c.header_ = make(http.Header)
  3724  	}
  3725  	return c.header_
  3726  }
  3727  
  3728  func (c *ProjectsPatchDeploymentsResumeCall) doRequest(alt string) (*http.Response, error) {
  3729  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3730  	var body io.Reader = nil
  3731  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.resumepatchdeploymentrequest)
  3732  	if err != nil {
  3733  		return nil, err
  3734  	}
  3735  	c.urlParams_.Set("alt", alt)
  3736  	c.urlParams_.Set("prettyPrint", "false")
  3737  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:resume")
  3738  	urls += "?" + c.urlParams_.Encode()
  3739  	req, err := http.NewRequest("POST", urls, body)
  3740  	if err != nil {
  3741  		return nil, err
  3742  	}
  3743  	req.Header = reqHeaders
  3744  	googleapi.Expand(req.URL, map[string]string{
  3745  		"name": c.name,
  3746  	})
  3747  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3748  }
  3749  
  3750  // Do executes the "osconfig.projects.patchDeployments.resume" call.
  3751  // Any non-2xx status code is an error. Response headers are in either
  3752  // *PatchDeployment.ServerResponse.Header or (if a response was returned at
  3753  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3754  // check whether the returned error was because http.StatusNotModified was
  3755  // returned.
  3756  func (c *ProjectsPatchDeploymentsResumeCall) Do(opts ...googleapi.CallOption) (*PatchDeployment, error) {
  3757  	gensupport.SetOptions(c.urlParams_, opts...)
  3758  	res, err := c.doRequest("json")
  3759  	if res != nil && res.StatusCode == http.StatusNotModified {
  3760  		if res.Body != nil {
  3761  			res.Body.Close()
  3762  		}
  3763  		return nil, gensupport.WrapError(&googleapi.Error{
  3764  			Code:   res.StatusCode,
  3765  			Header: res.Header,
  3766  		})
  3767  	}
  3768  	if err != nil {
  3769  		return nil, err
  3770  	}
  3771  	defer googleapi.CloseBody(res)
  3772  	if err := googleapi.CheckResponse(res); err != nil {
  3773  		return nil, gensupport.WrapError(err)
  3774  	}
  3775  	ret := &PatchDeployment{
  3776  		ServerResponse: googleapi.ServerResponse{
  3777  			Header:         res.Header,
  3778  			HTTPStatusCode: res.StatusCode,
  3779  		},
  3780  	}
  3781  	target := &ret
  3782  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3783  		return nil, err
  3784  	}
  3785  	return ret, nil
  3786  }
  3787  
  3788  type ProjectsPatchJobsCancelCall struct {
  3789  	s                     *Service
  3790  	name                  string
  3791  	cancelpatchjobrequest *CancelPatchJobRequest
  3792  	urlParams_            gensupport.URLParams
  3793  	ctx_                  context.Context
  3794  	header_               http.Header
  3795  }
  3796  
  3797  // Cancel: Cancel a patch job. The patch job must be active. Canceled patch
  3798  // jobs cannot be restarted.
  3799  //
  3800  // - name: Name of the patch in the form `projects/*/patchJobs/*`.
  3801  func (r *ProjectsPatchJobsService) Cancel(name string, cancelpatchjobrequest *CancelPatchJobRequest) *ProjectsPatchJobsCancelCall {
  3802  	c := &ProjectsPatchJobsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3803  	c.name = name
  3804  	c.cancelpatchjobrequest = cancelpatchjobrequest
  3805  	return c
  3806  }
  3807  
  3808  // Fields allows partial responses to be retrieved. See
  3809  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3810  // details.
  3811  func (c *ProjectsPatchJobsCancelCall) Fields(s ...googleapi.Field) *ProjectsPatchJobsCancelCall {
  3812  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3813  	return c
  3814  }
  3815  
  3816  // Context sets the context to be used in this call's Do method.
  3817  func (c *ProjectsPatchJobsCancelCall) Context(ctx context.Context) *ProjectsPatchJobsCancelCall {
  3818  	c.ctx_ = ctx
  3819  	return c
  3820  }
  3821  
  3822  // Header returns a http.Header that can be modified by the caller to add
  3823  // headers to the request.
  3824  func (c *ProjectsPatchJobsCancelCall) Header() http.Header {
  3825  	if c.header_ == nil {
  3826  		c.header_ = make(http.Header)
  3827  	}
  3828  	return c.header_
  3829  }
  3830  
  3831  func (c *ProjectsPatchJobsCancelCall) doRequest(alt string) (*http.Response, error) {
  3832  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3833  	var body io.Reader = nil
  3834  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.cancelpatchjobrequest)
  3835  	if err != nil {
  3836  		return nil, err
  3837  	}
  3838  	c.urlParams_.Set("alt", alt)
  3839  	c.urlParams_.Set("prettyPrint", "false")
  3840  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:cancel")
  3841  	urls += "?" + c.urlParams_.Encode()
  3842  	req, err := http.NewRequest("POST", urls, body)
  3843  	if err != nil {
  3844  		return nil, err
  3845  	}
  3846  	req.Header = reqHeaders
  3847  	googleapi.Expand(req.URL, map[string]string{
  3848  		"name": c.name,
  3849  	})
  3850  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3851  }
  3852  
  3853  // Do executes the "osconfig.projects.patchJobs.cancel" call.
  3854  // Any non-2xx status code is an error. Response headers are in either
  3855  // *PatchJob.ServerResponse.Header or (if a response was returned at all) in
  3856  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3857  // whether the returned error was because http.StatusNotModified was returned.
  3858  func (c *ProjectsPatchJobsCancelCall) Do(opts ...googleapi.CallOption) (*PatchJob, error) {
  3859  	gensupport.SetOptions(c.urlParams_, opts...)
  3860  	res, err := c.doRequest("json")
  3861  	if res != nil && res.StatusCode == http.StatusNotModified {
  3862  		if res.Body != nil {
  3863  			res.Body.Close()
  3864  		}
  3865  		return nil, gensupport.WrapError(&googleapi.Error{
  3866  			Code:   res.StatusCode,
  3867  			Header: res.Header,
  3868  		})
  3869  	}
  3870  	if err != nil {
  3871  		return nil, err
  3872  	}
  3873  	defer googleapi.CloseBody(res)
  3874  	if err := googleapi.CheckResponse(res); err != nil {
  3875  		return nil, gensupport.WrapError(err)
  3876  	}
  3877  	ret := &PatchJob{
  3878  		ServerResponse: googleapi.ServerResponse{
  3879  			Header:         res.Header,
  3880  			HTTPStatusCode: res.StatusCode,
  3881  		},
  3882  	}
  3883  	target := &ret
  3884  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3885  		return nil, err
  3886  	}
  3887  	return ret, nil
  3888  }
  3889  
  3890  type ProjectsPatchJobsExecuteCall struct {
  3891  	s                      *Service
  3892  	parent                 string
  3893  	executepatchjobrequest *ExecutePatchJobRequest
  3894  	urlParams_             gensupport.URLParams
  3895  	ctx_                   context.Context
  3896  	header_                http.Header
  3897  }
  3898  
  3899  // Execute: Patch VM instances by creating and running a patch job.
  3900  //
  3901  // - parent: The project in which to run this patch in the form `projects/*`.
  3902  func (r *ProjectsPatchJobsService) Execute(parent string, executepatchjobrequest *ExecutePatchJobRequest) *ProjectsPatchJobsExecuteCall {
  3903  	c := &ProjectsPatchJobsExecuteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3904  	c.parent = parent
  3905  	c.executepatchjobrequest = executepatchjobrequest
  3906  	return c
  3907  }
  3908  
  3909  // Fields allows partial responses to be retrieved. See
  3910  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3911  // details.
  3912  func (c *ProjectsPatchJobsExecuteCall) Fields(s ...googleapi.Field) *ProjectsPatchJobsExecuteCall {
  3913  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3914  	return c
  3915  }
  3916  
  3917  // Context sets the context to be used in this call's Do method.
  3918  func (c *ProjectsPatchJobsExecuteCall) Context(ctx context.Context) *ProjectsPatchJobsExecuteCall {
  3919  	c.ctx_ = ctx
  3920  	return c
  3921  }
  3922  
  3923  // Header returns a http.Header that can be modified by the caller to add
  3924  // headers to the request.
  3925  func (c *ProjectsPatchJobsExecuteCall) Header() http.Header {
  3926  	if c.header_ == nil {
  3927  		c.header_ = make(http.Header)
  3928  	}
  3929  	return c.header_
  3930  }
  3931  
  3932  func (c *ProjectsPatchJobsExecuteCall) doRequest(alt string) (*http.Response, error) {
  3933  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3934  	var body io.Reader = nil
  3935  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.executepatchjobrequest)
  3936  	if err != nil {
  3937  		return nil, err
  3938  	}
  3939  	c.urlParams_.Set("alt", alt)
  3940  	c.urlParams_.Set("prettyPrint", "false")
  3941  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/patchJobs:execute")
  3942  	urls += "?" + c.urlParams_.Encode()
  3943  	req, err := http.NewRequest("POST", urls, body)
  3944  	if err != nil {
  3945  		return nil, err
  3946  	}
  3947  	req.Header = reqHeaders
  3948  	googleapi.Expand(req.URL, map[string]string{
  3949  		"parent": c.parent,
  3950  	})
  3951  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3952  }
  3953  
  3954  // Do executes the "osconfig.projects.patchJobs.execute" call.
  3955  // Any non-2xx status code is an error. Response headers are in either
  3956  // *PatchJob.ServerResponse.Header or (if a response was returned at all) in
  3957  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3958  // whether the returned error was because http.StatusNotModified was returned.
  3959  func (c *ProjectsPatchJobsExecuteCall) Do(opts ...googleapi.CallOption) (*PatchJob, error) {
  3960  	gensupport.SetOptions(c.urlParams_, opts...)
  3961  	res, err := c.doRequest("json")
  3962  	if res != nil && res.StatusCode == http.StatusNotModified {
  3963  		if res.Body != nil {
  3964  			res.Body.Close()
  3965  		}
  3966  		return nil, gensupport.WrapError(&googleapi.Error{
  3967  			Code:   res.StatusCode,
  3968  			Header: res.Header,
  3969  		})
  3970  	}
  3971  	if err != nil {
  3972  		return nil, err
  3973  	}
  3974  	defer googleapi.CloseBody(res)
  3975  	if err := googleapi.CheckResponse(res); err != nil {
  3976  		return nil, gensupport.WrapError(err)
  3977  	}
  3978  	ret := &PatchJob{
  3979  		ServerResponse: googleapi.ServerResponse{
  3980  			Header:         res.Header,
  3981  			HTTPStatusCode: res.StatusCode,
  3982  		},
  3983  	}
  3984  	target := &ret
  3985  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3986  		return nil, err
  3987  	}
  3988  	return ret, nil
  3989  }
  3990  
  3991  type ProjectsPatchJobsGetCall struct {
  3992  	s            *Service
  3993  	name         string
  3994  	urlParams_   gensupport.URLParams
  3995  	ifNoneMatch_ string
  3996  	ctx_         context.Context
  3997  	header_      http.Header
  3998  }
  3999  
  4000  // Get: Get the patch job. This can be used to track the progress of an ongoing
  4001  // patch job or review the details of completed jobs.
  4002  //
  4003  // - name: Name of the patch in the form `projects/*/patchJobs/*`.
  4004  func (r *ProjectsPatchJobsService) Get(name string) *ProjectsPatchJobsGetCall {
  4005  	c := &ProjectsPatchJobsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4006  	c.name = name
  4007  	return c
  4008  }
  4009  
  4010  // Fields allows partial responses to be retrieved. See
  4011  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4012  // details.
  4013  func (c *ProjectsPatchJobsGetCall) Fields(s ...googleapi.Field) *ProjectsPatchJobsGetCall {
  4014  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4015  	return c
  4016  }
  4017  
  4018  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4019  // object's ETag matches the given value. This is useful for getting updates
  4020  // only after the object has changed since the last request.
  4021  func (c *ProjectsPatchJobsGetCall) IfNoneMatch(entityTag string) *ProjectsPatchJobsGetCall {
  4022  	c.ifNoneMatch_ = entityTag
  4023  	return c
  4024  }
  4025  
  4026  // Context sets the context to be used in this call's Do method.
  4027  func (c *ProjectsPatchJobsGetCall) Context(ctx context.Context) *ProjectsPatchJobsGetCall {
  4028  	c.ctx_ = ctx
  4029  	return c
  4030  }
  4031  
  4032  // Header returns a http.Header that can be modified by the caller to add
  4033  // headers to the request.
  4034  func (c *ProjectsPatchJobsGetCall) Header() http.Header {
  4035  	if c.header_ == nil {
  4036  		c.header_ = make(http.Header)
  4037  	}
  4038  	return c.header_
  4039  }
  4040  
  4041  func (c *ProjectsPatchJobsGetCall) doRequest(alt string) (*http.Response, error) {
  4042  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4043  	if c.ifNoneMatch_ != "" {
  4044  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4045  	}
  4046  	var body io.Reader = nil
  4047  	c.urlParams_.Set("alt", alt)
  4048  	c.urlParams_.Set("prettyPrint", "false")
  4049  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  4050  	urls += "?" + c.urlParams_.Encode()
  4051  	req, err := http.NewRequest("GET", urls, body)
  4052  	if err != nil {
  4053  		return nil, err
  4054  	}
  4055  	req.Header = reqHeaders
  4056  	googleapi.Expand(req.URL, map[string]string{
  4057  		"name": c.name,
  4058  	})
  4059  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4060  }
  4061  
  4062  // Do executes the "osconfig.projects.patchJobs.get" call.
  4063  // Any non-2xx status code is an error. Response headers are in either
  4064  // *PatchJob.ServerResponse.Header or (if a response was returned at all) in
  4065  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4066  // whether the returned error was because http.StatusNotModified was returned.
  4067  func (c *ProjectsPatchJobsGetCall) Do(opts ...googleapi.CallOption) (*PatchJob, error) {
  4068  	gensupport.SetOptions(c.urlParams_, opts...)
  4069  	res, err := c.doRequest("json")
  4070  	if res != nil && res.StatusCode == http.StatusNotModified {
  4071  		if res.Body != nil {
  4072  			res.Body.Close()
  4073  		}
  4074  		return nil, gensupport.WrapError(&googleapi.Error{
  4075  			Code:   res.StatusCode,
  4076  			Header: res.Header,
  4077  		})
  4078  	}
  4079  	if err != nil {
  4080  		return nil, err
  4081  	}
  4082  	defer googleapi.CloseBody(res)
  4083  	if err := googleapi.CheckResponse(res); err != nil {
  4084  		return nil, gensupport.WrapError(err)
  4085  	}
  4086  	ret := &PatchJob{
  4087  		ServerResponse: googleapi.ServerResponse{
  4088  			Header:         res.Header,
  4089  			HTTPStatusCode: res.StatusCode,
  4090  		},
  4091  	}
  4092  	target := &ret
  4093  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4094  		return nil, err
  4095  	}
  4096  	return ret, nil
  4097  }
  4098  
  4099  type ProjectsPatchJobsListCall struct {
  4100  	s            *Service
  4101  	parent       string
  4102  	urlParams_   gensupport.URLParams
  4103  	ifNoneMatch_ string
  4104  	ctx_         context.Context
  4105  	header_      http.Header
  4106  }
  4107  
  4108  // List: Get a list of patch jobs.
  4109  //
  4110  // - parent: In the form of `projects/*`.
  4111  func (r *ProjectsPatchJobsService) List(parent string) *ProjectsPatchJobsListCall {
  4112  	c := &ProjectsPatchJobsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4113  	c.parent = parent
  4114  	return c
  4115  }
  4116  
  4117  // Filter sets the optional parameter "filter": If provided, this field
  4118  // specifies the criteria that must be met by patch jobs to be included in the
  4119  // response. Currently, filtering is only available on the patch_deployment
  4120  // field.
  4121  func (c *ProjectsPatchJobsListCall) Filter(filter string) *ProjectsPatchJobsListCall {
  4122  	c.urlParams_.Set("filter", filter)
  4123  	return c
  4124  }
  4125  
  4126  // PageSize sets the optional parameter "pageSize": The maximum number of
  4127  // instance status to return.
  4128  func (c *ProjectsPatchJobsListCall) PageSize(pageSize int64) *ProjectsPatchJobsListCall {
  4129  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4130  	return c
  4131  }
  4132  
  4133  // PageToken sets the optional parameter "pageToken": A pagination token
  4134  // returned from a previous call that indicates where this listing should
  4135  // continue from.
  4136  func (c *ProjectsPatchJobsListCall) PageToken(pageToken string) *ProjectsPatchJobsListCall {
  4137  	c.urlParams_.Set("pageToken", pageToken)
  4138  	return c
  4139  }
  4140  
  4141  // Fields allows partial responses to be retrieved. See
  4142  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4143  // details.
  4144  func (c *ProjectsPatchJobsListCall) Fields(s ...googleapi.Field) *ProjectsPatchJobsListCall {
  4145  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4146  	return c
  4147  }
  4148  
  4149  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4150  // object's ETag matches the given value. This is useful for getting updates
  4151  // only after the object has changed since the last request.
  4152  func (c *ProjectsPatchJobsListCall) IfNoneMatch(entityTag string) *ProjectsPatchJobsListCall {
  4153  	c.ifNoneMatch_ = entityTag
  4154  	return c
  4155  }
  4156  
  4157  // Context sets the context to be used in this call's Do method.
  4158  func (c *ProjectsPatchJobsListCall) Context(ctx context.Context) *ProjectsPatchJobsListCall {
  4159  	c.ctx_ = ctx
  4160  	return c
  4161  }
  4162  
  4163  // Header returns a http.Header that can be modified by the caller to add
  4164  // headers to the request.
  4165  func (c *ProjectsPatchJobsListCall) Header() http.Header {
  4166  	if c.header_ == nil {
  4167  		c.header_ = make(http.Header)
  4168  	}
  4169  	return c.header_
  4170  }
  4171  
  4172  func (c *ProjectsPatchJobsListCall) doRequest(alt string) (*http.Response, error) {
  4173  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4174  	if c.ifNoneMatch_ != "" {
  4175  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4176  	}
  4177  	var body io.Reader = nil
  4178  	c.urlParams_.Set("alt", alt)
  4179  	c.urlParams_.Set("prettyPrint", "false")
  4180  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/patchJobs")
  4181  	urls += "?" + c.urlParams_.Encode()
  4182  	req, err := http.NewRequest("GET", urls, body)
  4183  	if err != nil {
  4184  		return nil, err
  4185  	}
  4186  	req.Header = reqHeaders
  4187  	googleapi.Expand(req.URL, map[string]string{
  4188  		"parent": c.parent,
  4189  	})
  4190  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4191  }
  4192  
  4193  // Do executes the "osconfig.projects.patchJobs.list" call.
  4194  // Any non-2xx status code is an error. Response headers are in either
  4195  // *ListPatchJobsResponse.ServerResponse.Header or (if a response was returned
  4196  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  4197  // check whether the returned error was because http.StatusNotModified was
  4198  // returned.
  4199  func (c *ProjectsPatchJobsListCall) Do(opts ...googleapi.CallOption) (*ListPatchJobsResponse, error) {
  4200  	gensupport.SetOptions(c.urlParams_, opts...)
  4201  	res, err := c.doRequest("json")
  4202  	if res != nil && res.StatusCode == http.StatusNotModified {
  4203  		if res.Body != nil {
  4204  			res.Body.Close()
  4205  		}
  4206  		return nil, gensupport.WrapError(&googleapi.Error{
  4207  			Code:   res.StatusCode,
  4208  			Header: res.Header,
  4209  		})
  4210  	}
  4211  	if err != nil {
  4212  		return nil, err
  4213  	}
  4214  	defer googleapi.CloseBody(res)
  4215  	if err := googleapi.CheckResponse(res); err != nil {
  4216  		return nil, gensupport.WrapError(err)
  4217  	}
  4218  	ret := &ListPatchJobsResponse{
  4219  		ServerResponse: googleapi.ServerResponse{
  4220  			Header:         res.Header,
  4221  			HTTPStatusCode: res.StatusCode,
  4222  		},
  4223  	}
  4224  	target := &ret
  4225  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4226  		return nil, err
  4227  	}
  4228  	return ret, nil
  4229  }
  4230  
  4231  // Pages invokes f for each page of results.
  4232  // A non-nil error returned from f will halt the iteration.
  4233  // The provided context supersedes any context provided to the Context method.
  4234  func (c *ProjectsPatchJobsListCall) Pages(ctx context.Context, f func(*ListPatchJobsResponse) error) error {
  4235  	c.ctx_ = ctx
  4236  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4237  	for {
  4238  		x, err := c.Do()
  4239  		if err != nil {
  4240  			return err
  4241  		}
  4242  		if err := f(x); err != nil {
  4243  			return err
  4244  		}
  4245  		if x.NextPageToken == "" {
  4246  			return nil
  4247  		}
  4248  		c.PageToken(x.NextPageToken)
  4249  	}
  4250  }
  4251  
  4252  type ProjectsPatchJobsInstanceDetailsListCall struct {
  4253  	s            *Service
  4254  	parent       string
  4255  	urlParams_   gensupport.URLParams
  4256  	ifNoneMatch_ string
  4257  	ctx_         context.Context
  4258  	header_      http.Header
  4259  }
  4260  
  4261  // List: Get a list of instance details for a given patch job.
  4262  //
  4263  //   - parent: The parent for the instances are in the form of
  4264  //     `projects/*/patchJobs/*`.
  4265  func (r *ProjectsPatchJobsInstanceDetailsService) List(parent string) *ProjectsPatchJobsInstanceDetailsListCall {
  4266  	c := &ProjectsPatchJobsInstanceDetailsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4267  	c.parent = parent
  4268  	return c
  4269  }
  4270  
  4271  // Filter sets the optional parameter "filter": A filter expression that
  4272  // filters results listed in the response. This field supports filtering
  4273  // results by instance zone, name, state, or `failure_reason`.
  4274  func (c *ProjectsPatchJobsInstanceDetailsListCall) Filter(filter string) *ProjectsPatchJobsInstanceDetailsListCall {
  4275  	c.urlParams_.Set("filter", filter)
  4276  	return c
  4277  }
  4278  
  4279  // PageSize sets the optional parameter "pageSize": The maximum number of
  4280  // instance details records to return. Default is 100.
  4281  func (c *ProjectsPatchJobsInstanceDetailsListCall) PageSize(pageSize int64) *ProjectsPatchJobsInstanceDetailsListCall {
  4282  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4283  	return c
  4284  }
  4285  
  4286  // PageToken sets the optional parameter "pageToken": A pagination token
  4287  // returned from a previous call that indicates where this listing should
  4288  // continue from.
  4289  func (c *ProjectsPatchJobsInstanceDetailsListCall) PageToken(pageToken string) *ProjectsPatchJobsInstanceDetailsListCall {
  4290  	c.urlParams_.Set("pageToken", pageToken)
  4291  	return c
  4292  }
  4293  
  4294  // Fields allows partial responses to be retrieved. See
  4295  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4296  // details.
  4297  func (c *ProjectsPatchJobsInstanceDetailsListCall) Fields(s ...googleapi.Field) *ProjectsPatchJobsInstanceDetailsListCall {
  4298  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4299  	return c
  4300  }
  4301  
  4302  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4303  // object's ETag matches the given value. This is useful for getting updates
  4304  // only after the object has changed since the last request.
  4305  func (c *ProjectsPatchJobsInstanceDetailsListCall) IfNoneMatch(entityTag string) *ProjectsPatchJobsInstanceDetailsListCall {
  4306  	c.ifNoneMatch_ = entityTag
  4307  	return c
  4308  }
  4309  
  4310  // Context sets the context to be used in this call's Do method.
  4311  func (c *ProjectsPatchJobsInstanceDetailsListCall) Context(ctx context.Context) *ProjectsPatchJobsInstanceDetailsListCall {
  4312  	c.ctx_ = ctx
  4313  	return c
  4314  }
  4315  
  4316  // Header returns a http.Header that can be modified by the caller to add
  4317  // headers to the request.
  4318  func (c *ProjectsPatchJobsInstanceDetailsListCall) Header() http.Header {
  4319  	if c.header_ == nil {
  4320  		c.header_ = make(http.Header)
  4321  	}
  4322  	return c.header_
  4323  }
  4324  
  4325  func (c *ProjectsPatchJobsInstanceDetailsListCall) doRequest(alt string) (*http.Response, error) {
  4326  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4327  	if c.ifNoneMatch_ != "" {
  4328  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4329  	}
  4330  	var body io.Reader = nil
  4331  	c.urlParams_.Set("alt", alt)
  4332  	c.urlParams_.Set("prettyPrint", "false")
  4333  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/instanceDetails")
  4334  	urls += "?" + c.urlParams_.Encode()
  4335  	req, err := http.NewRequest("GET", urls, body)
  4336  	if err != nil {
  4337  		return nil, err
  4338  	}
  4339  	req.Header = reqHeaders
  4340  	googleapi.Expand(req.URL, map[string]string{
  4341  		"parent": c.parent,
  4342  	})
  4343  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4344  }
  4345  
  4346  // Do executes the "osconfig.projects.patchJobs.instanceDetails.list" call.
  4347  // Any non-2xx status code is an error. Response headers are in either
  4348  // *ListPatchJobInstanceDetailsResponse.ServerResponse.Header or (if a response
  4349  // was returned at all) in error.(*googleapi.Error).Header. Use
  4350  // googleapi.IsNotModified to check whether the returned error was because
  4351  // http.StatusNotModified was returned.
  4352  func (c *ProjectsPatchJobsInstanceDetailsListCall) Do(opts ...googleapi.CallOption) (*ListPatchJobInstanceDetailsResponse, error) {
  4353  	gensupport.SetOptions(c.urlParams_, opts...)
  4354  	res, err := c.doRequest("json")
  4355  	if res != nil && res.StatusCode == http.StatusNotModified {
  4356  		if res.Body != nil {
  4357  			res.Body.Close()
  4358  		}
  4359  		return nil, gensupport.WrapError(&googleapi.Error{
  4360  			Code:   res.StatusCode,
  4361  			Header: res.Header,
  4362  		})
  4363  	}
  4364  	if err != nil {
  4365  		return nil, err
  4366  	}
  4367  	defer googleapi.CloseBody(res)
  4368  	if err := googleapi.CheckResponse(res); err != nil {
  4369  		return nil, gensupport.WrapError(err)
  4370  	}
  4371  	ret := &ListPatchJobInstanceDetailsResponse{
  4372  		ServerResponse: googleapi.ServerResponse{
  4373  			Header:         res.Header,
  4374  			HTTPStatusCode: res.StatusCode,
  4375  		},
  4376  	}
  4377  	target := &ret
  4378  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4379  		return nil, err
  4380  	}
  4381  	return ret, nil
  4382  }
  4383  
  4384  // Pages invokes f for each page of results.
  4385  // A non-nil error returned from f will halt the iteration.
  4386  // The provided context supersedes any context provided to the Context method.
  4387  func (c *ProjectsPatchJobsInstanceDetailsListCall) Pages(ctx context.Context, f func(*ListPatchJobInstanceDetailsResponse) error) error {
  4388  	c.ctx_ = ctx
  4389  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4390  	for {
  4391  		x, err := c.Do()
  4392  		if err != nil {
  4393  			return err
  4394  		}
  4395  		if err := f(x); err != nil {
  4396  			return err
  4397  		}
  4398  		if x.NextPageToken == "" {
  4399  			return nil
  4400  		}
  4401  		c.PageToken(x.NextPageToken)
  4402  	}
  4403  }
  4404  
  4405  type ProjectsZonesInstancesLookupEffectiveGuestPolicyCall struct {
  4406  	s                                 *Service
  4407  	instance                          string
  4408  	lookupeffectiveguestpolicyrequest *LookupEffectiveGuestPolicyRequest
  4409  	urlParams_                        gensupport.URLParams
  4410  	ctx_                              context.Context
  4411  	header_                           http.Header
  4412  }
  4413  
  4414  // LookupEffectiveGuestPolicy: Lookup the effective guest policy that applies
  4415  // to a VM instance. This lookup merges all policies that are assigned to the
  4416  // instance ancestry.
  4417  //
  4418  // - instance: The VM instance whose policies are being looked up.
  4419  func (r *ProjectsZonesInstancesService) LookupEffectiveGuestPolicy(instance string, lookupeffectiveguestpolicyrequest *LookupEffectiveGuestPolicyRequest) *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall {
  4420  	c := &ProjectsZonesInstancesLookupEffectiveGuestPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4421  	c.instance = instance
  4422  	c.lookupeffectiveguestpolicyrequest = lookupeffectiveguestpolicyrequest
  4423  	return c
  4424  }
  4425  
  4426  // Fields allows partial responses to be retrieved. See
  4427  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4428  // details.
  4429  func (c *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall) Fields(s ...googleapi.Field) *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall {
  4430  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4431  	return c
  4432  }
  4433  
  4434  // Context sets the context to be used in this call's Do method.
  4435  func (c *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall) Context(ctx context.Context) *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall {
  4436  	c.ctx_ = ctx
  4437  	return c
  4438  }
  4439  
  4440  // Header returns a http.Header that can be modified by the caller to add
  4441  // headers to the request.
  4442  func (c *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall) Header() http.Header {
  4443  	if c.header_ == nil {
  4444  		c.header_ = make(http.Header)
  4445  	}
  4446  	return c.header_
  4447  }
  4448  
  4449  func (c *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall) doRequest(alt string) (*http.Response, error) {
  4450  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4451  	var body io.Reader = nil
  4452  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.lookupeffectiveguestpolicyrequest)
  4453  	if err != nil {
  4454  		return nil, err
  4455  	}
  4456  	c.urlParams_.Set("alt", alt)
  4457  	c.urlParams_.Set("prettyPrint", "false")
  4458  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+instance}:lookupEffectiveGuestPolicy")
  4459  	urls += "?" + c.urlParams_.Encode()
  4460  	req, err := http.NewRequest("POST", urls, body)
  4461  	if err != nil {
  4462  		return nil, err
  4463  	}
  4464  	req.Header = reqHeaders
  4465  	googleapi.Expand(req.URL, map[string]string{
  4466  		"instance": c.instance,
  4467  	})
  4468  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4469  }
  4470  
  4471  // Do executes the "osconfig.projects.zones.instances.lookupEffectiveGuestPolicy" call.
  4472  // Any non-2xx status code is an error. Response headers are in either
  4473  // *EffectiveGuestPolicy.ServerResponse.Header or (if a response was returned
  4474  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  4475  // check whether the returned error was because http.StatusNotModified was
  4476  // returned.
  4477  func (c *ProjectsZonesInstancesLookupEffectiveGuestPolicyCall) Do(opts ...googleapi.CallOption) (*EffectiveGuestPolicy, error) {
  4478  	gensupport.SetOptions(c.urlParams_, opts...)
  4479  	res, err := c.doRequest("json")
  4480  	if res != nil && res.StatusCode == http.StatusNotModified {
  4481  		if res.Body != nil {
  4482  			res.Body.Close()
  4483  		}
  4484  		return nil, gensupport.WrapError(&googleapi.Error{
  4485  			Code:   res.StatusCode,
  4486  			Header: res.Header,
  4487  		})
  4488  	}
  4489  	if err != nil {
  4490  		return nil, err
  4491  	}
  4492  	defer googleapi.CloseBody(res)
  4493  	if err := googleapi.CheckResponse(res); err != nil {
  4494  		return nil, gensupport.WrapError(err)
  4495  	}
  4496  	ret := &EffectiveGuestPolicy{
  4497  		ServerResponse: googleapi.ServerResponse{
  4498  			Header:         res.Header,
  4499  			HTTPStatusCode: res.StatusCode,
  4500  		},
  4501  	}
  4502  	target := &ret
  4503  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4504  		return nil, err
  4505  	}
  4506  	return ret, nil
  4507  }
  4508  

View as plain text