1// Copyright 2021 Google LLC.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5// Code generated file. DO NOT EDIT.
6
7// Package ondemandscanning provides access to the On-Demand Scanning API.
8//
9// For product documentation, see: https://cloud.google.com/container-analysis/docs/on-demand-scanning/
10//
11// Creating a client
12//
13// Usage example:
14//
15//   import "google.golang.org/api/ondemandscanning/v1"
16//   ...
17//   ctx := context.Background()
18//   ondemandscanningService, err := ondemandscanning.NewService(ctx)
19//
20// In this example, Google Application Default Credentials are used for authentication.
21//
22// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
23//
24// Other authentication options
25//
26// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
27//
28//   ondemandscanningService, err := ondemandscanning.NewService(ctx, option.WithAPIKey("AIza..."))
29//
30// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
31//
32//   config := &oauth2.Config{...}
33//   // ...
34//   token, err := config.Exchange(ctx, ...)
35//   ondemandscanningService, err := ondemandscanning.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
36//
37// See https://godoc.org/google.golang.org/api/option/ for details on options.
38package ondemandscanning // import "google.golang.org/api/ondemandscanning/v1"
39
40import (
41	"bytes"
42	"context"
43	"encoding/json"
44	"errors"
45	"fmt"
46	"io"
47	"net/http"
48	"net/url"
49	"strconv"
50	"strings"
51
52	googleapi "google.golang.org/api/googleapi"
53	gensupport "google.golang.org/api/internal/gensupport"
54	option "google.golang.org/api/option"
55	internaloption "google.golang.org/api/option/internaloption"
56	htransport "google.golang.org/api/transport/http"
57)
58
59// Always reference these packages, just in case the auto-generated code
60// below doesn't.
61var _ = bytes.NewBuffer
62var _ = strconv.Itoa
63var _ = fmt.Sprintf
64var _ = json.NewDecoder
65var _ = io.Copy
66var _ = url.Parse
67var _ = gensupport.MarshalJSON
68var _ = googleapi.Version
69var _ = errors.New
70var _ = strings.Replace
71var _ = context.Canceled
72var _ = internaloption.WithDefaultEndpoint
73
74const apiId = "ondemandscanning:v1"
75const apiName = "ondemandscanning"
76const apiVersion = "v1"
77const basePath = "https://ondemandscanning.googleapis.com/"
78const mtlsBasePath = "https://ondemandscanning.mtls.googleapis.com/"
79
80// OAuth2 scopes used by this API.
81const (
82	// See, edit, configure, and delete your Google Cloud Platform data
83	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
84)
85
86// NewService creates a new Service.
87func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
88	scopesOption := option.WithScopes(
89		"https://www.googleapis.com/auth/cloud-platform",
90	)
91	// NOTE: prepend, so we don't override user-specified scopes.
92	opts = append([]option.ClientOption{scopesOption}, opts...)
93	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
94	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
95	client, endpoint, err := htransport.NewClient(ctx, opts...)
96	if err != nil {
97		return nil, err
98	}
99	s, err := New(client)
100	if err != nil {
101		return nil, err
102	}
103	if endpoint != "" {
104		s.BasePath = endpoint
105	}
106	return s, nil
107}
108
109// New creates a new Service. It uses the provided http.Client for requests.
110//
111// Deprecated: please use NewService instead.
112// To provide a custom HTTP client, use option.WithHTTPClient.
113// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
114func New(client *http.Client) (*Service, error) {
115	if client == nil {
116		return nil, errors.New("client is nil")
117	}
118	s := &Service{client: client, BasePath: basePath}
119	s.Projects = NewProjectsService(s)
120	return s, nil
121}
122
123type Service struct {
124	client    *http.Client
125	BasePath  string // API endpoint base URL
126	UserAgent string // optional additional User-Agent fragment
127
128	Projects *ProjectsService
129}
130
131func (s *Service) userAgent() string {
132	if s.UserAgent == "" {
133		return googleapi.UserAgent
134	}
135	return googleapi.UserAgent + " " + s.UserAgent
136}
137
138func NewProjectsService(s *Service) *ProjectsService {
139	rs := &ProjectsService{s: s}
140	rs.Locations = NewProjectsLocationsService(s)
141	return rs
142}
143
144type ProjectsService struct {
145	s *Service
146
147	Locations *ProjectsLocationsService
148}
149
150func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
151	rs := &ProjectsLocationsService{s: s}
152	rs.Operations = NewProjectsLocationsOperationsService(s)
153	rs.Scans = NewProjectsLocationsScansService(s)
154	return rs
155}
156
157type ProjectsLocationsService struct {
158	s *Service
159
160	Operations *ProjectsLocationsOperationsService
161
162	Scans *ProjectsLocationsScansService
163}
164
165func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
166	rs := &ProjectsLocationsOperationsService{s: s}
167	return rs
168}
169
170type ProjectsLocationsOperationsService struct {
171	s *Service
172}
173
174func NewProjectsLocationsScansService(s *Service) *ProjectsLocationsScansService {
175	rs := &ProjectsLocationsScansService{s: s}
176	rs.Vulnerabilities = NewProjectsLocationsScansVulnerabilitiesService(s)
177	return rs
178}
179
180type ProjectsLocationsScansService struct {
181	s *Service
182
183	Vulnerabilities *ProjectsLocationsScansVulnerabilitiesService
184}
185
186func NewProjectsLocationsScansVulnerabilitiesService(s *Service) *ProjectsLocationsScansVulnerabilitiesService {
187	rs := &ProjectsLocationsScansVulnerabilitiesService{s: s}
188	return rs
189}
190
191type ProjectsLocationsScansVulnerabilitiesService struct {
192	s *Service
193}
194
195// AliasContext: An alias to a repo revision.
196type AliasContext struct {
197	// Kind: The alias kind.
198	//
199	// Possible values:
200	//   "KIND_UNSPECIFIED" - Unknown.
201	//   "FIXED" - Git tag.
202	//   "MOVABLE" - Git branch.
203	//   "OTHER" - Used to specify non-standard aliases. For example, if a
204	// Git repo has a ref named "refs/foo/bar".
205	Kind string `json:"kind,omitempty"`
206
207	// Name: The alias name.
208	Name string `json:"name,omitempty"`
209
210	// ForceSendFields is a list of field names (e.g. "Kind") to
211	// unconditionally include in API requests. By default, fields with
212	// empty values are omitted from API requests. However, any non-pointer,
213	// non-interface field appearing in ForceSendFields will be sent to the
214	// server regardless of whether the field is empty or not. This may be
215	// used to include empty fields in Patch requests.
216	ForceSendFields []string `json:"-"`
217
218	// NullFields is a list of field names (e.g. "Kind") to include in API
219	// requests with the JSON null value. By default, fields with empty
220	// values are omitted from API requests. However, any field with an
221	// empty value appearing in NullFields will be sent to the server as
222	// null. It is an error if a field in this list has a non-empty value.
223	// This may be used to include null fields in Patch requests.
224	NullFields []string `json:"-"`
225}
226
227func (s *AliasContext) MarshalJSON() ([]byte, error) {
228	type NoMethod AliasContext
229	raw := NoMethod(*s)
230	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
231}
232
233// AnalyzePackagesMetadata: AnalyzePackagesMetadata contains metadata
234// for an active scan of a container image.
235type AnalyzePackagesMetadata struct {
236	// CreateTime: When the scan was created.
237	CreateTime string `json:"createTime,omitempty"`
238
239	// ResourceUri: The resource URI of the container image being scanned.
240	ResourceUri string `json:"resourceUri,omitempty"`
241
242	// ForceSendFields is a list of field names (e.g. "CreateTime") to
243	// unconditionally include in API requests. By default, fields with
244	// empty values are omitted from API requests. However, any non-pointer,
245	// non-interface field appearing in ForceSendFields will be sent to the
246	// server regardless of whether the field is empty or not. This may be
247	// used to include empty fields in Patch requests.
248	ForceSendFields []string `json:"-"`
249
250	// NullFields is a list of field names (e.g. "CreateTime") to include in
251	// API requests with the JSON null value. By default, fields with empty
252	// values are omitted from API requests. However, any field with an
253	// empty value appearing in NullFields will be sent to the server as
254	// null. It is an error if a field in this list has a non-empty value.
255	// This may be used to include null fields in Patch requests.
256	NullFields []string `json:"-"`
257}
258
259func (s *AnalyzePackagesMetadata) MarshalJSON() ([]byte, error) {
260	type NoMethod AnalyzePackagesMetadata
261	raw := NoMethod(*s)
262	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
263}
264
265// AnalyzePackagesMetadataV1: AnalyzePackagesMetadata contains metadata
266// for an active scan of a container image.
267type AnalyzePackagesMetadataV1 struct {
268	// CreateTime: When the scan was created.
269	CreateTime string `json:"createTime,omitempty"`
270
271	// ResourceUri: The resource URI of the container image being scanned.
272	ResourceUri string `json:"resourceUri,omitempty"`
273
274	// ForceSendFields is a list of field names (e.g. "CreateTime") to
275	// unconditionally include in API requests. By default, fields with
276	// empty values are omitted from API requests. However, any non-pointer,
277	// non-interface field appearing in ForceSendFields will be sent to the
278	// server regardless of whether the field is empty or not. This may be
279	// used to include empty fields in Patch requests.
280	ForceSendFields []string `json:"-"`
281
282	// NullFields is a list of field names (e.g. "CreateTime") to include in
283	// API requests with the JSON null value. By default, fields with empty
284	// values are omitted from API requests. However, any field with an
285	// empty value appearing in NullFields will be sent to the server as
286	// null. It is an error if a field in this list has a non-empty value.
287	// This may be used to include null fields in Patch requests.
288	NullFields []string `json:"-"`
289}
290
291func (s *AnalyzePackagesMetadataV1) MarshalJSON() ([]byte, error) {
292	type NoMethod AnalyzePackagesMetadataV1
293	raw := NoMethod(*s)
294	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
295}
296
297// AnalyzePackagesRequestV1: AnalyzePackagesRequest is the request to
298// analyze a list of packages and create Vulnerability Occurrences for
299// it.
300type AnalyzePackagesRequestV1 struct {
301	// Packages: The packages to analyze.
302	Packages []*PackageData `json:"packages,omitempty"`
303
304	// ResourceUri: Required. The resource URI of the container image being
305	// scanned.
306	ResourceUri string `json:"resourceUri,omitempty"`
307
308	// ForceSendFields is a list of field names (e.g. "Packages") to
309	// unconditionally include in API requests. By default, fields with
310	// empty values are omitted from API requests. However, any non-pointer,
311	// non-interface field appearing in ForceSendFields will be sent to the
312	// server regardless of whether the field is empty or not. This may be
313	// used to include empty fields in Patch requests.
314	ForceSendFields []string `json:"-"`
315
316	// NullFields is a list of field names (e.g. "Packages") to include in
317	// API requests with the JSON null value. By default, fields with empty
318	// values are omitted from API requests. However, any field with an
319	// empty value appearing in NullFields will be sent to the server as
320	// null. It is an error if a field in this list has a non-empty value.
321	// This may be used to include null fields in Patch requests.
322	NullFields []string `json:"-"`
323}
324
325func (s *AnalyzePackagesRequestV1) MarshalJSON() ([]byte, error) {
326	type NoMethod AnalyzePackagesRequestV1
327	raw := NoMethod(*s)
328	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
329}
330
331// AnalyzePackagesResponse: AnalyzePackagesResponse contains the
332// information necessary to find results for the given scan.
333type AnalyzePackagesResponse struct {
334	// Scan: The name of the scan resource created by this successful scan.
335	Scan string `json:"scan,omitempty"`
336
337	// ForceSendFields is a list of field names (e.g. "Scan") to
338	// unconditionally include in API requests. By default, fields with
339	// empty values are omitted from API requests. However, any non-pointer,
340	// non-interface field appearing in ForceSendFields will be sent to the
341	// server regardless of whether the field is empty or not. This may be
342	// used to include empty fields in Patch requests.
343	ForceSendFields []string `json:"-"`
344
345	// NullFields is a list of field names (e.g. "Scan") to include in API
346	// requests with the JSON null value. By default, fields with empty
347	// values are omitted from API requests. However, any field with an
348	// empty value appearing in NullFields will be sent to the server as
349	// null. It is an error if a field in this list has a non-empty value.
350	// This may be used to include null fields in Patch requests.
351	NullFields []string `json:"-"`
352}
353
354func (s *AnalyzePackagesResponse) MarshalJSON() ([]byte, error) {
355	type NoMethod AnalyzePackagesResponse
356	raw := NoMethod(*s)
357	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
358}
359
360// AnalyzePackagesResponseV1: AnalyzePackagesResponse contains the
361// information necessary to find results for the given scan.
362type AnalyzePackagesResponseV1 struct {
363	// Scan: The name of the scan resource created by this successful scan.
364	Scan string `json:"scan,omitempty"`
365
366	// ForceSendFields is a list of field names (e.g. "Scan") to
367	// unconditionally include in API requests. By default, fields with
368	// empty values are omitted from API requests. However, any non-pointer,
369	// non-interface field appearing in ForceSendFields will be sent to the
370	// server regardless of whether the field is empty or not. This may be
371	// used to include empty fields in Patch requests.
372	ForceSendFields []string `json:"-"`
373
374	// NullFields is a list of field names (e.g. "Scan") to include in API
375	// requests with the JSON null value. By default, fields with empty
376	// values are omitted from API requests. However, any field with an
377	// empty value appearing in NullFields will be sent to the server as
378	// null. It is an error if a field in this list has a non-empty value.
379	// This may be used to include null fields in Patch requests.
380	NullFields []string `json:"-"`
381}
382
383func (s *AnalyzePackagesResponseV1) MarshalJSON() ([]byte, error) {
384	type NoMethod AnalyzePackagesResponseV1
385	raw := NoMethod(*s)
386	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
387}
388
389// Artifact: Artifact describes a build product.
390type Artifact struct {
391	// Checksum: Hash or checksum value of a binary, or Docker Registry 2.0
392	// digest of a container.
393	Checksum string `json:"checksum,omitempty"`
394
395	// Id: Artifact ID, if any; for container images, this will be a URL by
396	// digest like `gcr.io/projectID/imagename@sha256:123456`.
397	Id string `json:"id,omitempty"`
398
399	// Names: Related artifact names. This may be the path to a binary or
400	// jar file, or in the case of a container build, the name used to push
401	// the container image to Google Container Registry, as presented to
402	// `docker push`. Note that a single Artifact ID can have multiple
403	// names, for example if two tags are applied to one image.
404	Names []string `json:"names,omitempty"`
405
406	// ForceSendFields is a list of field names (e.g. "Checksum") to
407	// unconditionally include in API requests. By default, fields with
408	// empty values are omitted from API requests. However, any non-pointer,
409	// non-interface field appearing in ForceSendFields will be sent to the
410	// server regardless of whether the field is empty or not. This may be
411	// used to include empty fields in Patch requests.
412	ForceSendFields []string `json:"-"`
413
414	// NullFields is a list of field names (e.g. "Checksum") to include in
415	// API requests with the JSON null value. By default, fields with empty
416	// values are omitted from API requests. However, any field with an
417	// empty value appearing in NullFields will be sent to the server as
418	// null. It is an error if a field in this list has a non-empty value.
419	// This may be used to include null fields in Patch requests.
420	NullFields []string `json:"-"`
421}
422
423func (s *Artifact) MarshalJSON() ([]byte, error) {
424	type NoMethod Artifact
425	raw := NoMethod(*s)
426	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
427}
428
429// AttestationOccurrence: Occurrence that represents a single
430// "attestation". The authenticity of an attestation can be verified
431// using the attached signature. If the verifier trusts the public key
432// of the signer, then verifying the signature is sufficient to
433// establish trust. In this circumstance, the authority to which this
434// attestation is attached is primarily useful for lookup (how to find
435// this attestation if you already know the authority and artifact to be
436// verified) and intent (for which authority this attestation was
437// intended to sign.
438type AttestationOccurrence struct {
439	// Jwts: One or more JWTs encoding a self-contained attestation. Each
440	// JWT encodes the payload that it verifies within the JWT itself.
441	// Verifier implementation SHOULD ignore the `serialized_payload` field
442	// when verifying these JWTs. If only JWTs are present on this
443	// AttestationOccurrence, then the `serialized_payload` SHOULD be left
444	// empty. Each JWT SHOULD encode a claim specific to the `resource_uri`
445	// of this Occurrence, but this is not validated by Grafeas metadata API
446	// implementations. The JWT itself is opaque to Grafeas.
447	Jwts []*Jwt `json:"jwts,omitempty"`
448
449	// SerializedPayload: Required. The serialized payload that is verified
450	// by one or more `signatures`.
451	SerializedPayload string `json:"serializedPayload,omitempty"`
452
453	// Signatures: One or more signatures over `serialized_payload`.
454	// Verifier implementations should consider this attestation message
455	// verified if at least one `signature` verifies `serialized_payload`.
456	// See `Signature` in common.proto for more details on signature
457	// structure and verification.
458	Signatures []*Signature `json:"signatures,omitempty"`
459
460	// ForceSendFields is a list of field names (e.g. "Jwts") to
461	// unconditionally include in API requests. By default, fields with
462	// empty values are omitted from API requests. However, any non-pointer,
463	// non-interface field appearing in ForceSendFields will be sent to the
464	// server regardless of whether the field is empty or not. This may be
465	// used to include empty fields in Patch requests.
466	ForceSendFields []string `json:"-"`
467
468	// NullFields is a list of field names (e.g. "Jwts") to include in API
469	// requests with the JSON null value. By default, fields with empty
470	// values are omitted from API requests. However, any field with an
471	// empty value appearing in NullFields will be sent to the server as
472	// null. It is an error if a field in this list has a non-empty value.
473	// This may be used to include null fields in Patch requests.
474	NullFields []string `json:"-"`
475}
476
477func (s *AttestationOccurrence) MarshalJSON() ([]byte, error) {
478	type NoMethod AttestationOccurrence
479	raw := NoMethod(*s)
480	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
481}
482
483// BuildOccurrence: Details of a build occurrence.
484type BuildOccurrence struct {
485	// Provenance: Required. The actual provenance for the build.
486	Provenance *BuildProvenance `json:"provenance,omitempty"`
487
488	// ProvenanceBytes: Serialized JSON representation of the provenance,
489	// used in generating the build signature in the corresponding build
490	// note. After verifying the signature, `provenance_bytes` can be
491	// unmarshalled and compared to the provenance to confirm that it is
492	// unchanged. A base64-encoded string representation of the provenance
493	// bytes is used for the signature in order to interoperate with openssl
494	// which expects this format for signature verification. The serialized
495	// form is captured both to avoid ambiguity in how the provenance is
496	// marshalled to json as well to prevent incompatibilities with future
497	// changes.
498	ProvenanceBytes string `json:"provenanceBytes,omitempty"`
499
500	// ForceSendFields is a list of field names (e.g. "Provenance") to
501	// unconditionally include in API requests. By default, fields with
502	// empty values are omitted from API requests. However, any non-pointer,
503	// non-interface field appearing in ForceSendFields will be sent to the
504	// server regardless of whether the field is empty or not. This may be
505	// used to include empty fields in Patch requests.
506	ForceSendFields []string `json:"-"`
507
508	// NullFields is a list of field names (e.g. "Provenance") to include in
509	// API requests with the JSON null value. By default, fields with empty
510	// values are omitted from API requests. However, any field with an
511	// empty value appearing in NullFields will be sent to the server as
512	// null. It is an error if a field in this list has a non-empty value.
513	// This may be used to include null fields in Patch requests.
514	NullFields []string `json:"-"`
515}
516
517func (s *BuildOccurrence) MarshalJSON() ([]byte, error) {
518	type NoMethod BuildOccurrence
519	raw := NoMethod(*s)
520	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
521}
522
523// BuildProvenance: Provenance of a build. Contains all information
524// needed to verify the full details about the build from source to
525// completion.
526type BuildProvenance struct {
527	// BuildOptions: Special options applied to this build. This is a
528	// catch-all field where build providers can enter any desired
529	// additional details.
530	BuildOptions map[string]string `json:"buildOptions,omitempty"`
531
532	// BuilderVersion: Version string of the builder at the time this build
533	// was executed.
534	BuilderVersion string `json:"builderVersion,omitempty"`
535
536	// BuiltArtifacts: Output of the build.
537	BuiltArtifacts []*Artifact `json:"builtArtifacts,omitempty"`
538
539	// Commands: Commands requested by the build.
540	Commands []*Command `json:"commands,omitempty"`
541
542	// CreateTime: Time at which the build was created.
543	CreateTime string `json:"createTime,omitempty"`
544
545	// Creator: E-mail address of the user who initiated this build. Note
546	// that this was the user's e-mail address at the time the build was
547	// initiated; this address may not represent the same end-user for all
548	// time.
549	Creator string `json:"creator,omitempty"`
550
551	// EndTime: Time at which execution of the build was finished.
552	EndTime string `json:"endTime,omitempty"`
553
554	// Id: Required. Unique identifier of the build.
555	Id string `json:"id,omitempty"`
556
557	// LogsUri: URI where any logs for this provenance were written.
558	LogsUri string `json:"logsUri,omitempty"`
559
560	// ProjectId: ID of the project.
561	ProjectId string `json:"projectId,omitempty"`
562
563	// SourceProvenance: Details of the Source input to the build.
564	SourceProvenance *Source `json:"sourceProvenance,omitempty"`
565
566	// StartTime: Time at which execution of the build was started.
567	StartTime string `json:"startTime,omitempty"`
568
569	// TriggerId: Trigger identifier if the build was triggered
570	// automatically; empty if not.
571	TriggerId string `json:"triggerId,omitempty"`
572
573	// ForceSendFields is a list of field names (e.g. "BuildOptions") to
574	// unconditionally include in API requests. By default, fields with
575	// empty values are omitted from API requests. However, any non-pointer,
576	// non-interface field appearing in ForceSendFields will be sent to the
577	// server regardless of whether the field is empty or not. This may be
578	// used to include empty fields in Patch requests.
579	ForceSendFields []string `json:"-"`
580
581	// NullFields is a list of field names (e.g. "BuildOptions") to include
582	// in API requests with the JSON null value. By default, fields with
583	// empty values are omitted from API requests. However, any field with
584	// an empty value appearing in NullFields will be sent to the server as
585	// null. It is an error if a field in this list has a non-empty value.
586	// This may be used to include null fields in Patch requests.
587	NullFields []string `json:"-"`
588}
589
590func (s *BuildProvenance) MarshalJSON() ([]byte, error) {
591	type NoMethod BuildProvenance
592	raw := NoMethod(*s)
593	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
594}
595
596// Category: The category to which the update belongs.
597type Category struct {
598	// CategoryId: The identifier of the category.
599	CategoryId string `json:"categoryId,omitempty"`
600
601	// Name: The localized name of the category.
602	Name string `json:"name,omitempty"`
603
604	// ForceSendFields is a list of field names (e.g. "CategoryId") to
605	// unconditionally include in API requests. By default, fields with
606	// empty values are omitted from API requests. However, any non-pointer,
607	// non-interface field appearing in ForceSendFields will be sent to the
608	// server regardless of whether the field is empty or not. This may be
609	// used to include empty fields in Patch requests.
610	ForceSendFields []string `json:"-"`
611
612	// NullFields is a list of field names (e.g. "CategoryId") to include in
613	// API requests with the JSON null value. By default, fields with empty
614	// values are omitted from API requests. However, any field with an
615	// empty value appearing in NullFields will be sent to the server as
616	// null. It is an error if a field in this list has a non-empty value.
617	// This may be used to include null fields in Patch requests.
618	NullFields []string `json:"-"`
619}
620
621func (s *Category) MarshalJSON() ([]byte, error) {
622	type NoMethod Category
623	raw := NoMethod(*s)
624	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
625}
626
627// CloudRepoSourceContext: A CloudRepoSourceContext denotes a particular
628// revision in a Google Cloud Source Repo.
629type CloudRepoSourceContext struct {
630	// AliasContext: An alias, which may be a branch or tag.
631	AliasContext *AliasContext `json:"aliasContext,omitempty"`
632
633	// RepoId: The ID of the repo.
634	RepoId *RepoId `json:"repoId,omitempty"`
635
636	// RevisionId: A revision ID.
637	RevisionId string `json:"revisionId,omitempty"`
638
639	// ForceSendFields is a list of field names (e.g. "AliasContext") to
640	// unconditionally include in API requests. By default, fields with
641	// empty values are omitted from API requests. However, any non-pointer,
642	// non-interface field appearing in ForceSendFields will be sent to the
643	// server regardless of whether the field is empty or not. This may be
644	// used to include empty fields in Patch requests.
645	ForceSendFields []string `json:"-"`
646
647	// NullFields is a list of field names (e.g. "AliasContext") to include
648	// in API requests with the JSON null value. By default, fields with
649	// empty values are omitted from API requests. However, any field with
650	// an empty value appearing in NullFields will be sent to the server as
651	// null. It is an error if a field in this list has a non-empty value.
652	// This may be used to include null fields in Patch requests.
653	NullFields []string `json:"-"`
654}
655
656func (s *CloudRepoSourceContext) MarshalJSON() ([]byte, error) {
657	type NoMethod CloudRepoSourceContext
658	raw := NoMethod(*s)
659	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
660}
661
662// Command: Command describes a step performed as part of the build
663// pipeline.
664type Command struct {
665	// Args: Command-line arguments used when executing this command.
666	Args []string `json:"args,omitempty"`
667
668	// Dir: Working directory (relative to project source root) used when
669	// running this command.
670	Dir string `json:"dir,omitempty"`
671
672	// Env: Environment variables set before running this command.
673	Env []string `json:"env,omitempty"`
674
675	// Id: Optional unique identifier for this command, used in wait_for to
676	// reference this command as a dependency.
677	Id string `json:"id,omitempty"`
678
679	// Name: Required. Name of the command, as presented on the command
680	// line, or if the command is packaged as a Docker container, as
681	// presented to `docker pull`.
682	Name string `json:"name,omitempty"`
683
684	// WaitFor: The ID(s) of the command(s) that this command depends on.
685	WaitFor []string `json:"waitFor,omitempty"`
686
687	// ForceSendFields is a list of field names (e.g. "Args") to
688	// unconditionally include in API requests. By default, fields with
689	// empty values are omitted from API requests. However, any non-pointer,
690	// non-interface field appearing in ForceSendFields will be sent to the
691	// server regardless of whether the field is empty or not. This may be
692	// used to include empty fields in Patch requests.
693	ForceSendFields []string `json:"-"`
694
695	// NullFields is a list of field names (e.g. "Args") to include in API
696	// requests with the JSON null value. By default, fields with empty
697	// values are omitted from API requests. However, any field with an
698	// empty value appearing in NullFields will be sent to the server as
699	// null. It is an error if a field in this list has a non-empty value.
700	// This may be used to include null fields in Patch requests.
701	NullFields []string `json:"-"`
702}
703
704func (s *Command) MarshalJSON() ([]byte, error) {
705	type NoMethod Command
706	raw := NoMethod(*s)
707	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
708}
709
710// DeploymentOccurrence: The period during which some deployable was
711// active in a runtime.
712type DeploymentOccurrence struct {
713	// Address: Address of the runtime element hosting this deployment.
714	Address string `json:"address,omitempty"`
715
716	// Config: Configuration used to create this deployment.
717	Config string `json:"config,omitempty"`
718
719	// DeployTime: Required. Beginning of the lifetime of this deployment.
720	DeployTime string `json:"deployTime,omitempty"`
721
722	// Platform: Platform hosting this deployment.
723	//
724	// Possible values:
725	//   "PLATFORM_UNSPECIFIED" - Unknown.
726	//   "GKE" - Google Container Engine.
727	//   "FLEX" - Google App Engine: Flexible Environment.
728	//   "CUSTOM" - Custom user-defined platform.
729	Platform string `json:"platform,omitempty"`
730
731	// ResourceUri: Output only. Resource URI for the artifact being
732	// deployed taken from the deployable field with the same name.
733	ResourceUri []string `json:"resourceUri,omitempty"`
734
735	// UndeployTime: End of the lifetime of this deployment.
736	UndeployTime string `json:"undeployTime,omitempty"`
737
738	// UserEmail: Identity of the user that triggered this deployment.
739	UserEmail string `json:"userEmail,omitempty"`
740
741	// ForceSendFields is a list of field names (e.g. "Address") to
742	// unconditionally include in API requests. By default, fields with
743	// empty values are omitted from API requests. However, any non-pointer,
744	// non-interface field appearing in ForceSendFields will be sent to the
745	// server regardless of whether the field is empty or not. This may be
746	// used to include empty fields in Patch requests.
747	ForceSendFields []string `json:"-"`
748
749	// NullFields is a list of field names (e.g. "Address") to include in
750	// API requests with the JSON null value. By default, fields with empty
751	// values are omitted from API requests. However, any field with an
752	// empty value appearing in NullFields will be sent to the server as
753	// null. It is an error if a field in this list has a non-empty value.
754	// This may be used to include null fields in Patch requests.
755	NullFields []string `json:"-"`
756}
757
758func (s *DeploymentOccurrence) MarshalJSON() ([]byte, error) {
759	type NoMethod DeploymentOccurrence
760	raw := NoMethod(*s)
761	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
762}
763
764// DiscoveryOccurrence: Provides information about the analysis status
765// of a discovered resource.
766type DiscoveryOccurrence struct {
767	// AnalysisStatus: The status of discovery for the resource.
768	//
769	// Possible values:
770	//   "ANALYSIS_STATUS_UNSPECIFIED" - Unknown.
771	//   "PENDING" - Resource is known but no action has been taken yet.
772	//   "SCANNING" - Resource is being analyzed.
773	//   "FINISHED_SUCCESS" - Analysis has finished successfully.
774	//   "FINISHED_FAILED" - Analysis has finished unsuccessfully, the
775	// analysis itself is in a bad state.
776	//   "FINISHED_UNSUPPORTED" - The resource is known not to be supported
777	AnalysisStatus string `json:"analysisStatus,omitempty"`
778
779	// AnalysisStatusError: When an error is encountered this will contain a
780	// LocalizedMessage under details to show to the user. The
781	// LocalizedMessage is output only and populated by the API.
782	AnalysisStatusError *Status `json:"analysisStatusError,omitempty"`
783
784	// ContinuousAnalysis: Whether the resource is continuously analyzed.
785	//
786	// Possible values:
787	//   "CONTINUOUS_ANALYSIS_UNSPECIFIED" - Unknown.
788	//   "ACTIVE" - The resource is continuously analyzed.
789	//   "INACTIVE" - The resource is ignored for continuous analysis.
790	ContinuousAnalysis string `json:"continuousAnalysis,omitempty"`
791
792	// Cpe: The CPE of the resource being scanned.
793	Cpe string `json:"cpe,omitempty"`
794
795	// LastScanTime: The last time this resource was scanned.
796	LastScanTime string `json:"lastScanTime,omitempty"`
797
798	// ForceSendFields is a list of field names (e.g. "AnalysisStatus") to
799	// unconditionally include in API requests. By default, fields with
800	// empty values are omitted from API requests. However, any non-pointer,
801	// non-interface field appearing in ForceSendFields will be sent to the
802	// server regardless of whether the field is empty or not. This may be
803	// used to include empty fields in Patch requests.
804	ForceSendFields []string `json:"-"`
805
806	// NullFields is a list of field names (e.g. "AnalysisStatus") to
807	// include in API requests with the JSON null value. By default, fields
808	// with empty values are omitted from API requests. However, any field
809	// with an empty value appearing in NullFields will be sent to the
810	// server as null. It is an error if a field in this list has a
811	// non-empty value. This may be used to include null fields in Patch
812	// requests.
813	NullFields []string `json:"-"`
814}
815
816func (s *DiscoveryOccurrence) MarshalJSON() ([]byte, error) {
817	type NoMethod DiscoveryOccurrence
818	raw := NoMethod(*s)
819	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
820}
821
822// Empty: A generic empty message that you can re-use to avoid defining
823// duplicated empty messages in your APIs. A typical example is to use
824// it as the request or the response type of an API method. For
825// instance: service Foo { rpc Bar(google.protobuf.Empty) returns
826// (google.protobuf.Empty); } The JSON representation for `Empty` is
827// empty JSON object `{}`.
828type Empty struct {
829	// ServerResponse contains the HTTP response code and headers from the
830	// server.
831	googleapi.ServerResponse `json:"-"`
832}
833
834// FileHashes: Container message for hashes of byte content of files,
835// used in source messages to verify integrity of source input to the
836// build.
837type FileHashes struct {
838	// FileHash: Required. Collection of file hashes.
839	FileHash []*Hash `json:"fileHash,omitempty"`
840
841	// ForceSendFields is a list of field names (e.g. "FileHash") to
842	// unconditionally include in API requests. By default, fields with
843	// empty values are omitted from API requests. However, any non-pointer,
844	// non-interface field appearing in ForceSendFields will be sent to the
845	// server regardless of whether the field is empty or not. This may be
846	// used to include empty fields in Patch requests.
847	ForceSendFields []string `json:"-"`
848
849	// NullFields is a list of field names (e.g. "FileHash") to include in
850	// API requests with the JSON null value. By default, fields with empty
851	// values are omitted from API requests. However, any field with an
852	// empty value appearing in NullFields will be sent to the server as
853	// null. It is an error if a field in this list has a non-empty value.
854	// This may be used to include null fields in Patch requests.
855	NullFields []string `json:"-"`
856}
857
858func (s *FileHashes) MarshalJSON() ([]byte, error) {
859	type NoMethod FileHashes
860	raw := NoMethod(*s)
861	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
862}
863
864// Fingerprint: A set of properties that uniquely identify a given
865// Docker image.
866type Fingerprint struct {
867	// V1Name: Required. The layer ID of the final layer in the Docker
868	// image's v1 representation.
869	V1Name string `json:"v1Name,omitempty"`
870
871	// V2Blob: Required. The ordered list of v2 blobs that represent a given
872	// image.
873	V2Blob []string `json:"v2Blob,omitempty"`
874
875	// V2Name: Output only. The name of the image's v2 blobs computed via:
876	// [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1])
877	// Only the name of the final blob is kept.
878	V2Name string `json:"v2Name,omitempty"`
879
880	// ForceSendFields is a list of field names (e.g. "V1Name") to
881	// unconditionally include in API requests. By default, fields with
882	// empty values are omitted from API requests. However, any non-pointer,
883	// non-interface field appearing in ForceSendFields will be sent to the
884	// server regardless of whether the field is empty or not. This may be
885	// used to include empty fields in Patch requests.
886	ForceSendFields []string `json:"-"`
887
888	// NullFields is a list of field names (e.g. "V1Name") to include in API
889	// requests with the JSON null value. By default, fields with empty
890	// values are omitted from API requests. However, any field with an
891	// empty value appearing in NullFields will be sent to the server as
892	// null. It is an error if a field in this list has a non-empty value.
893	// This may be used to include null fields in Patch requests.
894	NullFields []string `json:"-"`
895}
896
897func (s *Fingerprint) MarshalJSON() ([]byte, error) {
898	type NoMethod Fingerprint
899	raw := NoMethod(*s)
900	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
901}
902
903// GerritSourceContext: A SourceContext referring to a Gerrit project.
904type GerritSourceContext struct {
905	// AliasContext: An alias, which may be a branch or tag.
906	AliasContext *AliasContext `json:"aliasContext,omitempty"`
907
908	// GerritProject: The full project name within the host. Projects may be
909	// nested, so "project/subproject" is a valid project name. The "repo
910	// name" is the hostURI/project.
911	GerritProject string `json:"gerritProject,omitempty"`
912
913	// HostUri: The URI of a running Gerrit instance.
914	HostUri string `json:"hostUri,omitempty"`
915
916	// RevisionId: A revision (commit) ID.
917	RevisionId string `json:"revisionId,omitempty"`
918
919	// ForceSendFields is a list of field names (e.g. "AliasContext") to
920	// unconditionally include in API requests. By default, fields with
921	// empty values are omitted from API requests. However, any non-pointer,
922	// non-interface field appearing in ForceSendFields will be sent to the
923	// server regardless of whether the field is empty or not. This may be
924	// used to include empty fields in Patch requests.
925	ForceSendFields []string `json:"-"`
926
927	// NullFields is a list of field names (e.g. "AliasContext") to include
928	// in API requests with the JSON null value. By default, fields with
929	// empty values are omitted from API requests. However, any field with
930	// an empty value appearing in NullFields will be sent to the server as
931	// null. It is an error if a field in this list has a non-empty value.
932	// This may be used to include null fields in Patch requests.
933	NullFields []string `json:"-"`
934}
935
936func (s *GerritSourceContext) MarshalJSON() ([]byte, error) {
937	type NoMethod GerritSourceContext
938	raw := NoMethod(*s)
939	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
940}
941
942// GitSourceContext: A GitSourceContext denotes a particular revision in
943// a third party Git repository (e.g., GitHub).
944type GitSourceContext struct {
945	// RevisionId: Git commit hash.
946	RevisionId string `json:"revisionId,omitempty"`
947
948	// Url: Git repository URL.
949	Url string `json:"url,omitempty"`
950
951	// ForceSendFields is a list of field names (e.g. "RevisionId") to
952	// unconditionally include in API requests. By default, fields with
953	// empty values are omitted from API requests. However, any non-pointer,
954	// non-interface field appearing in ForceSendFields will be sent to the
955	// server regardless of whether the field is empty or not. This may be
956	// used to include empty fields in Patch requests.
957	ForceSendFields []string `json:"-"`
958
959	// NullFields is a list of field names (e.g. "RevisionId") to include in
960	// API requests with the JSON null value. By default, fields with empty
961	// values are omitted from API requests. However, any field with an
962	// empty value appearing in NullFields will be sent to the server as
963	// null. It is an error if a field in this list has a non-empty value.
964	// This may be used to include null fields in Patch requests.
965	NullFields []string `json:"-"`
966}
967
968func (s *GitSourceContext) MarshalJSON() ([]byte, error) {
969	type NoMethod GitSourceContext
970	raw := NoMethod(*s)
971	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
972}
973
974// Hash: Container message for hash values.
975type Hash struct {
976	// Type: Required. The type of hash that was performed, e.g. "SHA-256".
977	Type string `json:"type,omitempty"`
978
979	// Value: Required. The hash value.
980	Value string `json:"value,omitempty"`
981
982	// ForceSendFields is a list of field names (e.g. "Type") to
983	// unconditionally include in API requests. By default, fields with
984	// empty values are omitted from API requests. However, any non-pointer,
985	// non-interface field appearing in ForceSendFields will be sent to the
986	// server regardless of whether the field is empty or not. This may be
987	// used to include empty fields in Patch requests.
988	ForceSendFields []string `json:"-"`
989
990	// NullFields is a list of field names (e.g. "Type") to include in API
991	// requests with the JSON null value. By default, fields with empty
992	// values are omitted from API requests. However, any field with an
993	// empty value appearing in NullFields will be sent to the server as
994	// null. It is an error if a field in this list has a non-empty value.
995	// This may be used to include null fields in Patch requests.
996	NullFields []string `json:"-"`
997}
998
999func (s *Hash) MarshalJSON() ([]byte, error) {
1000	type NoMethod Hash
1001	raw := NoMethod(*s)
1002	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1003}
1004
1005// Identity: The unique identifier of the update.
1006type Identity struct {
1007	// Revision: The revision number of the update.
1008	Revision int64 `json:"revision,omitempty"`
1009
1010	// UpdateId: The revision independent identifier of the update.
1011	UpdateId string `json:"updateId,omitempty"`
1012
1013	// ForceSendFields is a list of field names (e.g. "Revision") to
1014	// unconditionally include in API requests. By default, fields with
1015	// empty values are omitted from API requests. However, any non-pointer,
1016	// non-interface field appearing in ForceSendFields will be sent to the
1017	// server regardless of whether the field is empty or not. This may be
1018	// used to include empty fields in Patch requests.
1019	ForceSendFields []string `json:"-"`
1020
1021	// NullFields is a list of field names (e.g. "Revision") to include in
1022	// API requests with the JSON null value. By default, fields with empty
1023	// values are omitted from API requests. However, any field with an
1024	// empty value appearing in NullFields will be sent to the server as
1025	// null. It is an error if a field in this list has a non-empty value.
1026	// This may be used to include null fields in Patch requests.
1027	NullFields []string `json:"-"`
1028}
1029
1030func (s *Identity) MarshalJSON() ([]byte, error) {
1031	type NoMethod Identity
1032	raw := NoMethod(*s)
1033	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1034}
1035
1036// ImageOccurrence: Details of the derived image portion of the
1037// DockerImage relationship. This image would be produced from a
1038// Dockerfile with FROM .
1039type ImageOccurrence struct {
1040	// BaseResourceUrl: Output only. This contains the base image URL for
1041	// the derived image occurrence.
1042	BaseResourceUrl string `json:"baseResourceUrl,omitempty"`
1043
1044	// Distance: Output only. The number of layers by which this image
1045	// differs from the associated image basis.
1046	Distance int64 `json:"distance,omitempty"`
1047
1048	// Fingerprint: Required. The fingerprint of the derived image.
1049	Fingerprint *Fingerprint `json:"fingerprint,omitempty"`
1050
1051	// LayerInfo: This contains layer-specific metadata, if populated it has
1052	// length "distance" and is ordered with [distance] being the layer
1053	// immediately following the base image and [1] being the final layer.
1054	LayerInfo []*Layer `json:"layerInfo,omitempty"`
1055
1056	// ForceSendFields is a list of field names (e.g. "BaseResourceUrl") to
1057	// unconditionally include in API requests. By default, fields with
1058	// empty values are omitted from API requests. However, any non-pointer,
1059	// non-interface field appearing in ForceSendFields will be sent to the
1060	// server regardless of whether the field is empty or not. This may be
1061	// used to include empty fields in Patch requests.
1062	ForceSendFields []string `json:"-"`
1063
1064	// NullFields is a list of field names (e.g. "BaseResourceUrl") to
1065	// include in API requests with the JSON null value. By default, fields
1066	// with empty values are omitted from API requests. However, any field
1067	// with an empty value appearing in NullFields will be sent to the
1068	// server as null. It is an error if a field in this list has a
1069	// non-empty value. This may be used to include null fields in Patch
1070	// requests.
1071	NullFields []string `json:"-"`
1072}
1073
1074func (s *ImageOccurrence) MarshalJSON() ([]byte, error) {
1075	type NoMethod ImageOccurrence
1076	raw := NoMethod(*s)
1077	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1078}
1079
1080type Jwt struct {
1081	// CompactJwt: The compact encoding of a JWS, which is always three
1082	// base64 encoded strings joined by periods. For details, see:
1083	// https://tools.ietf.org/html/rfc7515.html#section-3.1
1084	CompactJwt string `json:"compactJwt,omitempty"`
1085
1086	// ForceSendFields is a list of field names (e.g. "CompactJwt") to
1087	// unconditionally include in API requests. By default, fields with
1088	// empty values are omitted from API requests. However, any non-pointer,
1089	// non-interface field appearing in ForceSendFields will be sent to the
1090	// server regardless of whether the field is empty or not. This may be
1091	// used to include empty fields in Patch requests.
1092	ForceSendFields []string `json:"-"`
1093
1094	// NullFields is a list of field names (e.g. "CompactJwt") to include in
1095	// API requests with the JSON null value. By default, fields with empty
1096	// values are omitted from API requests. However, any field with an
1097	// empty value appearing in NullFields will be sent to the server as
1098	// null. It is an error if a field in this list has a non-empty value.
1099	// This may be used to include null fields in Patch requests.
1100	NullFields []string `json:"-"`
1101}
1102
1103func (s *Jwt) MarshalJSON() ([]byte, error) {
1104	type NoMethod Jwt
1105	raw := NoMethod(*s)
1106	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1107}
1108
1109// Layer: Layer holds metadata specific to a layer of a Docker image.
1110type Layer struct {
1111	// Arguments: The recovered arguments to the Dockerfile directive.
1112	Arguments string `json:"arguments,omitempty"`
1113
1114	// Directive: Required. The recovered Dockerfile directive used to
1115	// construct this layer. See
1116	// https://docs.docker.com/engine/reference/builder/ for more
1117	// information.
1118	Directive string `json:"directive,omitempty"`
1119
1120	// ForceSendFields is a list of field names (e.g. "Arguments") to
1121	// unconditionally include in API requests. By default, fields with
1122	// empty values are omitted from API requests. However, any non-pointer,
1123	// non-interface field appearing in ForceSendFields will be sent to the
1124	// server regardless of whether the field is empty or not. This may be
1125	// used to include empty fields in Patch requests.
1126	ForceSendFields []string `json:"-"`
1127
1128	// NullFields is a list of field names (e.g. "Arguments") to include in
1129	// API requests with the JSON null value. By default, fields with empty
1130	// values are omitted from API requests. However, any field with an
1131	// empty value appearing in NullFields will be sent to the server as
1132	// null. It is an error if a field in this list has a non-empty value.
1133	// This may be used to include null fields in Patch requests.
1134	NullFields []string `json:"-"`
1135}
1136
1137func (s *Layer) MarshalJSON() ([]byte, error) {
1138	type NoMethod Layer
1139	raw := NoMethod(*s)
1140	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1141}
1142
1143// ListOperationsResponse: The response message for
1144// Operations.ListOperations.
1145type ListOperationsResponse struct {
1146	// NextPageToken: The standard List next-page token.
1147	NextPageToken string `json:"nextPageToken,omitempty"`
1148
1149	// Operations: A list of operations that matches the specified filter in
1150	// the request.
1151	Operations []*Operation `json:"operations,omitempty"`
1152
1153	// ServerResponse contains the HTTP response code and headers from the
1154	// server.
1155	googleapi.ServerResponse `json:"-"`
1156
1157	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
1158	// unconditionally include in API requests. By default, fields with
1159	// empty values are omitted from API requests. However, any non-pointer,
1160	// non-interface field appearing in ForceSendFields will be sent to the
1161	// server regardless of whether the field is empty or not. This may be
1162	// used to include empty fields in Patch requests.
1163	ForceSendFields []string `json:"-"`
1164
1165	// NullFields is a list of field names (e.g. "NextPageToken") to include
1166	// in API requests with the JSON null value. By default, fields with
1167	// empty values are omitted from API requests. However, any field with
1168	// an empty value appearing in NullFields will be sent to the server as
1169	// null. It is an error if a field in this list has a non-empty value.
1170	// This may be used to include null fields in Patch requests.
1171	NullFields []string `json:"-"`
1172}
1173
1174func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
1175	type NoMethod ListOperationsResponse
1176	raw := NoMethod(*s)
1177	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1178}
1179
1180// ListVulnerabilitiesResponseV1: ListVulnerabilitiesResponse contains a
1181// single page of vulnerabilities resulting from a scan.
1182type ListVulnerabilitiesResponseV1 struct {
1183	// NextPageToken: A page token that can be used in a subsequent call to
1184	// ListVulnerabilities to continue retrieving results.
1185	NextPageToken string `json:"nextPageToken,omitempty"`
1186
1187	// Occurrences: The list of Vulnerability Occurrences resulting from a
1188	// scan.
1189	Occurrences []*Occurrence `json:"occurrences,omitempty"`
1190
1191	// ServerResponse contains the HTTP response code and headers from the
1192	// server.
1193	googleapi.ServerResponse `json:"-"`
1194
1195	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
1196	// unconditionally include in API requests. By default, fields with
1197	// empty values are omitted from API requests. However, any non-pointer,
1198	// non-interface field appearing in ForceSendFields will be sent to the
1199	// server regardless of whether the field is empty or not. This may be
1200	// used to include empty fields in Patch requests.
1201	ForceSendFields []string `json:"-"`
1202
1203	// NullFields is a list of field names (e.g. "NextPageToken") to include
1204	// in API requests with the JSON null value. By default, fields with
1205	// empty values are omitted from API requests. However, any field with
1206	// an empty value appearing in NullFields will be sent to the server as
1207	// null. It is an error if a field in this list has a non-empty value.
1208	// This may be used to include null fields in Patch requests.
1209	NullFields []string `json:"-"`
1210}
1211
1212func (s *ListVulnerabilitiesResponseV1) MarshalJSON() ([]byte, error) {
1213	type NoMethod ListVulnerabilitiesResponseV1
1214	raw := NoMethod(*s)
1215	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1216}
1217
1218// Location: An occurrence of a particular package installation found
1219// within a system's filesystem. E.g., glibc was found in
1220// `/var/lib/dpkg/status`.
1221type Location struct {
1222	// CpeUri: Required. The CPE URI in CPE format
1223	// (https://cpe.mitre.org/specification/) denoting the package manager
1224	// version distributing a package.
1225	CpeUri string `json:"cpeUri,omitempty"`
1226
1227	// Path: The path from which we gathered that this package/version is
1228	// installed.
1229	Path string `json:"path,omitempty"`
1230
1231	// Version: The version installed at this location.
1232	Version *Version `json:"version,omitempty"`
1233
1234	// ForceSendFields is a list of field names (e.g. "CpeUri") to
1235	// unconditionally include in API requests. By default, fields with
1236	// empty values are omitted from API requests. However, any non-pointer,
1237	// non-interface field appearing in ForceSendFields will be sent to the
1238	// server regardless of whether the field is empty or not. This may be
1239	// used to include empty fields in Patch requests.
1240	ForceSendFields []string `json:"-"`
1241
1242	// NullFields is a list of field names (e.g. "CpeUri") to include in API
1243	// requests with the JSON null value. By default, fields with empty
1244	// values are omitted from API requests. However, any field with an
1245	// empty value appearing in NullFields will be sent to the server as
1246	// null. It is an error if a field in this list has a non-empty value.
1247	// This may be used to include null fields in Patch requests.
1248	NullFields []string `json:"-"`
1249}
1250
1251func (s *Location) MarshalJSON() ([]byte, error) {
1252	type NoMethod Location
1253	raw := NoMethod(*s)
1254	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1255}
1256
1257// Occurrence: An instance of an analysis type that has been found on a
1258// resource.
1259type Occurrence struct {
1260	// Attestation: Describes an attestation of an artifact.
1261	Attestation *AttestationOccurrence `json:"attestation,omitempty"`
1262
1263	// Build: Describes a verifiable build.
1264	Build *BuildOccurrence `json:"build,omitempty"`
1265
1266	// CreateTime: Output only. The time this occurrence was created.
1267	CreateTime string `json:"createTime,omitempty"`
1268
1269	// Deployment: Describes the deployment of an artifact on a runtime.
1270	Deployment *DeploymentOccurrence `json:"deployment,omitempty"`
1271
1272	// Discovery: Describes when a resource was discovered.
1273	Discovery *DiscoveryOccurrence `json:"discovery,omitempty"`
1274
1275	// Image: Describes how this resource derives from the basis in the
1276	// associated note.
1277	Image *ImageOccurrence `json:"image,omitempty"`
1278
1279	// Kind: Output only. This explicitly denotes which of the occurrence
1280	// details are specified. This field can be used as a filter in list
1281	// requests.
1282	//
1283	// Possible values:
1284	//   "NOTE_KIND_UNSPECIFIED" - Default value. This value is unused.
1285	//   "VULNERABILITY" - The note and occurrence represent a package
1286	// vulnerability.
1287	//   "BUILD" - The note and occurrence assert build provenance.
1288	//   "IMAGE" - This represents an image basis relationship.
1289	//   "PACKAGE" - This represents a package installed via a package
1290	// manager.
1291	//   "DEPLOYMENT" - The note and occurrence track deployment events.
1292	//   "DISCOVERY" - The note and occurrence track the initial discovery
1293	// status of a resource.
1294	//   "ATTESTATION" - This represents a logical "role" that can attest to
1295	// artifacts.
1296	//   "UPGRADE" - This represents an available package upgrade.
1297	Kind string `json:"kind,omitempty"`
1298
1299	// Name: Output only. The name of the occurrence in the form of
1300	// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
1301	Name string `json:"name,omitempty"`
1302
1303	// NoteName: Required. Immutable. The analysis note associated with this
1304	// occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
1305	// This field can be used as a filter in list requests.
1306	NoteName string `json:"noteName,omitempty"`
1307
1308	// Package: Describes the installation of a package on the linked
1309	// resource.
1310	Package *PackageOccurrence `json:"package,omitempty"`
1311
1312	// Remediation: A description of actions that can be taken to remedy the
1313	// note.
1314	Remediation string `json:"remediation,omitempty"`
1315
1316	// ResourceUri: Required. Immutable. A URI that represents the resource
1317	// for which the occurrence applies. For example,
1318	// `https://gcr.io/project/image@sha256:123abc` for a Docker image.
1319	ResourceUri string `json:"resourceUri,omitempty"`
1320
1321	// UpdateTime: Output only. The time this occurrence was last updated.
1322	UpdateTime string `json:"updateTime,omitempty"`
1323
1324	// Upgrade: Describes an available package upgrade on the linked
1325	// resource.
1326	Upgrade *UpgradeOccurrence `json:"upgrade,omitempty"`
1327
1328	// Vulnerability: Describes a security vulnerability.
1329	Vulnerability *VulnerabilityOccurrence `json:"vulnerability,omitempty"`
1330
1331	// ForceSendFields is a list of field names (e.g. "Attestation") to
1332	// unconditionally include in API requests. By default, fields with
1333	// empty values are omitted from API requests. However, any non-pointer,
1334	// non-interface field appearing in ForceSendFields will be sent to the
1335	// server regardless of whether the field is empty or not. This may be
1336	// used to include empty fields in Patch requests.
1337	ForceSendFields []string `json:"-"`
1338
1339	// NullFields is a list of field names (e.g. "Attestation") to include
1340	// in API requests with the JSON null value. By default, fields with
1341	// empty values are omitted from API requests. However, any field with
1342	// an empty value appearing in NullFields will be sent to the server as
1343	// null. It is an error if a field in this list has a non-empty value.
1344	// This may be used to include null fields in Patch requests.
1345	NullFields []string `json:"-"`
1346}
1347
1348func (s *Occurrence) MarshalJSON() ([]byte, error) {
1349	type NoMethod Occurrence
1350	raw := NoMethod(*s)
1351	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1352}
1353
1354// Operation: This resource represents a long-running operation that is
1355// the result of a network API call.
1356type Operation struct {
1357	// Done: If the value is `false`, it means the operation is still in
1358	// progress. If `true`, the operation is completed, and either `error`
1359	// or `response` is available.
1360	Done bool `json:"done,omitempty"`
1361
1362	// Error: The error result of the operation in case of failure or
1363	// cancellation.
1364	Error *Status `json:"error,omitempty"`
1365
1366	// Metadata: Service-specific metadata associated with the operation. It
1367	// typically contains progress information and common metadata such as
1368	// create time. Some services might not provide such metadata. Any
1369	// method that returns a long-running operation should document the
1370	// metadata type, if any.
1371	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
1372
1373	// Name: The server-assigned name, which is only unique within the same
1374	// service that originally returns it. If you use the default HTTP
1375	// mapping, the `name` should be a resource name ending with
1376	// `operations/{unique_id}`.
1377	Name string `json:"name,omitempty"`
1378
1379	// Response: The normal response of the operation in case of success. If
1380	// the original method returns no data on success, such as `Delete`, the
1381	// response is `google.protobuf.Empty`. If the original method is
1382	// standard `Get`/`Create`/`Update`, the response should be the
1383	// resource. For other methods, the response should have the type
1384	// `XxxResponse`, where `Xxx` is the original method name. For example,
1385	// if the original method name is `TakeSnapshot()`, the inferred
1386	// response type is `TakeSnapshotResponse`.
1387	Response googleapi.RawMessage `json:"response,omitempty"`
1388
1389	// ServerResponse contains the HTTP response code and headers from the
1390	// server.
1391	googleapi.ServerResponse `json:"-"`
1392
1393	// ForceSendFields is a list of field names (e.g. "Done") to
1394	// unconditionally include in API requests. By default, fields with
1395	// empty values are omitted from API requests. However, any non-pointer,
1396	// non-interface field appearing in ForceSendFields will be sent to the
1397	// server regardless of whether the field is empty or not. This may be
1398	// used to include empty fields in Patch requests.
1399	ForceSendFields []string `json:"-"`
1400
1401	// NullFields is a list of field names (e.g. "Done") to include in API
1402	// requests with the JSON null value. By default, fields with empty
1403	// values are omitted from API requests. However, any field with an
1404	// empty value appearing in NullFields will be sent to the server as
1405	// null. It is an error if a field in this list has a non-empty value.
1406	// This may be used to include null fields in Patch requests.
1407	NullFields []string `json:"-"`
1408}
1409
1410func (s *Operation) MarshalJSON() ([]byte, error) {
1411	type NoMethod Operation
1412	raw := NoMethod(*s)
1413	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1414}
1415
1416type PackageData struct {
1417	// CpeUri: The cpe_uri in [cpe format]
1418	// (https://cpe.mitre.org/specification/) in which the vulnerability may
1419	// manifest. Examples include distro or storage location for vulnerable
1420	// jar.
1421	CpeUri string `json:"cpeUri,omitempty"`
1422
1423	// Os: The OS affected by a vulnerability This field is deprecated and
1424	// the information is in cpe_uri
1425	Os string `json:"os,omitempty"`
1426
1427	// OsVersion: The version of the OS This field is deprecated and the
1428	// information is in cpe_uri
1429	OsVersion string `json:"osVersion,omitempty"`
1430
1431	// Package: The package being analysed for vulnerabilities
1432	Package string `json:"package,omitempty"`
1433
1434	// ProjectId: The projectId of the package to which this data belongs.
1435	// Most of Drydock's code does not set or use this field. This is added
1436	// specifically so we can group packages by projects and decide whether
1437	// or not to apply NVD data to the packages belonging to a specific
1438	// project.
1439	ProjectId string `json:"projectId,omitempty"`
1440
1441	// Version: The version of the package being analysed
1442	Version string `json:"version,omitempty"`
1443
1444	// ForceSendFields is a list of field names (e.g. "CpeUri") to
1445	// unconditionally include in API requests. By default, fields with
1446	// empty values are omitted from API requests. However, any non-pointer,
1447	// non-interface field appearing in ForceSendFields will be sent to the
1448	// server regardless of whether the field is empty or not. This may be
1449	// used to include empty fields in Patch requests.
1450	ForceSendFields []string `json:"-"`
1451
1452	// NullFields is a list of field names (e.g. "CpeUri") to include in API
1453	// requests with the JSON null value. By default, fields with empty
1454	// values are omitted from API requests. However, any field with an
1455	// empty value appearing in NullFields will be sent to the server as
1456	// null. It is an error if a field in this list has a non-empty value.
1457	// This may be used to include null fields in Patch requests.
1458	NullFields []string `json:"-"`
1459}
1460
1461func (s *PackageData) MarshalJSON() ([]byte, error) {
1462	type NoMethod PackageData
1463	raw := NoMethod(*s)
1464	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1465}
1466
1467// PackageIssue: A detail for a distro and package this vulnerability
1468// occurrence was found in and its associated fix (if one is available).
1469type PackageIssue struct {
1470	// AffectedCpeUri: Required. The CPE URI
1471	// (https://cpe.mitre.org/specification/) this vulnerability was found
1472	// in.
1473	AffectedCpeUri string `json:"affectedCpeUri,omitempty"`
1474
1475	// AffectedPackage: Required. The package this vulnerability was found
1476	// in.
1477	AffectedPackage string `json:"affectedPackage,omitempty"`
1478
1479	// AffectedVersion: Required. The version of the package that is
1480	// installed on the resource affected by this vulnerability.
1481	AffectedVersion *Version `json:"affectedVersion,omitempty"`
1482
1483	// FixAvailable: Output only. Whether a fix is available for this
1484	// package.
1485	FixAvailable bool `json:"fixAvailable,omitempty"`
1486
1487	// FixedCpeUri: The CPE URI (https://cpe.mitre.org/specification/) this
1488	// vulnerability was fixed in. It is possible for this to be different
1489	// from the affected_cpe_uri.
1490	FixedCpeUri string `json:"fixedCpeUri,omitempty"`
1491
1492	// FixedPackage: The package this vulnerability was fixed in. It is
1493	// possible for this to be different from the affected_package.
1494	FixedPackage string `json:"fixedPackage,omitempty"`
1495
1496	// FixedVersion: Required. The version of the package this vulnerability
1497	// was fixed in. Setting this to VersionKind.MAXIMUM means no fix is yet
1498	// available.
1499	FixedVersion *Version `json:"fixedVersion,omitempty"`
1500
1501	// ForceSendFields is a list of field names (e.g. "AffectedCpeUri") to
1502	// unconditionally include in API requests. By default, fields with
1503	// empty values are omitted from API requests. However, any non-pointer,
1504	// non-interface field appearing in ForceSendFields will be sent to the
1505	// server regardless of whether the field is empty or not. This may be
1506	// used to include empty fields in Patch requests.
1507	ForceSendFields []string `json:"-"`
1508
1509	// NullFields is a list of field names (e.g. "AffectedCpeUri") to
1510	// include in API requests with the JSON null value. By default, fields
1511	// with empty values are omitted from API requests. However, any field
1512	// with an empty value appearing in NullFields will be sent to the
1513	// server as null. It is an error if a field in this list has a
1514	// non-empty value. This may be used to include null fields in Patch
1515	// requests.
1516	NullFields []string `json:"-"`
1517}
1518
1519func (s *PackageIssue) MarshalJSON() ([]byte, error) {
1520	type NoMethod PackageIssue
1521	raw := NoMethod(*s)
1522	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1523}
1524
1525// PackageOccurrence: Details on how a particular software package was
1526// installed on a system.
1527type PackageOccurrence struct {
1528	// Location: Required. All of the places within the filesystem versions
1529	// of this package have been found.
1530	Location []*Location `json:"location,omitempty"`
1531
1532	// Name: Output only. The name of the installed package.
1533	Name string `json:"name,omitempty"`
1534
1535	// ForceSendFields is a list of field names (e.g. "Location") to
1536	// unconditionally include in API requests. By default, fields with
1537	// empty values are omitted from API requests. However, any non-pointer,
1538	// non-interface field appearing in ForceSendFields will be sent to the
1539	// server regardless of whether the field is empty or not. This may be
1540	// used to include empty fields in Patch requests.
1541	ForceSendFields []string `json:"-"`
1542
1543	// NullFields is a list of field names (e.g. "Location") to include in
1544	// API requests with the JSON null value. By default, fields with empty
1545	// values are omitted from API requests. However, any field with an
1546	// empty value appearing in NullFields will be sent to the server as
1547	// null. It is an error if a field in this list has a non-empty value.
1548	// This may be used to include null fields in Patch requests.
1549	NullFields []string `json:"-"`
1550}
1551
1552func (s *PackageOccurrence) MarshalJSON() ([]byte, error) {
1553	type NoMethod PackageOccurrence
1554	raw := NoMethod(*s)
1555	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1556}
1557
1558// ProjectRepoId: Selects a repo using a Google Cloud Platform project
1559// ID (e.g., winged-cargo-31) and a repo name within that project.
1560type ProjectRepoId struct {
1561	// ProjectId: The ID of the project.
1562	ProjectId string `json:"projectId,omitempty"`
1563
1564	// RepoName: The name of the repo. Leave empty for the default repo.
1565	RepoName string `json:"repoName,omitempty"`
1566
1567	// ForceSendFields is a list of field names (e.g. "ProjectId") to
1568	// unconditionally include in API requests. By default, fields with
1569	// empty values are omitted from API requests. However, any non-pointer,
1570	// non-interface field appearing in ForceSendFields will be sent to the
1571	// server regardless of whether the field is empty or not. This may be
1572	// used to include empty fields in Patch requests.
1573	ForceSendFields []string `json:"-"`
1574
1575	// NullFields is a list of field names (e.g. "ProjectId") to include in
1576	// API requests with the JSON null value. By default, fields with empty
1577	// values are omitted from API requests. However, any field with an
1578	// empty value appearing in NullFields will be sent to the server as
1579	// null. It is an error if a field in this list has a non-empty value.
1580	// This may be used to include null fields in Patch requests.
1581	NullFields []string `json:"-"`
1582}
1583
1584func (s *ProjectRepoId) MarshalJSON() ([]byte, error) {
1585	type NoMethod ProjectRepoId
1586	raw := NoMethod(*s)
1587	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1588}
1589
1590// RelatedUrl: Metadata for any related URL information.
1591type RelatedUrl struct {
1592	// Label: Label to describe usage of the URL.
1593	Label string `json:"label,omitempty"`
1594
1595	// Url: Specific URL associated with the resource.
1596	Url string `json:"url,omitempty"`
1597
1598	// ForceSendFields is a list of field names (e.g. "Label") to
1599	// unconditionally include in API requests. By default, fields with
1600	// empty values are omitted from API requests. However, any non-pointer,
1601	// non-interface field appearing in ForceSendFields will be sent to the
1602	// server regardless of whether the field is empty or not. This may be
1603	// used to include empty fields in Patch requests.
1604	ForceSendFields []string `json:"-"`
1605
1606	// NullFields is a list of field names (e.g. "Label") to include in API
1607	// requests with the JSON null value. By default, fields with empty
1608	// values are omitted from API requests. However, any field with an
1609	// empty value appearing in NullFields will be sent to the server as
1610	// null. It is an error if a field in this list has a non-empty value.
1611	// This may be used to include null fields in Patch requests.
1612	NullFields []string `json:"-"`
1613}
1614
1615func (s *RelatedUrl) MarshalJSON() ([]byte, error) {
1616	type NoMethod RelatedUrl
1617	raw := NoMethod(*s)
1618	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1619}
1620
1621// RepoId: A unique identifier for a Cloud Repo.
1622type RepoId struct {
1623	// ProjectRepoId: A combination of a project ID and a repo name.
1624	ProjectRepoId *ProjectRepoId `json:"projectRepoId,omitempty"`
1625
1626	// Uid: A server-assigned, globally unique identifier.
1627	Uid string `json:"uid,omitempty"`
1628
1629	// ForceSendFields is a list of field names (e.g. "ProjectRepoId") to
1630	// unconditionally include in API requests. By default, fields with
1631	// empty values are omitted from API requests. However, any non-pointer,
1632	// non-interface field appearing in ForceSendFields will be sent to the
1633	// server regardless of whether the field is empty or not. This may be
1634	// used to include empty fields in Patch requests.
1635	ForceSendFields []string `json:"-"`
1636
1637	// NullFields is a list of field names (e.g. "ProjectRepoId") to include
1638	// in API requests with the JSON null value. By default, fields with
1639	// empty values are omitted from API requests. However, any field with
1640	// an empty value appearing in NullFields will be sent to the server as
1641	// null. It is an error if a field in this list has a non-empty value.
1642	// This may be used to include null fields in Patch requests.
1643	NullFields []string `json:"-"`
1644}
1645
1646func (s *RepoId) MarshalJSON() ([]byte, error) {
1647	type NoMethod RepoId
1648	raw := NoMethod(*s)
1649	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1650}
1651
1652// Signature: Verifiers (e.g. Kritis implementations) MUST verify
1653// signatures with respect to the trust anchors defined in policy (e.g.
1654// a Kritis policy). Typically this means that the verifier has been
1655// configured with a map from `public_key_id` to public key material
1656// (and any required parameters, e.g. signing algorithm). In particular,
1657// verification implementations MUST NOT treat the signature
1658// `public_key_id` as anything more than a key lookup hint. The
1659// `public_key_id` DOES NOT validate or authenticate a public key; it
1660// only provides a mechanism for quickly selecting a public key ALREADY
1661// CONFIGURED on the verifier through a trusted channel. Verification
1662// implementations MUST reject signatures in any of the following
1663// circumstances: * The `public_key_id` is not recognized by the
1664// verifier. * The public key that `public_key_id` refers to does not
1665// verify the signature with respect to the payload. The `signature`
1666// contents SHOULD NOT be "attached" (where the payload is included with
1667// the serialized `signature` bytes). Verifiers MUST ignore any
1668// "attached" payload and only verify signatures with respect to
1669// explicitly provided payload (e.g. a `payload` field on the proto
1670// message that holds this Signature, or the canonical serialization of
1671// the proto message that holds this signature).
1672type Signature struct {
1673	// PublicKeyId: The identifier for the public key that verifies this
1674	// signature. * The `public_key_id` is required. * The `public_key_id`
1675	// SHOULD be an RFC3986 conformant URI. * When possible, the
1676	// `public_key_id` SHOULD be an immutable reference, such as a
1677	// cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4
1678	// public key fingerprint: *
1679	// "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See
1680	// https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for
1681	// more details on this scheme. RFC6920 digest-named
1682	// SubjectPublicKeyInfo (digest of the DER serialization): *
1683	// "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" *
1684	// "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95
1685	// a1271589a5"
1686	PublicKeyId string `json:"publicKeyId,omitempty"`
1687
1688	// Signature: The content of the signature, an opaque bytestring. The
1689	// payload that this signature verifies MUST be unambiguously provided
1690	// with the Signature during verification. A wrapper message might
1691	// provide the payload explicitly. Alternatively, a message might have a
1692	// canonical serialization that can always be unambiguously computed to
1693	// derive the payload.
1694	Signature string `json:"signature,omitempty"`
1695
1696	// ForceSendFields is a list of field names (e.g. "PublicKeyId") to
1697	// unconditionally include in API requests. By default, fields with
1698	// empty values are omitted from API requests. However, any non-pointer,
1699	// non-interface field appearing in ForceSendFields will be sent to the
1700	// server regardless of whether the field is empty or not. This may be
1701	// used to include empty fields in Patch requests.
1702	ForceSendFields []string `json:"-"`
1703
1704	// NullFields is a list of field names (e.g. "PublicKeyId") to include
1705	// in API requests with the JSON null value. By default, fields with
1706	// empty values are omitted from API requests. However, any field with
1707	// an empty value appearing in NullFields will be sent to the server as
1708	// null. It is an error if a field in this list has a non-empty value.
1709	// This may be used to include null fields in Patch requests.
1710	NullFields []string `json:"-"`
1711}
1712
1713func (s *Signature) MarshalJSON() ([]byte, error) {
1714	type NoMethod Signature
1715	raw := NoMethod(*s)
1716	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1717}
1718
1719// Source: Source describes the location of the source used for the
1720// build.
1721type Source struct {
1722	// AdditionalContexts: If provided, some of the source code used for the
1723	// build may be found in these locations, in the case where the source
1724	// repository had multiple remotes or submodules. This list will not
1725	// include the context specified in the context field.
1726	AdditionalContexts []*SourceContext `json:"additionalContexts,omitempty"`
1727
1728	// ArtifactStorageSourceUri: If provided, the input binary artifacts for
1729	// the build came from this location.
1730	ArtifactStorageSourceUri string `json:"artifactStorageSourceUri,omitempty"`
1731
1732	// Context: If provided, the source code used for the build came from
1733	// this location.
1734	Context *SourceContext `json:"context,omitempty"`
1735
1736	// FileHashes: Hash(es) of the build source, which can be used to verify
1737	// that the original source integrity was maintained in the build. The
1738	// keys to this map are file paths used as build source and the values
1739	// contain the hash values for those files. If the build source came in
1740	// a single package such as a gzipped tarfile (.tar.gz), the FileHash
1741	// will be for the single path to that file.
1742	FileHashes map[string]FileHashes `json:"fileHashes,omitempty"`
1743
1744	// ForceSendFields is a list of field names (e.g. "AdditionalContexts")
1745	// to unconditionally include in API requests. By default, fields with
1746	// empty values are omitted from API requests. However, any non-pointer,
1747	// non-interface field appearing in ForceSendFields will be sent to the
1748	// server regardless of whether the field is empty or not. This may be
1749	// used to include empty fields in Patch requests.
1750	ForceSendFields []string `json:"-"`
1751
1752	// NullFields is a list of field names (e.g. "AdditionalContexts") to
1753	// include in API requests with the JSON null value. By default, fields
1754	// with empty values are omitted from API requests. However, any field
1755	// with an empty value appearing in NullFields will be sent to the
1756	// server as null. It is an error if a field in this list has a
1757	// non-empty value. This may be used to include null fields in Patch
1758	// requests.
1759	NullFields []string `json:"-"`
1760}
1761
1762func (s *Source) MarshalJSON() ([]byte, error) {
1763	type NoMethod Source
1764	raw := NoMethod(*s)
1765	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1766}
1767
1768// SourceContext: A SourceContext is a reference to a tree of files. A
1769// SourceContext together with a path point to a unique revision of a
1770// single file or directory.
1771type SourceContext struct {
1772	// CloudRepo: A SourceContext referring to a revision in a Google Cloud
1773	// Source Repo.
1774	CloudRepo *CloudRepoSourceContext `json:"cloudRepo,omitempty"`
1775
1776	// Gerrit: A SourceContext referring to a Gerrit project.
1777	Gerrit *GerritSourceContext `json:"gerrit,omitempty"`
1778
1779	// Git: A SourceContext referring to any third party Git repo (e.g.,
1780	// GitHub).
1781	Git *GitSourceContext `json:"git,omitempty"`
1782
1783	// Labels: Labels with user defined metadata.
1784	Labels map[string]string `json:"labels,omitempty"`
1785
1786	// ForceSendFields is a list of field names (e.g. "CloudRepo") to
1787	// unconditionally include in API requests. By default, fields with
1788	// empty values are omitted from API requests. However, any non-pointer,
1789	// non-interface field appearing in ForceSendFields will be sent to the
1790	// server regardless of whether the field is empty or not. This may be
1791	// used to include empty fields in Patch requests.
1792	ForceSendFields []string `json:"-"`
1793
1794	// NullFields is a list of field names (e.g. "CloudRepo") to include in
1795	// API requests with the JSON null value. By default, fields with empty
1796	// values are omitted from API requests. However, any field with an
1797	// empty value appearing in NullFields will be sent to the server as
1798	// null. It is an error if a field in this list has a non-empty value.
1799	// This may be used to include null fields in Patch requests.
1800	NullFields []string `json:"-"`
1801}
1802
1803func (s *SourceContext) MarshalJSON() ([]byte, error) {
1804	type NoMethod SourceContext
1805	raw := NoMethod(*s)
1806	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1807}
1808
1809// Status: The `Status` type defines a logical error model that is
1810// suitable for different programming environments, including REST APIs
1811// and RPC APIs. It is used by gRPC (https://github.com/grpc). Each
1812// `Status` message contains three pieces of data: error code, error
1813// message, and error details. You can find out more about this error
1814// model and how to work with it in the API Design Guide
1815// (https://cloud.google.com/apis/design/errors).
1816type Status struct {
1817	// Code: The status code, which should be an enum value of
1818	// google.rpc.Code.
1819	Code int64 `json:"code,omitempty"`
1820
1821	// Details: A list of messages that carry the error details. There is a
1822	// common set of message types for APIs to use.
1823	Details []googleapi.RawMessage `json:"details,omitempty"`
1824
1825	// Message: A developer-facing error message, which should be in
1826	// English. Any user-facing error message should be localized and sent
1827	// in the google.rpc.Status.details field, or localized by the client.
1828	Message string `json:"message,omitempty"`
1829
1830	// ForceSendFields is a list of field names (e.g. "Code") to
1831	// unconditionally include in API requests. By default, fields with
1832	// empty values are omitted from API requests. However, any non-pointer,
1833	// non-interface field appearing in ForceSendFields will be sent to the
1834	// server regardless of whether the field is empty or not. This may be
1835	// used to include empty fields in Patch requests.
1836	ForceSendFields []string `json:"-"`
1837
1838	// NullFields is a list of field names (e.g. "Code") to include in API
1839	// requests with the JSON null value. By default, fields with empty
1840	// values are omitted from API requests. However, any field with an
1841	// empty value appearing in NullFields will be sent to the server as
1842	// null. It is an error if a field in this list has a non-empty value.
1843	// This may be used to include null fields in Patch requests.
1844	NullFields []string `json:"-"`
1845}
1846
1847func (s *Status) MarshalJSON() ([]byte, error) {
1848	type NoMethod Status
1849	raw := NoMethod(*s)
1850	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1851}
1852
1853// UpgradeDistribution: The Upgrade Distribution represents metadata
1854// about the Upgrade for each operating system (CPE). Some distributions
1855// have additional metadata around updates, classifying them into
1856// various categories and severities.
1857type UpgradeDistribution struct {
1858	// Classification: The operating system classification of this Upgrade,
1859	// as specified by the upstream operating system upgrade feed. For
1860	// Windows the classification is one of the category_ids listed at
1861	// https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85)
1862	Classification string `json:"classification,omitempty"`
1863
1864	// CpeUri: Required - The specific operating system this metadata
1865	// applies to. See https://cpe.mitre.org/specification/.
1866	CpeUri string `json:"cpeUri,omitempty"`
1867
1868	// Cve: The cve tied to this Upgrade.
1869	Cve []string `json:"cve,omitempty"`
1870
1871	// Severity: The severity as specified by the upstream operating system.
1872	Severity string `json:"severity,omitempty"`
1873
1874	// ForceSendFields is a list of field names (e.g. "Classification") to
1875	// unconditionally include in API requests. By default, fields with
1876	// empty values are omitted from API requests. However, any non-pointer,
1877	// non-interface field appearing in ForceSendFields will be sent to the
1878	// server regardless of whether the field is empty or not. This may be
1879	// used to include empty fields in Patch requests.
1880	ForceSendFields []string `json:"-"`
1881
1882	// NullFields is a list of field names (e.g. "Classification") to
1883	// include in API requests with the JSON null value. By default, fields
1884	// with empty values are omitted from API requests. However, any field
1885	// with an empty value appearing in NullFields will be sent to the
1886	// server as null. It is an error if a field in this list has a
1887	// non-empty value. This may be used to include null fields in Patch
1888	// requests.
1889	NullFields []string `json:"-"`
1890}
1891
1892func (s *UpgradeDistribution) MarshalJSON() ([]byte, error) {
1893	type NoMethod UpgradeDistribution
1894	raw := NoMethod(*s)
1895	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1896}
1897
1898// UpgradeOccurrence: An Upgrade Occurrence represents that a specific
1899// resource_url could install a specific upgrade. This presence is
1900// supplied via local sources (i.e. it is present in the mirror and the
1901// running system has noticed its availability). For Windows, both
1902// distribution and windows_update contain information for the Windows
1903// update.
1904type UpgradeOccurrence struct {
1905	// Distribution: Metadata about the upgrade for available for the
1906	// specific operating system for the resource_url. This allows efficient
1907	// filtering, as well as making it easier to use the occurrence.
1908	Distribution *UpgradeDistribution `json:"distribution,omitempty"`
1909
1910	// Package: Required for non-Windows OS. The package this Upgrade is
1911	// for.
1912	Package string `json:"package,omitempty"`
1913
1914	// ParsedVersion: Required for non-Windows OS. The version of the
1915	// package in a machine + human readable form.
1916	ParsedVersion *Version `json:"parsedVersion,omitempty"`
1917
1918	// WindowsUpdate: Required for Windows OS. Represents the metadata about
1919	// the Windows update.
1920	WindowsUpdate *WindowsUpdate `json:"windowsUpdate,omitempty"`
1921
1922	// ForceSendFields is a list of field names (e.g. "Distribution") to
1923	// unconditionally include in API requests. By default, fields with
1924	// empty values are omitted from API requests. However, any non-pointer,
1925	// non-interface field appearing in ForceSendFields will be sent to the
1926	// server regardless of whether the field is empty or not. This may be
1927	// used to include empty fields in Patch requests.
1928	ForceSendFields []string `json:"-"`
1929
1930	// NullFields is a list of field names (e.g. "Distribution") to include
1931	// in API requests with the JSON null value. By default, fields with
1932	// empty values are omitted from API requests. However, any field with
1933	// an empty value appearing in NullFields will be sent to the server as
1934	// null. It is an error if a field in this list has a non-empty value.
1935	// This may be used to include null fields in Patch requests.
1936	NullFields []string `json:"-"`
1937}
1938
1939func (s *UpgradeOccurrence) MarshalJSON() ([]byte, error) {
1940	type NoMethod UpgradeOccurrence
1941	raw := NoMethod(*s)
1942	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1943}
1944
1945// Version: Version contains structured information about the version of
1946// a package.
1947type Version struct {
1948	// Epoch: Used to correct mistakes in the version numbering scheme.
1949	Epoch int64 `json:"epoch,omitempty"`
1950
1951	// FullName: Human readable version string. This string is of the form
1952	// :- and is only set when kind is NORMAL.
1953	FullName string `json:"fullName,omitempty"`
1954
1955	// Inclusive: Whether this version is specifying part of an inclusive
1956	// range. Grafeas does not have the capability to specify version
1957	// ranges; instead we have fields that specify start version and end
1958	// versions. At times this is insufficient - we also need to specify
1959	// whether the version is included in the range or is excluded from the
1960	// range. This boolean is expected to be set to true when the version is
1961	// included in a range.
1962	Inclusive bool `json:"inclusive,omitempty"`
1963
1964	// Kind: Required. Distinguishes between sentinel MIN/MAX versions and
1965	// normal versions.
1966	//
1967	// Possible values:
1968	//   "VERSION_KIND_UNSPECIFIED" - Unknown.
1969	//   "NORMAL" - A standard package version.
1970	//   "MINIMUM" - A special version representing negative infinity.
1971	//   "MAXIMUM" - A special version representing positive infinity.
1972	Kind string `json:"kind,omitempty"`
1973
1974	// Name: Required only when version kind is NORMAL. The main part of the
1975	// version name.
1976	Name string `json:"name,omitempty"`
1977
1978	// Revision: The iteration of the package build from the above version.
1979	Revision string `json:"revision,omitempty"`
1980
1981	// ForceSendFields is a list of field names (e.g. "Epoch") to
1982	// unconditionally include in API requests. By default, fields with
1983	// empty values are omitted from API requests. However, any non-pointer,
1984	// non-interface field appearing in ForceSendFields will be sent to the
1985	// server regardless of whether the field is empty or not. This may be
1986	// used to include empty fields in Patch requests.
1987	ForceSendFields []string `json:"-"`
1988
1989	// NullFields is a list of field names (e.g. "Epoch") to include in API
1990	// requests with the JSON null value. By default, fields with empty
1991	// values are omitted from API requests. However, any field with an
1992	// empty value appearing in NullFields will be sent to the server as
1993	// null. It is an error if a field in this list has a non-empty value.
1994	// This may be used to include null fields in Patch requests.
1995	NullFields []string `json:"-"`
1996}
1997
1998func (s *Version) MarshalJSON() ([]byte, error) {
1999	type NoMethod Version
2000	raw := NoMethod(*s)
2001	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2002}
2003
2004// VulnerabilityOccurrence: An occurrence of a severity vulnerability on
2005// a resource.
2006type VulnerabilityOccurrence struct {
2007	// CvssScore: Output only. The CVSS score of this vulnerability. CVSS
2008	// score is on a scale of 0 - 10 where 0 indicates low severity and 10
2009	// indicates high severity.
2010	CvssScore float64 `json:"cvssScore,omitempty"`
2011
2012	// EffectiveSeverity: The distro assigned severity for this
2013	// vulnerability when it is available, otherwise this is the note
2014	// provider assigned severity.
2015	//
2016	// Possible values:
2017	//   "SEVERITY_UNSPECIFIED" - Unknown.
2018	//   "MINIMAL" - Minimal severity.
2019	//   "LOW" - Low severity.
2020	//   "MEDIUM" - Medium severity.
2021	//   "HIGH" - High severity.
2022	//   "CRITICAL" - Critical severity.
2023	EffectiveSeverity string `json:"effectiveSeverity,omitempty"`
2024
2025	// FixAvailable: Output only. Whether at least one of the affected
2026	// packages has a fix available.
2027	FixAvailable bool `json:"fixAvailable,omitempty"`
2028
2029	// LongDescription: Output only. A detailed description of this
2030	// vulnerability.
2031	LongDescription string `json:"longDescription,omitempty"`
2032
2033	// PackageIssue: Required. The set of affected locations and their fixes
2034	// (if available) within the associated resource.
2035	PackageIssue []*PackageIssue `json:"packageIssue,omitempty"`
2036
2037	// RelatedUrls: Output only. URLs related to this vulnerability.
2038	RelatedUrls []*RelatedUrl `json:"relatedUrls,omitempty"`
2039
2040	// Severity: Output only. The note provider assigned severity of this
2041	// vulnerability.
2042	//
2043	// Possible values:
2044	//   "SEVERITY_UNSPECIFIED" - Unknown.
2045	//   "MINIMAL" - Minimal severity.
2046	//   "LOW" - Low severity.
2047	//   "MEDIUM" - Medium severity.
2048	//   "HIGH" - High severity.
2049	//   "CRITICAL" - Critical severity.
2050	Severity string `json:"severity,omitempty"`
2051
2052	// ShortDescription: Output only. A one sentence description of this
2053	// vulnerability.
2054	ShortDescription string `json:"shortDescription,omitempty"`
2055
2056	// Type: The type of package; whether native or non native (e.g., ruby
2057	// gems, node.js packages, etc.).
2058	Type string `json:"type,omitempty"`
2059
2060	// ForceSendFields is a list of field names (e.g. "CvssScore") to
2061	// unconditionally include in API requests. By default, fields with
2062	// empty values are omitted from API requests. However, any non-pointer,
2063	// non-interface field appearing in ForceSendFields will be sent to the
2064	// server regardless of whether the field is empty or not. This may be
2065	// used to include empty fields in Patch requests.
2066	ForceSendFields []string `json:"-"`
2067
2068	// NullFields is a list of field names (e.g. "CvssScore") to include in
2069	// API requests with the JSON null value. By default, fields with empty
2070	// values are omitted from API requests. However, any field with an
2071	// empty value appearing in NullFields will be sent to the server as
2072	// null. It is an error if a field in this list has a non-empty value.
2073	// This may be used to include null fields in Patch requests.
2074	NullFields []string `json:"-"`
2075}
2076
2077func (s *VulnerabilityOccurrence) MarshalJSON() ([]byte, error) {
2078	type NoMethod VulnerabilityOccurrence
2079	raw := NoMethod(*s)
2080	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2081}
2082
2083func (s *VulnerabilityOccurrence) UnmarshalJSON(data []byte) error {
2084	type NoMethod VulnerabilityOccurrence
2085	var s1 struct {
2086		CvssScore gensupport.JSONFloat64 `json:"cvssScore"`
2087		*NoMethod
2088	}
2089	s1.NoMethod = (*NoMethod)(s)
2090	if err := json.Unmarshal(data, &s1); err != nil {
2091		return err
2092	}
2093	s.CvssScore = float64(s1.CvssScore)
2094	return nil
2095}
2096
2097// WindowsUpdate: Windows Update represents the metadata about the
2098// update for the Windows operating system. The fields in this message
2099// come from the Windows Update API documented at
2100// https://docs.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdate.
2101type WindowsUpdate struct {
2102	// Categories: The list of categories to which the update belongs.
2103	Categories []*Category `json:"categories,omitempty"`
2104
2105	// Description: The localized description of the update.
2106	Description string `json:"description,omitempty"`
2107
2108	// Identity: Required - The unique identifier for the update.
2109	Identity *Identity `json:"identity,omitempty"`
2110
2111	// KbArticleIds: The Microsoft Knowledge Base article IDs that are
2112	// associated with the update.
2113	KbArticleIds []string `json:"kbArticleIds,omitempty"`
2114
2115	// LastPublishedTimestamp: The last published timestamp of the update.
2116	LastPublishedTimestamp string `json:"lastPublishedTimestamp,omitempty"`
2117
2118	// SupportUrl: The hyperlink to the support information for the update.
2119	SupportUrl string `json:"supportUrl,omitempty"`
2120
2121	// Title: The localized title of the update.
2122	Title string `json:"title,omitempty"`
2123
2124	// ForceSendFields is a list of field names (e.g. "Categories") to
2125	// unconditionally include in API requests. By default, fields with
2126	// empty values are omitted from API requests. However, any non-pointer,
2127	// non-interface field appearing in ForceSendFields will be sent to the
2128	// server regardless of whether the field is empty or not. This may be
2129	// used to include empty fields in Patch requests.
2130	ForceSendFields []string `json:"-"`
2131
2132	// NullFields is a list of field names (e.g. "Categories") to include in
2133	// API requests with the JSON null value. By default, fields with empty
2134	// values are omitted from API requests. However, any field with an
2135	// empty value appearing in NullFields will be sent to the server as
2136	// null. It is an error if a field in this list has a non-empty value.
2137	// This may be used to include null fields in Patch requests.
2138	NullFields []string `json:"-"`
2139}
2140
2141func (s *WindowsUpdate) MarshalJSON() ([]byte, error) {
2142	type NoMethod WindowsUpdate
2143	raw := NoMethod(*s)
2144	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2145}
2146
2147// method id "ondemandscanning.projects.locations.operations.cancel":
2148
2149type ProjectsLocationsOperationsCancelCall struct {
2150	s          *Service
2151	name       string
2152	urlParams_ gensupport.URLParams
2153	ctx_       context.Context
2154	header_    http.Header
2155}
2156
2157// Cancel: Starts asynchronous cancellation on a long-running operation.
2158// The server makes a best effort to cancel the operation, but success
2159// is not guaranteed. If the server doesn't support this method, it
2160// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use
2161// Operations.GetOperation or other methods to check whether the
2162// cancellation succeeded or whether the operation completed despite
2163// cancellation. On successful cancellation, the operation is not
2164// deleted; instead, it becomes an operation with an Operation.error
2165// value with a google.rpc.Status.code of 1, corresponding to
2166// `Code.CANCELLED`.
2167//
2168// - name: The name of the operation resource to be cancelled.
2169func (r *ProjectsLocationsOperationsService) Cancel(name string) *ProjectsLocationsOperationsCancelCall {
2170	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2171	c.name = name
2172	return c
2173}
2174
2175// Fields allows partial responses to be retrieved. See
2176// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2177// for more information.
2178func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
2179	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2180	return c
2181}
2182
2183// Context sets the context to be used in this call's Do method. Any
2184// pending HTTP request will be aborted if the provided context is
2185// canceled.
2186func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
2187	c.ctx_ = ctx
2188	return c
2189}
2190
2191// Header returns an http.Header that can be modified by the caller to
2192// add HTTP headers to the request.
2193func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
2194	if c.header_ == nil {
2195		c.header_ = make(http.Header)
2196	}
2197	return c.header_
2198}
2199
2200func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
2201	reqHeaders := make(http.Header)
2202	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
2203	for k, v := range c.header_ {
2204		reqHeaders[k] = v
2205	}
2206	reqHeaders.Set("User-Agent", c.s.userAgent())
2207	var body io.Reader = nil
2208	c.urlParams_.Set("alt", alt)
2209	c.urlParams_.Set("prettyPrint", "false")
2210	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel")
2211	urls += "?" + c.urlParams_.Encode()
2212	req, err := http.NewRequest("POST", urls, body)
2213	if err != nil {
2214		return nil, err
2215	}
2216	req.Header = reqHeaders
2217	googleapi.Expand(req.URL, map[string]string{
2218		"name": c.name,
2219	})
2220	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2221}
2222
2223// Do executes the "ondemandscanning.projects.locations.operations.cancel" call.
2224// Exactly one of *Empty or error will be non-nil. Any non-2xx status
2225// code is an error. Response headers are in either
2226// *Empty.ServerResponse.Header or (if a response was returned at all)
2227// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
2228// check whether the returned error was because http.StatusNotModified
2229// was returned.
2230func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
2231	gensupport.SetOptions(c.urlParams_, opts...)
2232	res, err := c.doRequest("json")
2233	if res != nil && res.StatusCode == http.StatusNotModified {
2234		if res.Body != nil {
2235			res.Body.Close()
2236		}
2237		return nil, &googleapi.Error{
2238			Code:   res.StatusCode,
2239			Header: res.Header,
2240		}
2241	}
2242	if err != nil {
2243		return nil, err
2244	}
2245	defer googleapi.CloseBody(res)
2246	if err := googleapi.CheckResponse(res); err != nil {
2247		return nil, err
2248	}
2249	ret := &Empty{
2250		ServerResponse: googleapi.ServerResponse{
2251			Header:         res.Header,
2252			HTTPStatusCode: res.StatusCode,
2253		},
2254	}
2255	target := &ret
2256	if err := gensupport.DecodeResponse(target, res); err != nil {
2257		return nil, err
2258	}
2259	return ret, nil
2260	// {
2261	//   "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.",
2262	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
2263	//   "httpMethod": "POST",
2264	//   "id": "ondemandscanning.projects.locations.operations.cancel",
2265	//   "parameterOrder": [
2266	//     "name"
2267	//   ],
2268	//   "parameters": {
2269	//     "name": {
2270	//       "description": "The name of the operation resource to be cancelled.",
2271	//       "location": "path",
2272	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
2273	//       "required": true,
2274	//       "type": "string"
2275	//     }
2276	//   },
2277	//   "path": "v1/{+name}:cancel",
2278	//   "response": {
2279	//     "$ref": "Empty"
2280	//   },
2281	//   "scopes": [
2282	//     "https://www.googleapis.com/auth/cloud-platform"
2283	//   ]
2284	// }
2285
2286}
2287
2288// method id "ondemandscanning.projects.locations.operations.delete":
2289
2290type ProjectsLocationsOperationsDeleteCall struct {
2291	s          *Service
2292	name       string
2293	urlParams_ gensupport.URLParams
2294	ctx_       context.Context
2295	header_    http.Header
2296}
2297
2298// Delete: Deletes a long-running operation. This method indicates that
2299// the client is no longer interested in the operation result. It does
2300// not cancel the operation. If the server doesn't support this method,
2301// it returns `google.rpc.Code.UNIMPLEMENTED`.
2302//
2303// - name: The name of the operation resource to be deleted.
2304func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall {
2305	c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2306	c.name = name
2307	return c
2308}
2309
2310// Fields allows partial responses to be retrieved. See
2311// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2312// for more information.
2313func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall {
2314	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2315	return c
2316}
2317
2318// Context sets the context to be used in this call's Do method. Any
2319// pending HTTP request will be aborted if the provided context is
2320// canceled.
2321func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall {
2322	c.ctx_ = ctx
2323	return c
2324}
2325
2326// Header returns an http.Header that can be modified by the caller to
2327// add HTTP headers to the request.
2328func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header {
2329	if c.header_ == nil {
2330		c.header_ = make(http.Header)
2331	}
2332	return c.header_
2333}
2334
2335func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) {
2336	reqHeaders := make(http.Header)
2337	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
2338	for k, v := range c.header_ {
2339		reqHeaders[k] = v
2340	}
2341	reqHeaders.Set("User-Agent", c.s.userAgent())
2342	var body io.Reader = nil
2343	c.urlParams_.Set("alt", alt)
2344	c.urlParams_.Set("prettyPrint", "false")
2345	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
2346	urls += "?" + c.urlParams_.Encode()
2347	req, err := http.NewRequest("DELETE", urls, body)
2348	if err != nil {
2349		return nil, err
2350	}
2351	req.Header = reqHeaders
2352	googleapi.Expand(req.URL, map[string]string{
2353		"name": c.name,
2354	})
2355	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2356}
2357
2358// Do executes the "ondemandscanning.projects.locations.operations.delete" call.
2359// Exactly one of *Empty or error will be non-nil. Any non-2xx status
2360// code is an error. Response headers are in either
2361// *Empty.ServerResponse.Header or (if a response was returned at all)
2362// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
2363// check whether the returned error was because http.StatusNotModified
2364// was returned.
2365func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
2366	gensupport.SetOptions(c.urlParams_, opts...)
2367	res, err := c.doRequest("json")
2368	if res != nil && res.StatusCode == http.StatusNotModified {
2369		if res.Body != nil {
2370			res.Body.Close()
2371		}
2372		return nil, &googleapi.Error{
2373			Code:   res.StatusCode,
2374			Header: res.Header,
2375		}
2376	}
2377	if err != nil {
2378		return nil, err
2379	}
2380	defer googleapi.CloseBody(res)
2381	if err := googleapi.CheckResponse(res); err != nil {
2382		return nil, err
2383	}
2384	ret := &Empty{
2385		ServerResponse: googleapi.ServerResponse{
2386			Header:         res.Header,
2387			HTTPStatusCode: res.StatusCode,
2388		},
2389	}
2390	target := &ret
2391	if err := gensupport.DecodeResponse(target, res); err != nil {
2392		return nil, err
2393	}
2394	return ret, nil
2395	// {
2396	//   "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.",
2397	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
2398	//   "httpMethod": "DELETE",
2399	//   "id": "ondemandscanning.projects.locations.operations.delete",
2400	//   "parameterOrder": [
2401	//     "name"
2402	//   ],
2403	//   "parameters": {
2404	//     "name": {
2405	//       "description": "The name of the operation resource to be deleted.",
2406	//       "location": "path",
2407	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
2408	//       "required": true,
2409	//       "type": "string"
2410	//     }
2411	//   },
2412	//   "path": "v1/{+name}",
2413	//   "response": {
2414	//     "$ref": "Empty"
2415	//   },
2416	//   "scopes": [
2417	//     "https://www.googleapis.com/auth/cloud-platform"
2418	//   ]
2419	// }
2420
2421}
2422
2423// method id "ondemandscanning.projects.locations.operations.get":
2424
2425type ProjectsLocationsOperationsGetCall struct {
2426	s            *Service
2427	name         string
2428	urlParams_   gensupport.URLParams
2429	ifNoneMatch_ string
2430	ctx_         context.Context
2431	header_      http.Header
2432}
2433
2434// Get: Gets the latest state of a long-running operation. Clients can
2435// use this method to poll the operation result at intervals as
2436// recommended by the API service.
2437//
2438// - name: The name of the operation resource.
2439func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
2440	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2441	c.name = name
2442	return c
2443}
2444
2445// Fields allows partial responses to be retrieved. See
2446// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2447// for more information.
2448func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
2449	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2450	return c
2451}
2452
2453// IfNoneMatch sets the optional parameter which makes the operation
2454// fail if the object's ETag matches the given value. This is useful for
2455// getting updates only after the object has changed since the last
2456// request. Use googleapi.IsNotModified to check whether the response
2457// error from Do is the result of In-None-Match.
2458func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
2459	c.ifNoneMatch_ = entityTag
2460	return c
2461}
2462
2463// Context sets the context to be used in this call's Do method. Any
2464// pending HTTP request will be aborted if the provided context is
2465// canceled.
2466func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
2467	c.ctx_ = ctx
2468	return c
2469}
2470
2471// Header returns an http.Header that can be modified by the caller to
2472// add HTTP headers to the request.
2473func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
2474	if c.header_ == nil {
2475		c.header_ = make(http.Header)
2476	}
2477	return c.header_
2478}
2479
2480func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
2481	reqHeaders := make(http.Header)
2482	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
2483	for k, v := range c.header_ {
2484		reqHeaders[k] = v
2485	}
2486	reqHeaders.Set("User-Agent", c.s.userAgent())
2487	if c.ifNoneMatch_ != "" {
2488		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
2489	}
2490	var body io.Reader = nil
2491	c.urlParams_.Set("alt", alt)
2492	c.urlParams_.Set("prettyPrint", "false")
2493	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
2494	urls += "?" + c.urlParams_.Encode()
2495	req, err := http.NewRequest("GET", urls, body)
2496	if err != nil {
2497		return nil, err
2498	}
2499	req.Header = reqHeaders
2500	googleapi.Expand(req.URL, map[string]string{
2501		"name": c.name,
2502	})
2503	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2504}
2505
2506// Do executes the "ondemandscanning.projects.locations.operations.get" call.
2507// Exactly one of *Operation or error will be non-nil. Any non-2xx
2508// status code is an error. Response headers are in either
2509// *Operation.ServerResponse.Header or (if a response was returned at
2510// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2511// to check whether the returned error was because
2512// http.StatusNotModified was returned.
2513func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
2514	gensupport.SetOptions(c.urlParams_, opts...)
2515	res, err := c.doRequest("json")
2516	if res != nil && res.StatusCode == http.StatusNotModified {
2517		if res.Body != nil {
2518			res.Body.Close()
2519		}
2520		return nil, &googleapi.Error{
2521			Code:   res.StatusCode,
2522			Header: res.Header,
2523		}
2524	}
2525	if err != nil {
2526		return nil, err
2527	}
2528	defer googleapi.CloseBody(res)
2529	if err := googleapi.CheckResponse(res); err != nil {
2530		return nil, err
2531	}
2532	ret := &Operation{
2533		ServerResponse: googleapi.ServerResponse{
2534			Header:         res.Header,
2535			HTTPStatusCode: res.StatusCode,
2536		},
2537	}
2538	target := &ret
2539	if err := gensupport.DecodeResponse(target, res); err != nil {
2540		return nil, err
2541	}
2542	return ret, nil
2543	// {
2544	//   "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.",
2545	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
2546	//   "httpMethod": "GET",
2547	//   "id": "ondemandscanning.projects.locations.operations.get",
2548	//   "parameterOrder": [
2549	//     "name"
2550	//   ],
2551	//   "parameters": {
2552	//     "name": {
2553	//       "description": "The name of the operation resource.",
2554	//       "location": "path",
2555	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
2556	//       "required": true,
2557	//       "type": "string"
2558	//     }
2559	//   },
2560	//   "path": "v1/{+name}",
2561	//   "response": {
2562	//     "$ref": "Operation"
2563	//   },
2564	//   "scopes": [
2565	//     "https://www.googleapis.com/auth/cloud-platform"
2566	//   ]
2567	// }
2568
2569}
2570
2571// method id "ondemandscanning.projects.locations.operations.list":
2572
2573type ProjectsLocationsOperationsListCall struct {
2574	s            *Service
2575	name         string
2576	urlParams_   gensupport.URLParams
2577	ifNoneMatch_ string
2578	ctx_         context.Context
2579	header_      http.Header
2580}
2581
2582// List: Lists operations that match the specified filter in the
2583// request. If the server doesn't support this method, it returns
2584// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
2585// override the binding to use different resource name schemes, such as
2586// `users/*/operations`. To override the binding, API services can add a
2587// binding such as "/v1/{name=users/*}/operations" to their service
2588// configuration. For backwards compatibility, the default name includes
2589// the operations collection id, however overriding users must ensure
2590// the name binding is the parent resource, without the operations
2591// collection id.
2592//
2593// - name: The name of the operation's parent resource.
2594func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
2595	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2596	c.name = name
2597	return c
2598}
2599
2600// Filter sets the optional parameter "filter": The standard list
2601// filter.
2602func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
2603	c.urlParams_.Set("filter", filter)
2604	return c
2605}
2606
2607// PageSize sets the optional parameter "pageSize": The standard list
2608// page size.
2609func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
2610	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
2611	return c
2612}
2613
2614// PageToken sets the optional parameter "pageToken": The standard list
2615// page token.
2616func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
2617	c.urlParams_.Set("pageToken", pageToken)
2618	return c
2619}
2620
2621// Fields allows partial responses to be retrieved. See
2622// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2623// for more information.
2624func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
2625	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2626	return c
2627}
2628
2629// IfNoneMatch sets the optional parameter which makes the operation
2630// fail if the object's ETag matches the given value. This is useful for
2631// getting updates only after the object has changed since the last
2632// request. Use googleapi.IsNotModified to check whether the response
2633// error from Do is the result of In-None-Match.
2634func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
2635	c.ifNoneMatch_ = entityTag
2636	return c
2637}
2638
2639// Context sets the context to be used in this call's Do method. Any
2640// pending HTTP request will be aborted if the provided context is
2641// canceled.
2642func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
2643	c.ctx_ = ctx
2644	return c
2645}
2646
2647// Header returns an http.Header that can be modified by the caller to
2648// add HTTP headers to the request.
2649func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
2650	if c.header_ == nil {
2651		c.header_ = make(http.Header)
2652	}
2653	return c.header_
2654}
2655
2656func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
2657	reqHeaders := make(http.Header)
2658	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
2659	for k, v := range c.header_ {
2660		reqHeaders[k] = v
2661	}
2662	reqHeaders.Set("User-Agent", c.s.userAgent())
2663	if c.ifNoneMatch_ != "" {
2664		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
2665	}
2666	var body io.Reader = nil
2667	c.urlParams_.Set("alt", alt)
2668	c.urlParams_.Set("prettyPrint", "false")
2669	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations")
2670	urls += "?" + c.urlParams_.Encode()
2671	req, err := http.NewRequest("GET", urls, body)
2672	if err != nil {
2673		return nil, err
2674	}
2675	req.Header = reqHeaders
2676	googleapi.Expand(req.URL, map[string]string{
2677		"name": c.name,
2678	})
2679	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2680}
2681
2682// Do executes the "ondemandscanning.projects.locations.operations.list" call.
2683// Exactly one of *ListOperationsResponse or error will be non-nil. Any
2684// non-2xx status code is an error. Response headers are in either
2685// *ListOperationsResponse.ServerResponse.Header or (if a response was
2686// returned at all) in error.(*googleapi.Error).Header. Use
2687// googleapi.IsNotModified to check whether the returned error was
2688// because http.StatusNotModified was returned.
2689func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
2690	gensupport.SetOptions(c.urlParams_, opts...)
2691	res, err := c.doRequest("json")
2692	if res != nil && res.StatusCode == http.StatusNotModified {
2693		if res.Body != nil {
2694			res.Body.Close()
2695		}
2696		return nil, &googleapi.Error{
2697			Code:   res.StatusCode,
2698			Header: res.Header,
2699		}
2700	}
2701	if err != nil {
2702		return nil, err
2703	}
2704	defer googleapi.CloseBody(res)
2705	if err := googleapi.CheckResponse(res); err != nil {
2706		return nil, err
2707	}
2708	ret := &ListOperationsResponse{
2709		ServerResponse: googleapi.ServerResponse{
2710			Header:         res.Header,
2711			HTTPStatusCode: res.StatusCode,
2712		},
2713	}
2714	target := &ret
2715	if err := gensupport.DecodeResponse(target, res); err != nil {
2716		return nil, err
2717	}
2718	return ret, nil
2719	// {
2720	//   "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.",
2721	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations",
2722	//   "httpMethod": "GET",
2723	//   "id": "ondemandscanning.projects.locations.operations.list",
2724	//   "parameterOrder": [
2725	//     "name"
2726	//   ],
2727	//   "parameters": {
2728	//     "filter": {
2729	//       "description": "The standard list filter.",
2730	//       "location": "query",
2731	//       "type": "string"
2732	//     },
2733	//     "name": {
2734	//       "description": "The name of the operation's parent resource.",
2735	//       "location": "path",
2736	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
2737	//       "required": true,
2738	//       "type": "string"
2739	//     },
2740	//     "pageSize": {
2741	//       "description": "The standard list page size.",
2742	//       "format": "int32",
2743	//       "location": "query",
2744	//       "type": "integer"
2745	//     },
2746	//     "pageToken": {
2747	//       "description": "The standard list page token.",
2748	//       "location": "query",
2749	//       "type": "string"
2750	//     }
2751	//   },
2752	//   "path": "v1/{+name}/operations",
2753	//   "response": {
2754	//     "$ref": "ListOperationsResponse"
2755	//   },
2756	//   "scopes": [
2757	//     "https://www.googleapis.com/auth/cloud-platform"
2758	//   ]
2759	// }
2760
2761}
2762
2763// Pages invokes f for each page of results.
2764// A non-nil error returned from f will halt the iteration.
2765// The provided context supersedes any context provided to the Context method.
2766func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
2767	c.ctx_ = ctx
2768	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
2769	for {
2770		x, err := c.Do()
2771		if err != nil {
2772			return err
2773		}
2774		if err := f(x); err != nil {
2775			return err
2776		}
2777		if x.NextPageToken == "" {
2778			return nil
2779		}
2780		c.PageToken(x.NextPageToken)
2781	}
2782}
2783
2784// method id "ondemandscanning.projects.locations.operations.wait":
2785
2786type ProjectsLocationsOperationsWaitCall struct {
2787	s          *Service
2788	name       string
2789	urlParams_ gensupport.URLParams
2790	ctx_       context.Context
2791	header_    http.Header
2792}
2793
2794// Wait: Waits until the specified long-running operation is done or
2795// reaches at most a specified timeout, returning the latest state. If
2796// the operation is already done, the latest state is immediately
2797// returned. If the timeout specified is greater than the default
2798// HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does
2799// not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
2800// Note that this method is on a best-effort basis. It may return the
2801// latest state before the specified timeout (including immediately),
2802// meaning even an immediate response is no guarantee that the operation
2803// is done.
2804//
2805// - name: The name of the operation resource to wait on.
2806func (r *ProjectsLocationsOperationsService) Wait(name string) *ProjectsLocationsOperationsWaitCall {
2807	c := &ProjectsLocationsOperationsWaitCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2808	c.name = name
2809	return c
2810}
2811
2812// Timeout sets the optional parameter "timeout": The maximum duration
2813// to wait before timing out. If left blank, the wait will be at most
2814// the time permitted by the underlying HTTP/RPC protocol. If RPC
2815// context deadline is also specified, the shorter one will be used.
2816func (c *ProjectsLocationsOperationsWaitCall) Timeout(timeout string) *ProjectsLocationsOperationsWaitCall {
2817	c.urlParams_.Set("timeout", timeout)
2818	return c
2819}
2820
2821// Fields allows partial responses to be retrieved. See
2822// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2823// for more information.
2824func (c *ProjectsLocationsOperationsWaitCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsWaitCall {
2825	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2826	return c
2827}
2828
2829// Context sets the context to be used in this call's Do method. Any
2830// pending HTTP request will be aborted if the provided context is
2831// canceled.
2832func (c *ProjectsLocationsOperationsWaitCall) Context(ctx context.Context) *ProjectsLocationsOperationsWaitCall {
2833	c.ctx_ = ctx
2834	return c
2835}
2836
2837// Header returns an http.Header that can be modified by the caller to
2838// add HTTP headers to the request.
2839func (c *ProjectsLocationsOperationsWaitCall) Header() http.Header {
2840	if c.header_ == nil {
2841		c.header_ = make(http.Header)
2842	}
2843	return c.header_
2844}
2845
2846func (c *ProjectsLocationsOperationsWaitCall) doRequest(alt string) (*http.Response, error) {
2847	reqHeaders := make(http.Header)
2848	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
2849	for k, v := range c.header_ {
2850		reqHeaders[k] = v
2851	}
2852	reqHeaders.Set("User-Agent", c.s.userAgent())
2853	var body io.Reader = nil
2854	c.urlParams_.Set("alt", alt)
2855	c.urlParams_.Set("prettyPrint", "false")
2856	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:wait")
2857	urls += "?" + c.urlParams_.Encode()
2858	req, err := http.NewRequest("POST", urls, body)
2859	if err != nil {
2860		return nil, err
2861	}
2862	req.Header = reqHeaders
2863	googleapi.Expand(req.URL, map[string]string{
2864		"name": c.name,
2865	})
2866	return gensupport.SendRequest(c.ctx_, c.s.client, req)
2867}
2868
2869// Do executes the "ondemandscanning.projects.locations.operations.wait" call.
2870// Exactly one of *Operation or error will be non-nil. Any non-2xx
2871// status code is an error. Response headers are in either
2872// *Operation.ServerResponse.Header or (if a response was returned at
2873// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
2874// to check whether the returned error was because
2875// http.StatusNotModified was returned.
2876func (c *ProjectsLocationsOperationsWaitCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
2877	gensupport.SetOptions(c.urlParams_, opts...)
2878	res, err := c.doRequest("json")
2879	if res != nil && res.StatusCode == http.StatusNotModified {
2880		if res.Body != nil {
2881			res.Body.Close()
2882		}
2883		return nil, &googleapi.Error{
2884			Code:   res.StatusCode,
2885			Header: res.Header,
2886		}
2887	}
2888	if err != nil {
2889		return nil, err
2890	}
2891	defer googleapi.CloseBody(res)
2892	if err := googleapi.CheckResponse(res); err != nil {
2893		return nil, err
2894	}
2895	ret := &Operation{
2896		ServerResponse: googleapi.ServerResponse{
2897			Header:         res.Header,
2898			HTTPStatusCode: res.StatusCode,
2899		},
2900	}
2901	target := &ret
2902	if err := gensupport.DecodeResponse(target, res); err != nil {
2903		return nil, err
2904	}
2905	return ret, nil
2906	// {
2907	//   "description": "Waits until the specified long-running operation is done or reaches at most a specified timeout, returning the latest state. If the operation is already done, the latest state is immediately returned. If the timeout specified is greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort basis. It may return the latest state before the specified timeout (including immediately), meaning even an immediate response is no guarantee that the operation is done.",
2908	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:wait",
2909	//   "httpMethod": "POST",
2910	//   "id": "ondemandscanning.projects.locations.operations.wait",
2911	//   "parameterOrder": [
2912	//     "name"
2913	//   ],
2914	//   "parameters": {
2915	//     "name": {
2916	//       "description": "The name of the operation resource to wait on.",
2917	//       "location": "path",
2918	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
2919	//       "required": true,
2920	//       "type": "string"
2921	//     },
2922	//     "timeout": {
2923	//       "description": "The maximum duration to wait before timing out. If left blank, the wait will be at most the time permitted by the underlying HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one will be used.",
2924	//       "format": "google-duration",
2925	//       "location": "query",
2926	//       "type": "string"
2927	//     }
2928	//   },
2929	//   "path": "v1/{+name}:wait",
2930	//   "response": {
2931	//     "$ref": "Operation"
2932	//   },
2933	//   "scopes": [
2934	//     "https://www.googleapis.com/auth/cloud-platform"
2935	//   ]
2936	// }
2937
2938}
2939
2940// method id "ondemandscanning.projects.locations.scans.analyzePackages":
2941
2942type ProjectsLocationsScansAnalyzePackagesCall struct {
2943	s                        *Service
2944	parent                   string
2945	analyzepackagesrequestv1 *AnalyzePackagesRequestV1
2946	urlParams_               gensupport.URLParams
2947	ctx_                     context.Context
2948	header_                  http.Header
2949}
2950
2951// AnalyzePackages: Initiates an analysis of the provided packages.
2952//
2953// - parent: The parent of the resource for which analysis is requested.
2954//   Format: projects/[project_name]/locations/[location].
2955func (r *ProjectsLocationsScansService) AnalyzePackages(parent string, analyzepackagesrequestv1 *AnalyzePackagesRequestV1) *ProjectsLocationsScansAnalyzePackagesCall {
2956	c := &ProjectsLocationsScansAnalyzePackagesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
2957	c.parent = parent
2958	c.analyzepackagesrequestv1 = analyzepackagesrequestv1
2959	return c
2960}
2961
2962// Fields allows partial responses to be retrieved. See
2963// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
2964// for more information.
2965func (c *ProjectsLocationsScansAnalyzePackagesCall) Fields(s ...googleapi.Field) *ProjectsLocationsScansAnalyzePackagesCall {
2966	c.urlParams_.Set("fields", googleapi.CombineFields(s))
2967	return c
2968}
2969
2970// Context sets the context to be used in this call's Do method. Any
2971// pending HTTP request will be aborted if the provided context is
2972// canceled.
2973func (c *ProjectsLocationsScansAnalyzePackagesCall) Context(ctx context.Context) *ProjectsLocationsScansAnalyzePackagesCall {
2974	c.ctx_ = ctx
2975	return c
2976}
2977
2978// Header returns an http.Header that can be modified by the caller to
2979// add HTTP headers to the request.
2980func (c *ProjectsLocationsScansAnalyzePackagesCall) Header() http.Header {
2981	if c.header_ == nil {
2982		c.header_ = make(http.Header)
2983	}
2984	return c.header_
2985}
2986
2987func (c *ProjectsLocationsScansAnalyzePackagesCall) doRequest(alt string) (*http.Response, error) {
2988	reqHeaders := make(http.Header)
2989	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
2990	for k, v := range c.header_ {
2991		reqHeaders[k] = v
2992	}
2993	reqHeaders.Set("User-Agent", c.s.userAgent())
2994	var body io.Reader = nil
2995	body, err := googleapi.WithoutDataWrapper.JSONReader(c.analyzepackagesrequestv1)
2996	if err != nil {
2997		return nil, err
2998	}
2999	reqHeaders.Set("Content-Type", "application/json")
3000	c.urlParams_.Set("alt", alt)
3001	c.urlParams_.Set("prettyPrint", "false")
3002	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/scans:analyzePackages")
3003	urls += "?" + c.urlParams_.Encode()
3004	req, err := http.NewRequest("POST", urls, body)
3005	if err != nil {
3006		return nil, err
3007	}
3008	req.Header = reqHeaders
3009	googleapi.Expand(req.URL, map[string]string{
3010		"parent": c.parent,
3011	})
3012	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3013}
3014
3015// Do executes the "ondemandscanning.projects.locations.scans.analyzePackages" call.
3016// Exactly one of *Operation or error will be non-nil. Any non-2xx
3017// status code is an error. Response headers are in either
3018// *Operation.ServerResponse.Header or (if a response was returned at
3019// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
3020// to check whether the returned error was because
3021// http.StatusNotModified was returned.
3022func (c *ProjectsLocationsScansAnalyzePackagesCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
3023	gensupport.SetOptions(c.urlParams_, opts...)
3024	res, err := c.doRequest("json")
3025	if res != nil && res.StatusCode == http.StatusNotModified {
3026		if res.Body != nil {
3027			res.Body.Close()
3028		}
3029		return nil, &googleapi.Error{
3030			Code:   res.StatusCode,
3031			Header: res.Header,
3032		}
3033	}
3034	if err != nil {
3035		return nil, err
3036	}
3037	defer googleapi.CloseBody(res)
3038	if err := googleapi.CheckResponse(res); err != nil {
3039		return nil, err
3040	}
3041	ret := &Operation{
3042		ServerResponse: googleapi.ServerResponse{
3043			Header:         res.Header,
3044			HTTPStatusCode: res.StatusCode,
3045		},
3046	}
3047	target := &ret
3048	if err := gensupport.DecodeResponse(target, res); err != nil {
3049		return nil, err
3050	}
3051	return ret, nil
3052	// {
3053	//   "description": "Initiates an analysis of the provided packages.",
3054	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/scans:analyzePackages",
3055	//   "httpMethod": "POST",
3056	//   "id": "ondemandscanning.projects.locations.scans.analyzePackages",
3057	//   "parameterOrder": [
3058	//     "parent"
3059	//   ],
3060	//   "parameters": {
3061	//     "parent": {
3062	//       "description": "Required. The parent of the resource for which analysis is requested. Format: projects/[project_name]/locations/[location]",
3063	//       "location": "path",
3064	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
3065	//       "required": true,
3066	//       "type": "string"
3067	//     }
3068	//   },
3069	//   "path": "v1/{+parent}/scans:analyzePackages",
3070	//   "request": {
3071	//     "$ref": "AnalyzePackagesRequestV1"
3072	//   },
3073	//   "response": {
3074	//     "$ref": "Operation"
3075	//   },
3076	//   "scopes": [
3077	//     "https://www.googleapis.com/auth/cloud-platform"
3078	//   ]
3079	// }
3080
3081}
3082
3083// method id "ondemandscanning.projects.locations.scans.vulnerabilities.list":
3084
3085type ProjectsLocationsScansVulnerabilitiesListCall struct {
3086	s            *Service
3087	parent       string
3088	urlParams_   gensupport.URLParams
3089	ifNoneMatch_ string
3090	ctx_         context.Context
3091	header_      http.Header
3092}
3093
3094// List: Lists vulnerabilities resulting from a successfully completed
3095// scan.
3096//
3097// - parent: The parent of the collection of Vulnerabilities being
3098//   requested. Format:
3099//   projects/[project_name]/locations/[location]/scans/[scan_id].
3100func (r *ProjectsLocationsScansVulnerabilitiesService) List(parent string) *ProjectsLocationsScansVulnerabilitiesListCall {
3101	c := &ProjectsLocationsScansVulnerabilitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3102	c.parent = parent
3103	return c
3104}
3105
3106// PageSize sets the optional parameter "pageSize": The number of
3107// vulnerabilities to retrieve.
3108func (c *ProjectsLocationsScansVulnerabilitiesListCall) PageSize(pageSize int64) *ProjectsLocationsScansVulnerabilitiesListCall {
3109	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
3110	return c
3111}
3112
3113// PageToken sets the optional parameter "pageToken": The page token,
3114// resulting from a previous call to ListVulnerabilities.
3115func (c *ProjectsLocationsScansVulnerabilitiesListCall) PageToken(pageToken string) *ProjectsLocationsScansVulnerabilitiesListCall {
3116	c.urlParams_.Set("pageToken", pageToken)
3117	return c
3118}
3119
3120// Fields allows partial responses to be retrieved. See
3121// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3122// for more information.
3123func (c *ProjectsLocationsScansVulnerabilitiesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsScansVulnerabilitiesListCall {
3124	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3125	return c
3126}
3127
3128// IfNoneMatch sets the optional parameter which makes the operation
3129// fail if the object's ETag matches the given value. This is useful for
3130// getting updates only after the object has changed since the last
3131// request. Use googleapi.IsNotModified to check whether the response
3132// error from Do is the result of In-None-Match.
3133func (c *ProjectsLocationsScansVulnerabilitiesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsScansVulnerabilitiesListCall {
3134	c.ifNoneMatch_ = entityTag
3135	return c
3136}
3137
3138// Context sets the context to be used in this call's Do method. Any
3139// pending HTTP request will be aborted if the provided context is
3140// canceled.
3141func (c *ProjectsLocationsScansVulnerabilitiesListCall) Context(ctx context.Context) *ProjectsLocationsScansVulnerabilitiesListCall {
3142	c.ctx_ = ctx
3143	return c
3144}
3145
3146// Header returns an http.Header that can be modified by the caller to
3147// add HTTP headers to the request.
3148func (c *ProjectsLocationsScansVulnerabilitiesListCall) Header() http.Header {
3149	if c.header_ == nil {
3150		c.header_ = make(http.Header)
3151	}
3152	return c.header_
3153}
3154
3155func (c *ProjectsLocationsScansVulnerabilitiesListCall) doRequest(alt string) (*http.Response, error) {
3156	reqHeaders := make(http.Header)
3157	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
3158	for k, v := range c.header_ {
3159		reqHeaders[k] = v
3160	}
3161	reqHeaders.Set("User-Agent", c.s.userAgent())
3162	if c.ifNoneMatch_ != "" {
3163		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
3164	}
3165	var body io.Reader = nil
3166	c.urlParams_.Set("alt", alt)
3167	c.urlParams_.Set("prettyPrint", "false")
3168	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/vulnerabilities")
3169	urls += "?" + c.urlParams_.Encode()
3170	req, err := http.NewRequest("GET", urls, body)
3171	if err != nil {
3172		return nil, err
3173	}
3174	req.Header = reqHeaders
3175	googleapi.Expand(req.URL, map[string]string{
3176		"parent": c.parent,
3177	})
3178	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3179}
3180
3181// Do executes the "ondemandscanning.projects.locations.scans.vulnerabilities.list" call.
3182// Exactly one of *ListVulnerabilitiesResponseV1 or error will be
3183// non-nil. Any non-2xx status code is an error. Response headers are in
3184// either *ListVulnerabilitiesResponseV1.ServerResponse.Header or (if a
3185// response was returned at all) in error.(*googleapi.Error).Header. Use
3186// googleapi.IsNotModified to check whether the returned error was
3187// because http.StatusNotModified was returned.
3188func (c *ProjectsLocationsScansVulnerabilitiesListCall) Do(opts ...googleapi.CallOption) (*ListVulnerabilitiesResponseV1, error) {
3189	gensupport.SetOptions(c.urlParams_, opts...)
3190	res, err := c.doRequest("json")
3191	if res != nil && res.StatusCode == http.StatusNotModified {
3192		if res.Body != nil {
3193			res.Body.Close()
3194		}
3195		return nil, &googleapi.Error{
3196			Code:   res.StatusCode,
3197			Header: res.Header,
3198		}
3199	}
3200	if err != nil {
3201		return nil, err
3202	}
3203	defer googleapi.CloseBody(res)
3204	if err := googleapi.CheckResponse(res); err != nil {
3205		return nil, err
3206	}
3207	ret := &ListVulnerabilitiesResponseV1{
3208		ServerResponse: googleapi.ServerResponse{
3209			Header:         res.Header,
3210			HTTPStatusCode: res.StatusCode,
3211		},
3212	}
3213	target := &ret
3214	if err := gensupport.DecodeResponse(target, res); err != nil {
3215		return nil, err
3216	}
3217	return ret, nil
3218	// {
3219	//   "description": "Lists vulnerabilities resulting from a successfully completed scan.",
3220	//   "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/scans/{scansId}/vulnerabilities",
3221	//   "httpMethod": "GET",
3222	//   "id": "ondemandscanning.projects.locations.scans.vulnerabilities.list",
3223	//   "parameterOrder": [
3224	//     "parent"
3225	//   ],
3226	//   "parameters": {
3227	//     "pageSize": {
3228	//       "description": "The number of vulnerabilities to retrieve.",
3229	//       "format": "int32",
3230	//       "location": "query",
3231	//       "type": "integer"
3232	//     },
3233	//     "pageToken": {
3234	//       "description": "The page token, resulting from a previous call to ListVulnerabilities.",
3235	//       "location": "query",
3236	//       "type": "string"
3237	//     },
3238	//     "parent": {
3239	//       "description": "Required. The parent of the collection of Vulnerabilities being requested. Format: projects/[project_name]/locations/[location]/scans/[scan_id]",
3240	//       "location": "path",
3241	//       "pattern": "^projects/[^/]+/locations/[^/]+/scans/[^/]+$",
3242	//       "required": true,
3243	//       "type": "string"
3244	//     }
3245	//   },
3246	//   "path": "v1/{+parent}/vulnerabilities",
3247	//   "response": {
3248	//     "$ref": "ListVulnerabilitiesResponseV1"
3249	//   },
3250	//   "scopes": [
3251	//     "https://www.googleapis.com/auth/cloud-platform"
3252	//   ]
3253	// }
3254
3255}
3256
3257// Pages invokes f for each page of results.
3258// A non-nil error returned from f will halt the iteration.
3259// The provided context supersedes any context provided to the Context method.
3260func (c *ProjectsLocationsScansVulnerabilitiesListCall) Pages(ctx context.Context, f func(*ListVulnerabilitiesResponseV1) error) error {
3261	c.ctx_ = ctx
3262	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
3263	for {
3264		x, err := c.Do()
3265		if err != nil {
3266			return err
3267		}
3268		if err := f(x); err != nil {
3269			return err
3270		}
3271		if x.NextPageToken == "" {
3272			return nil
3273		}
3274		c.PageToken(x.NextPageToken)
3275	}
3276}
3277