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 containeranalysis provides access to the Container Analysis API.
8//
9// For product documentation, see: https://cloud.google.com/container-analysis/api/reference/rest/
10//
11// Creating a client
12//
13// Usage example:
14//
15//   import "google.golang.org/api/containeranalysis/v1beta1"
16//   ...
17//   ctx := context.Background()
18//   containeranalysisService, err := containeranalysis.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//   containeranalysisService, err := containeranalysis.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//   containeranalysisService, err := containeranalysis.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
36//
37// See https://godoc.org/google.golang.org/api/option/ for details on options.
38package containeranalysis // import "google.golang.org/api/containeranalysis/v1beta1"
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 = "containeranalysis:v1beta1"
75const apiName = "containeranalysis"
76const apiVersion = "v1beta1"
77const basePath = "https://containeranalysis.googleapis.com/"
78const mtlsBasePath = "https://containeranalysis.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.Notes = NewProjectsNotesService(s)
141	rs.Occurrences = NewProjectsOccurrencesService(s)
142	rs.ScanConfigs = NewProjectsScanConfigsService(s)
143	return rs
144}
145
146type ProjectsService struct {
147	s *Service
148
149	Notes *ProjectsNotesService
150
151	Occurrences *ProjectsOccurrencesService
152
153	ScanConfigs *ProjectsScanConfigsService
154}
155
156func NewProjectsNotesService(s *Service) *ProjectsNotesService {
157	rs := &ProjectsNotesService{s: s}
158	rs.Occurrences = NewProjectsNotesOccurrencesService(s)
159	return rs
160}
161
162type ProjectsNotesService struct {
163	s *Service
164
165	Occurrences *ProjectsNotesOccurrencesService
166}
167
168func NewProjectsNotesOccurrencesService(s *Service) *ProjectsNotesOccurrencesService {
169	rs := &ProjectsNotesOccurrencesService{s: s}
170	return rs
171}
172
173type ProjectsNotesOccurrencesService struct {
174	s *Service
175}
176
177func NewProjectsOccurrencesService(s *Service) *ProjectsOccurrencesService {
178	rs := &ProjectsOccurrencesService{s: s}
179	return rs
180}
181
182type ProjectsOccurrencesService struct {
183	s *Service
184}
185
186func NewProjectsScanConfigsService(s *Service) *ProjectsScanConfigsService {
187	rs := &ProjectsScanConfigsService{s: s}
188	return rs
189}
190
191type ProjectsScanConfigsService 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// Artifact: Artifact describes a build product.
234type Artifact struct {
235	// Checksum: Hash or checksum value of a binary, or Docker Registry 2.0
236	// digest of a container.
237	Checksum string `json:"checksum,omitempty"`
238
239	// Id: Artifact ID, if any; for container images, this will be a URL by
240	// digest like `gcr.io/projectID/imagename@sha256:123456`.
241	Id string `json:"id,omitempty"`
242
243	// Names: Related artifact names. This may be the path to a binary or
244	// jar file, or in the case of a container build, the name used to push
245	// the container image to Google Container Registry, as presented to
246	// `docker push`. Note that a single Artifact ID can have multiple
247	// names, for example if two tags are applied to one image.
248	Names []string `json:"names,omitempty"`
249
250	// ForceSendFields is a list of field names (e.g. "Checksum") to
251	// unconditionally include in API requests. By default, fields with
252	// empty values are omitted from API requests. However, any non-pointer,
253	// non-interface field appearing in ForceSendFields will be sent to the
254	// server regardless of whether the field is empty or not. This may be
255	// used to include empty fields in Patch requests.
256	ForceSendFields []string `json:"-"`
257
258	// NullFields is a list of field names (e.g. "Checksum") to include in
259	// API requests with the JSON null value. By default, fields with empty
260	// values are omitted from API requests. However, any field with an
261	// empty value appearing in NullFields will be sent to the server as
262	// null. It is an error if a field in this list has a non-empty value.
263	// This may be used to include null fields in Patch requests.
264	NullFields []string `json:"-"`
265}
266
267func (s *Artifact) MarshalJSON() ([]byte, error) {
268	type NoMethod Artifact
269	raw := NoMethod(*s)
270	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
271}
272
273// ArtifactHashes: Defines a hash object for use in Materials and
274// Products.
275type ArtifactHashes struct {
276	Sha256 string `json:"sha256,omitempty"`
277
278	// ForceSendFields is a list of field names (e.g. "Sha256") to
279	// unconditionally include in API requests. By default, fields with
280	// empty values are omitted from API requests. However, any non-pointer,
281	// non-interface field appearing in ForceSendFields will be sent to the
282	// server regardless of whether the field is empty or not. This may be
283	// used to include empty fields in Patch requests.
284	ForceSendFields []string `json:"-"`
285
286	// NullFields is a list of field names (e.g. "Sha256") to include in API
287	// requests with the JSON null value. By default, fields with empty
288	// values are omitted from API requests. However, any field with an
289	// empty value appearing in NullFields will be sent to the server as
290	// null. It is an error if a field in this list has a non-empty value.
291	// This may be used to include null fields in Patch requests.
292	NullFields []string `json:"-"`
293}
294
295func (s *ArtifactHashes) MarshalJSON() ([]byte, error) {
296	type NoMethod ArtifactHashes
297	raw := NoMethod(*s)
298	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
299}
300
301// ArtifactRule: Defines an object to declare an in-toto artifact rule
302type ArtifactRule struct {
303	ArtifactRule []string `json:"artifactRule,omitempty"`
304
305	// ForceSendFields is a list of field names (e.g. "ArtifactRule") to
306	// unconditionally include in API requests. By default, fields with
307	// empty values are omitted from API requests. However, any non-pointer,
308	// non-interface field appearing in ForceSendFields will be sent to the
309	// server regardless of whether the field is empty or not. This may be
310	// used to include empty fields in Patch requests.
311	ForceSendFields []string `json:"-"`
312
313	// NullFields is a list of field names (e.g. "ArtifactRule") to include
314	// in API requests with the JSON null value. By default, fields with
315	// empty values are omitted from API requests. However, any field with
316	// an empty value appearing in NullFields will be sent to the server as
317	// null. It is an error if a field in this list has a non-empty value.
318	// This may be used to include null fields in Patch requests.
319	NullFields []string `json:"-"`
320}
321
322func (s *ArtifactRule) MarshalJSON() ([]byte, error) {
323	type NoMethod ArtifactRule
324	raw := NoMethod(*s)
325	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
326}
327
328// Attestation: Occurrence that represents a single "attestation". The
329// authenticity of an attestation can be verified using the attached
330// signature. If the verifier trusts the public key of the signer, then
331// verifying the signature is sufficient to establish trust. In this
332// circumstance, the authority to which this attestation is attached is
333// primarily useful for look-up (how to find this attestation if you
334// already know the authority and artifact to be verified) and intent
335// (which authority was this attestation intended to sign for).
336type Attestation struct {
337	GenericSignedAttestation *GenericSignedAttestation `json:"genericSignedAttestation,omitempty"`
338
339	// PgpSignedAttestation: A PGP signed attestation.
340	PgpSignedAttestation *PgpSignedAttestation `json:"pgpSignedAttestation,omitempty"`
341
342	// ForceSendFields is a list of field names (e.g.
343	// "GenericSignedAttestation") to unconditionally include in API
344	// requests. By default, fields with empty values are omitted from API
345	// requests. However, any non-pointer, non-interface field appearing in
346	// ForceSendFields will be sent to the server regardless of whether the
347	// field is empty or not. This may be used to include empty fields in
348	// Patch requests.
349	ForceSendFields []string `json:"-"`
350
351	// NullFields is a list of field names (e.g. "GenericSignedAttestation")
352	// to include in API requests with the JSON null value. By default,
353	// fields with empty values are omitted from API requests. However, any
354	// field with an empty value appearing in NullFields will be sent to the
355	// server as null. It is an error if a field in this list has a
356	// non-empty value. This may be used to include null fields in Patch
357	// requests.
358	NullFields []string `json:"-"`
359}
360
361func (s *Attestation) MarshalJSON() ([]byte, error) {
362	type NoMethod Attestation
363	raw := NoMethod(*s)
364	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
365}
366
367// Authority: Note kind that represents a logical attestation "role" or
368// "authority". For example, an organization might have one `Authority`
369// for "QA" and one for "build". This note is intended to act strictly
370// as a grouping mechanism for the attached occurrences (Attestations).
371// This grouping mechanism also provides a security boundary, since IAM
372// ACLs gate the ability for a principle to attach an occurrence to a
373// given note. It also provides a single point of lookup to find all
374// attached attestation occurrences, even if they don't all live in the
375// same project.
376type Authority struct {
377	// Hint: Hint hints at the purpose of the attestation authority.
378	Hint *Hint `json:"hint,omitempty"`
379
380	// ForceSendFields is a list of field names (e.g. "Hint") to
381	// unconditionally include in API requests. By default, fields with
382	// empty values are omitted from API requests. However, any non-pointer,
383	// non-interface field appearing in ForceSendFields will be sent to the
384	// server regardless of whether the field is empty or not. This may be
385	// used to include empty fields in Patch requests.
386	ForceSendFields []string `json:"-"`
387
388	// NullFields is a list of field names (e.g. "Hint") to include in API
389	// requests with the JSON null value. By default, fields with empty
390	// values are omitted from API requests. However, any field with an
391	// empty value appearing in NullFields will be sent to the server as
392	// null. It is an error if a field in this list has a non-empty value.
393	// This may be used to include null fields in Patch requests.
394	NullFields []string `json:"-"`
395}
396
397func (s *Authority) MarshalJSON() ([]byte, error) {
398	type NoMethod Authority
399	raw := NoMethod(*s)
400	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
401}
402
403// Basis: Basis describes the base image portion (Note) of the
404// DockerImage relationship. Linked occurrences are derived from this or
405// an equivalent image via: FROM Or an equivalent reference, e.g. a tag
406// of the resource_url.
407type Basis struct {
408	// Fingerprint: Required. Immutable. The fingerprint of the base image.
409	Fingerprint *Fingerprint `json:"fingerprint,omitempty"`
410
411	// ResourceUrl: Required. Immutable. The resource_url for the resource
412	// representing the basis of associated occurrence images.
413	ResourceUrl string `json:"resourceUrl,omitempty"`
414
415	// ForceSendFields is a list of field names (e.g. "Fingerprint") to
416	// unconditionally include in API requests. By default, fields with
417	// empty values are omitted from API requests. However, any non-pointer,
418	// non-interface field appearing in ForceSendFields will be sent to the
419	// server regardless of whether the field is empty or not. This may be
420	// used to include empty fields in Patch requests.
421	ForceSendFields []string `json:"-"`
422
423	// NullFields is a list of field names (e.g. "Fingerprint") to include
424	// in API requests with the JSON null value. By default, fields with
425	// empty values are omitted from API requests. However, any field with
426	// an empty value appearing in NullFields will be sent to the server as
427	// null. It is an error if a field in this list has a non-empty value.
428	// This may be used to include null fields in Patch requests.
429	NullFields []string `json:"-"`
430}
431
432func (s *Basis) MarshalJSON() ([]byte, error) {
433	type NoMethod Basis
434	raw := NoMethod(*s)
435	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
436}
437
438// BatchCreateNotesRequest: Request to create notes in batch.
439type BatchCreateNotesRequest struct {
440	// Notes: Required. The notes to create, the key is expected to be the
441	// note ID. Max allowed length is 1000.
442	Notes map[string]Note `json:"notes,omitempty"`
443
444	// ForceSendFields is a list of field names (e.g. "Notes") to
445	// unconditionally include in API requests. By default, fields with
446	// empty values are omitted from API requests. However, any non-pointer,
447	// non-interface field appearing in ForceSendFields will be sent to the
448	// server regardless of whether the field is empty or not. This may be
449	// used to include empty fields in Patch requests.
450	ForceSendFields []string `json:"-"`
451
452	// NullFields is a list of field names (e.g. "Notes") to include in API
453	// requests with the JSON null value. By default, fields with empty
454	// values are omitted from API requests. However, any field with an
455	// empty value appearing in NullFields will be sent to the server as
456	// null. It is an error if a field in this list has a non-empty value.
457	// This may be used to include null fields in Patch requests.
458	NullFields []string `json:"-"`
459}
460
461func (s *BatchCreateNotesRequest) MarshalJSON() ([]byte, error) {
462	type NoMethod BatchCreateNotesRequest
463	raw := NoMethod(*s)
464	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
465}
466
467// BatchCreateNotesResponse: Response for creating notes in batch.
468type BatchCreateNotesResponse struct {
469	// Notes: The notes that were created.
470	Notes []*Note `json:"notes,omitempty"`
471
472	// ServerResponse contains the HTTP response code and headers from the
473	// server.
474	googleapi.ServerResponse `json:"-"`
475
476	// ForceSendFields is a list of field names (e.g. "Notes") to
477	// unconditionally include in API requests. By default, fields with
478	// empty values are omitted from API requests. However, any non-pointer,
479	// non-interface field appearing in ForceSendFields will be sent to the
480	// server regardless of whether the field is empty or not. This may be
481	// used to include empty fields in Patch requests.
482	ForceSendFields []string `json:"-"`
483
484	// NullFields is a list of field names (e.g. "Notes") to include in API
485	// requests with the JSON null value. By default, fields with empty
486	// values are omitted from API requests. However, any field with an
487	// empty value appearing in NullFields will be sent to the server as
488	// null. It is an error if a field in this list has a non-empty value.
489	// This may be used to include null fields in Patch requests.
490	NullFields []string `json:"-"`
491}
492
493func (s *BatchCreateNotesResponse) MarshalJSON() ([]byte, error) {
494	type NoMethod BatchCreateNotesResponse
495	raw := NoMethod(*s)
496	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
497}
498
499// BatchCreateOccurrencesRequest: Request to create occurrences in
500// batch.
501type BatchCreateOccurrencesRequest struct {
502	// Occurrences: Required. The occurrences to create. Max allowed length
503	// is 1000.
504	Occurrences []*Occurrence `json:"occurrences,omitempty"`
505
506	// ForceSendFields is a list of field names (e.g. "Occurrences") to
507	// unconditionally include in API requests. By default, fields with
508	// empty values are omitted from API requests. However, any non-pointer,
509	// non-interface field appearing in ForceSendFields will be sent to the
510	// server regardless of whether the field is empty or not. This may be
511	// used to include empty fields in Patch requests.
512	ForceSendFields []string `json:"-"`
513
514	// NullFields is a list of field names (e.g. "Occurrences") to include
515	// in API requests with the JSON null value. By default, fields with
516	// empty values are omitted from API requests. However, any field with
517	// an empty value appearing in NullFields will be sent to the server as
518	// null. It is an error if a field in this list has a non-empty value.
519	// This may be used to include null fields in Patch requests.
520	NullFields []string `json:"-"`
521}
522
523func (s *BatchCreateOccurrencesRequest) MarshalJSON() ([]byte, error) {
524	type NoMethod BatchCreateOccurrencesRequest
525	raw := NoMethod(*s)
526	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
527}
528
529// BatchCreateOccurrencesResponse: Response for creating occurrences in
530// batch.
531type BatchCreateOccurrencesResponse struct {
532	// Occurrences: The occurrences that were created.
533	Occurrences []*Occurrence `json:"occurrences,omitempty"`
534
535	// ServerResponse contains the HTTP response code and headers from the
536	// server.
537	googleapi.ServerResponse `json:"-"`
538
539	// ForceSendFields is a list of field names (e.g. "Occurrences") to
540	// unconditionally include in API requests. By default, fields with
541	// empty values are omitted from API requests. However, any non-pointer,
542	// non-interface field appearing in ForceSendFields will be sent to the
543	// server regardless of whether the field is empty or not. This may be
544	// used to include empty fields in Patch requests.
545	ForceSendFields []string `json:"-"`
546
547	// NullFields is a list of field names (e.g. "Occurrences") to include
548	// in API requests with the JSON null value. By default, fields with
549	// empty values are omitted from API requests. However, any field with
550	// an empty value appearing in NullFields will be sent to the server as
551	// null. It is an error if a field in this list has a non-empty value.
552	// This may be used to include null fields in Patch requests.
553	NullFields []string `json:"-"`
554}
555
556func (s *BatchCreateOccurrencesResponse) MarshalJSON() ([]byte, error) {
557	type NoMethod BatchCreateOccurrencesResponse
558	raw := NoMethod(*s)
559	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
560}
561
562// Binding: Associates `members` with a `role`.
563type Binding struct {
564	// Condition: The condition that is associated with this binding. If the
565	// condition evaluates to `true`, then this binding applies to the
566	// current request. If the condition evaluates to `false`, then this
567	// binding does not apply to the current request. However, a different
568	// role binding might grant the same role to one or more of the members
569	// in this binding. To learn which resources support conditions in their
570	// IAM policies, see the IAM documentation
571	// (https://cloud.google.com/iam/help/conditions/resource-policies).
572	Condition *Expr `json:"condition,omitempty"`
573
574	// Members: Specifies the identities requesting access for a Cloud
575	// Platform resource. `members` can have the following values: *
576	// `allUsers`: A special identifier that represents anyone who is on the
577	// internet; with or without a Google account. *
578	// `allAuthenticatedUsers`: A special identifier that represents anyone
579	// who is authenticated with a Google account or a service account. *
580	// `user:{emailid}`: An email address that represents a specific Google
581	// account. For example, `alice@example.com` . *
582	// `serviceAccount:{emailid}`: An email address that represents a
583	// service account. For example,
584	// `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An
585	// email address that represents a Google group. For example,
586	// `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An
587	// email address (plus unique identifier) representing a user that has
588	// been recently deleted. For example,
589	// `alice@example.com?uid=123456789012345678901`. If the user is
590	// recovered, this value reverts to `user:{emailid}` and the recovered
591	// user retains the role in the binding. *
592	// `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address
593	// (plus unique identifier) representing a service account that has been
594	// recently deleted. For example,
595	// `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
596	// If the service account is undeleted, this value reverts to
597	// `serviceAccount:{emailid}` and the undeleted service account retains
598	// the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`:
599	// An email address (plus unique identifier) representing a Google group
600	// that has been recently deleted. For example,
601	// `admins@example.com?uid=123456789012345678901`. If the group is
602	// recovered, this value reverts to `group:{emailid}` and the recovered
603	// group retains the role in the binding. * `domain:{domain}`: The G
604	// Suite domain (primary) that represents all the users of that domain.
605	// For example, `google.com` or `example.com`.
606	Members []string `json:"members,omitempty"`
607
608	// Role: Role that is assigned to `members`. For example,
609	// `roles/viewer`, `roles/editor`, or `roles/owner`.
610	Role string `json:"role,omitempty"`
611
612	// ForceSendFields is a list of field names (e.g. "Condition") to
613	// unconditionally include in API requests. By default, fields with
614	// empty values are omitted from API requests. However, any non-pointer,
615	// non-interface field appearing in ForceSendFields will be sent to the
616	// server regardless of whether the field is empty or not. This may be
617	// used to include empty fields in Patch requests.
618	ForceSendFields []string `json:"-"`
619
620	// NullFields is a list of field names (e.g. "Condition") to include in
621	// API requests with the JSON null value. By default, fields with empty
622	// values are omitted from API requests. However, any field with an
623	// empty value appearing in NullFields will be sent to the server as
624	// null. It is an error if a field in this list has a non-empty value.
625	// This may be used to include null fields in Patch requests.
626	NullFields []string `json:"-"`
627}
628
629func (s *Binding) MarshalJSON() ([]byte, error) {
630	type NoMethod Binding
631	raw := NoMethod(*s)
632	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
633}
634
635// Build: Note holding the version of the provider's builder and the
636// signature of the provenance message in the build details occurrence.
637type Build struct {
638	// BuilderVersion: Required. Immutable. Version of the builder which
639	// produced this build.
640	BuilderVersion string `json:"builderVersion,omitempty"`
641
642	// Signature: Signature of the build in occurrences pointing to this
643	// build note containing build details.
644	Signature *BuildSignature `json:"signature,omitempty"`
645
646	// ForceSendFields is a list of field names (e.g. "BuilderVersion") to
647	// unconditionally include in API requests. By default, fields with
648	// empty values are omitted from API requests. However, any non-pointer,
649	// non-interface field appearing in ForceSendFields will be sent to the
650	// server regardless of whether the field is empty or not. This may be
651	// used to include empty fields in Patch requests.
652	ForceSendFields []string `json:"-"`
653
654	// NullFields is a list of field names (e.g. "BuilderVersion") to
655	// include in API requests with the JSON null value. By default, fields
656	// with empty values are omitted from API requests. However, any field
657	// with an empty value appearing in NullFields will be sent to the
658	// server as null. It is an error if a field in this list has a
659	// non-empty value. This may be used to include null fields in Patch
660	// requests.
661	NullFields []string `json:"-"`
662}
663
664func (s *Build) MarshalJSON() ([]byte, error) {
665	type NoMethod Build
666	raw := NoMethod(*s)
667	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
668}
669
670// BuildProvenance: Provenance of a build. Contains all information
671// needed to verify the full details about the build from source to
672// completion.
673type BuildProvenance struct {
674	// BuildOptions: Special options applied to this build. This is a
675	// catch-all field where build providers can enter any desired
676	// additional details.
677	BuildOptions map[string]string `json:"buildOptions,omitempty"`
678
679	// BuilderVersion: Version string of the builder at the time this build
680	// was executed.
681	BuilderVersion string `json:"builderVersion,omitempty"`
682
683	// BuiltArtifacts: Output of the build.
684	BuiltArtifacts []*Artifact `json:"builtArtifacts,omitempty"`
685
686	// Commands: Commands requested by the build.
687	Commands []*Command `json:"commands,omitempty"`
688
689	// CreateTime: Time at which the build was created.
690	CreateTime string `json:"createTime,omitempty"`
691
692	// Creator: E-mail address of the user who initiated this build. Note
693	// that this was the user's e-mail address at the time the build was
694	// initiated; this address may not represent the same end-user for all
695	// time.
696	Creator string `json:"creator,omitempty"`
697
698	// EndTime: Time at which execution of the build was finished.
699	EndTime string `json:"endTime,omitempty"`
700
701	// Id: Required. Unique identifier of the build.
702	Id string `json:"id,omitempty"`
703
704	// LogsUri: URI where any logs for this provenance were written.
705	LogsUri string `json:"logsUri,omitempty"`
706
707	// ProjectId: ID of the project.
708	ProjectId string `json:"projectId,omitempty"`
709
710	// SourceProvenance: Details of the Source input to the build.
711	SourceProvenance *Source `json:"sourceProvenance,omitempty"`
712
713	// StartTime: Time at which execution of the build was started.
714	StartTime string `json:"startTime,omitempty"`
715
716	// TriggerId: Trigger identifier if the build was triggered
717	// automatically; empty if not.
718	TriggerId string `json:"triggerId,omitempty"`
719
720	// ForceSendFields is a list of field names (e.g. "BuildOptions") to
721	// unconditionally include in API requests. By default, fields with
722	// empty values are omitted from API requests. However, any non-pointer,
723	// non-interface field appearing in ForceSendFields will be sent to the
724	// server regardless of whether the field is empty or not. This may be
725	// used to include empty fields in Patch requests.
726	ForceSendFields []string `json:"-"`
727
728	// NullFields is a list of field names (e.g. "BuildOptions") to include
729	// in API requests with the JSON null value. By default, fields with
730	// empty values are omitted from API requests. However, any field with
731	// an empty value appearing in NullFields will be sent to the server as
732	// null. It is an error if a field in this list has a non-empty value.
733	// This may be used to include null fields in Patch requests.
734	NullFields []string `json:"-"`
735}
736
737func (s *BuildProvenance) MarshalJSON() ([]byte, error) {
738	type NoMethod BuildProvenance
739	raw := NoMethod(*s)
740	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
741}
742
743// BuildSignature: Message encapsulating the signature of the verified
744// build.
745type BuildSignature struct {
746	// KeyId: An ID for the key used to sign. This could be either an ID for
747	// the key stored in `public_key` (such as the ID or fingerprint for a
748	// PGP key, or the CN for a cert), or a reference to an external key
749	// (such as a reference to a key in Cloud Key Management Service).
750	KeyId string `json:"keyId,omitempty"`
751
752	// KeyType: The type of the key, either stored in `public_key` or
753	// referenced in `key_id`.
754	//
755	// Possible values:
756	//   "KEY_TYPE_UNSPECIFIED" - `KeyType` is not set.
757	//   "PGP_ASCII_ARMORED" - `PGP ASCII Armored` public key.
758	//   "PKIX_PEM" - `PKIX PEM` public key.
759	KeyType string `json:"keyType,omitempty"`
760
761	// PublicKey: Public key of the builder which can be used to verify that
762	// the related findings are valid and unchanged. If `key_type` is empty,
763	// this defaults to PEM encoded public keys. This field may be empty if
764	// `key_id` references an external key. For Cloud Build based
765	// signatures, this is a PEM encoded public key. To verify the Cloud
766	// Build signature, place the contents of this field into a file
767	// (public.pem). The signature field is base64-decoded into its binary
768	// representation in signature.bin, and the provenance bytes from
769	// `BuildDetails` are base64-decoded into a binary representation in
770	// signed.bin. OpenSSL can then verify the signature: `openssl sha256
771	// -verify public.pem -signature signature.bin signed.bin`
772	PublicKey string `json:"publicKey,omitempty"`
773
774	// Signature: Required. Signature of the related `BuildProvenance`. In
775	// JSON, this is base-64 encoded.
776	Signature string `json:"signature,omitempty"`
777
778	// ForceSendFields is a list of field names (e.g. "KeyId") to
779	// unconditionally include in API requests. By default, fields with
780	// empty values are omitted from API requests. However, any non-pointer,
781	// non-interface field appearing in ForceSendFields will be sent to the
782	// server regardless of whether the field is empty or not. This may be
783	// used to include empty fields in Patch requests.
784	ForceSendFields []string `json:"-"`
785
786	// NullFields is a list of field names (e.g. "KeyId") to include in API
787	// requests with the JSON null value. By default, fields with empty
788	// values are omitted from API requests. However, any field with an
789	// empty value appearing in NullFields will be sent to the server as
790	// null. It is an error if a field in this list has a non-empty value.
791	// This may be used to include null fields in Patch requests.
792	NullFields []string `json:"-"`
793}
794
795func (s *BuildSignature) MarshalJSON() ([]byte, error) {
796	type NoMethod BuildSignature
797	raw := NoMethod(*s)
798	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
799}
800
801// ByProducts: Defines an object for the byproducts field in in-toto
802// links. The suggested fields are "stderr", "stdout", and
803// "return-value".
804type ByProducts struct {
805	CustomValues map[string]string `json:"customValues,omitempty"`
806
807	// ForceSendFields is a list of field names (e.g. "CustomValues") to
808	// unconditionally include in API requests. By default, fields with
809	// empty values are omitted from API requests. However, any non-pointer,
810	// non-interface field appearing in ForceSendFields will be sent to the
811	// server regardless of whether the field is empty or not. This may be
812	// used to include empty fields in Patch requests.
813	ForceSendFields []string `json:"-"`
814
815	// NullFields is a list of field names (e.g. "CustomValues") to include
816	// in API requests with the JSON null value. By default, fields with
817	// empty values are omitted from API requests. However, any field with
818	// an empty value appearing in NullFields will be sent to the server as
819	// null. It is an error if a field in this list has a non-empty value.
820	// This may be used to include null fields in Patch requests.
821	NullFields []string `json:"-"`
822}
823
824func (s *ByProducts) MarshalJSON() ([]byte, error) {
825	type NoMethod ByProducts
826	raw := NoMethod(*s)
827	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
828}
829
830// CVSSv3: Common Vulnerability Scoring System version 3. For details,
831// see https://www.first.org/cvss/specification-document
832type CVSSv3 struct {
833	// Possible values:
834	//   "ATTACK_COMPLEXITY_UNSPECIFIED"
835	//   "ATTACK_COMPLEXITY_LOW"
836	//   "ATTACK_COMPLEXITY_HIGH"
837	AttackComplexity string `json:"attackComplexity,omitempty"`
838
839	// AttackVector: Base Metrics Represents the intrinsic characteristics
840	// of a vulnerability that are constant over time and across user
841	// environments.
842	//
843	// Possible values:
844	//   "ATTACK_VECTOR_UNSPECIFIED"
845	//   "ATTACK_VECTOR_NETWORK"
846	//   "ATTACK_VECTOR_ADJACENT"
847	//   "ATTACK_VECTOR_LOCAL"
848	//   "ATTACK_VECTOR_PHYSICAL"
849	AttackVector string `json:"attackVector,omitempty"`
850
851	// Possible values:
852	//   "IMPACT_UNSPECIFIED"
853	//   "IMPACT_HIGH"
854	//   "IMPACT_LOW"
855	//   "IMPACT_NONE"
856	AvailabilityImpact string `json:"availabilityImpact,omitempty"`
857
858	// BaseScore: The base score is a function of the base metric scores.
859	BaseScore float64 `json:"baseScore,omitempty"`
860
861	// Possible values:
862	//   "IMPACT_UNSPECIFIED"
863	//   "IMPACT_HIGH"
864	//   "IMPACT_LOW"
865	//   "IMPACT_NONE"
866	ConfidentialityImpact string `json:"confidentialityImpact,omitempty"`
867
868	ExploitabilityScore float64 `json:"exploitabilityScore,omitempty"`
869
870	ImpactScore float64 `json:"impactScore,omitempty"`
871
872	// Possible values:
873	//   "IMPACT_UNSPECIFIED"
874	//   "IMPACT_HIGH"
875	//   "IMPACT_LOW"
876	//   "IMPACT_NONE"
877	IntegrityImpact string `json:"integrityImpact,omitempty"`
878
879	// Possible values:
880	//   "PRIVILEGES_REQUIRED_UNSPECIFIED"
881	//   "PRIVILEGES_REQUIRED_NONE"
882	//   "PRIVILEGES_REQUIRED_LOW"
883	//   "PRIVILEGES_REQUIRED_HIGH"
884	PrivilegesRequired string `json:"privilegesRequired,omitempty"`
885
886	// Possible values:
887	//   "SCOPE_UNSPECIFIED"
888	//   "SCOPE_UNCHANGED"
889	//   "SCOPE_CHANGED"
890	Scope string `json:"scope,omitempty"`
891
892	// Possible values:
893	//   "USER_INTERACTION_UNSPECIFIED"
894	//   "USER_INTERACTION_NONE"
895	//   "USER_INTERACTION_REQUIRED"
896	UserInteraction string `json:"userInteraction,omitempty"`
897
898	// ForceSendFields is a list of field names (e.g. "AttackComplexity") to
899	// unconditionally include in API requests. By default, fields with
900	// empty values are omitted from API requests. However, any non-pointer,
901	// non-interface field appearing in ForceSendFields will be sent to the
902	// server regardless of whether the field is empty or not. This may be
903	// used to include empty fields in Patch requests.
904	ForceSendFields []string `json:"-"`
905
906	// NullFields is a list of field names (e.g. "AttackComplexity") to
907	// include in API requests with the JSON null value. By default, fields
908	// with empty values are omitted from API requests. However, any field
909	// with an empty value appearing in NullFields will be sent to the
910	// server as null. It is an error if a field in this list has a
911	// non-empty value. This may be used to include null fields in Patch
912	// requests.
913	NullFields []string `json:"-"`
914}
915
916func (s *CVSSv3) MarshalJSON() ([]byte, error) {
917	type NoMethod CVSSv3
918	raw := NoMethod(*s)
919	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
920}
921
922func (s *CVSSv3) UnmarshalJSON(data []byte) error {
923	type NoMethod CVSSv3
924	var s1 struct {
925		BaseScore           gensupport.JSONFloat64 `json:"baseScore"`
926		ExploitabilityScore gensupport.JSONFloat64 `json:"exploitabilityScore"`
927		ImpactScore         gensupport.JSONFloat64 `json:"impactScore"`
928		*NoMethod
929	}
930	s1.NoMethod = (*NoMethod)(s)
931	if err := json.Unmarshal(data, &s1); err != nil {
932		return err
933	}
934	s.BaseScore = float64(s1.BaseScore)
935	s.ExploitabilityScore = float64(s1.ExploitabilityScore)
936	s.ImpactScore = float64(s1.ImpactScore)
937	return nil
938}
939
940// CloudRepoSourceContext: A CloudRepoSourceContext denotes a particular
941// revision in a Google Cloud Source Repo.
942type CloudRepoSourceContext struct {
943	// AliasContext: An alias, which may be a branch or tag.
944	AliasContext *AliasContext `json:"aliasContext,omitempty"`
945
946	// RepoId: The ID of the repo.
947	RepoId *RepoId `json:"repoId,omitempty"`
948
949	// RevisionId: A revision ID.
950	RevisionId string `json:"revisionId,omitempty"`
951
952	// ForceSendFields is a list of field names (e.g. "AliasContext") to
953	// unconditionally include in API requests. By default, fields with
954	// empty values are omitted from API requests. However, any non-pointer,
955	// non-interface field appearing in ForceSendFields will be sent to the
956	// server regardless of whether the field is empty or not. This may be
957	// used to include empty fields in Patch requests.
958	ForceSendFields []string `json:"-"`
959
960	// NullFields is a list of field names (e.g. "AliasContext") to include
961	// in API requests with the JSON null value. By default, fields with
962	// empty values are omitted from API requests. However, any field with
963	// an empty value appearing in NullFields will be sent to the server as
964	// null. It is an error if a field in this list has a non-empty value.
965	// This may be used to include null fields in Patch requests.
966	NullFields []string `json:"-"`
967}
968
969func (s *CloudRepoSourceContext) MarshalJSON() ([]byte, error) {
970	type NoMethod CloudRepoSourceContext
971	raw := NoMethod(*s)
972	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
973}
974
975// Command: Command describes a step performed as part of the build
976// pipeline.
977type Command struct {
978	// Args: Command-line arguments used when executing this command.
979	Args []string `json:"args,omitempty"`
980
981	// Dir: Working directory (relative to project source root) used when
982	// running this command.
983	Dir string `json:"dir,omitempty"`
984
985	// Env: Environment variables set before running this command.
986	Env []string `json:"env,omitempty"`
987
988	// Id: Optional unique identifier for this command, used in wait_for to
989	// reference this command as a dependency.
990	Id string `json:"id,omitempty"`
991
992	// Name: Required. Name of the command, as presented on the command
993	// line, or if the command is packaged as a Docker container, as
994	// presented to `docker pull`.
995	Name string `json:"name,omitempty"`
996
997	// WaitFor: The ID(s) of the command(s) that this command depends on.
998	WaitFor []string `json:"waitFor,omitempty"`
999
1000	// ForceSendFields is a list of field names (e.g. "Args") to
1001	// unconditionally include in API requests. By default, fields with
1002	// empty values are omitted from API requests. However, any non-pointer,
1003	// non-interface field appearing in ForceSendFields will be sent to the
1004	// server regardless of whether the field is empty or not. This may be
1005	// used to include empty fields in Patch requests.
1006	ForceSendFields []string `json:"-"`
1007
1008	// NullFields is a list of field names (e.g. "Args") to include in API
1009	// requests with the JSON null value. By default, fields with empty
1010	// values are omitted from API requests. However, any field with an
1011	// empty value appearing in NullFields will be sent to the server as
1012	// null. It is an error if a field in this list has a non-empty value.
1013	// This may be used to include null fields in Patch requests.
1014	NullFields []string `json:"-"`
1015}
1016
1017func (s *Command) MarshalJSON() ([]byte, error) {
1018	type NoMethod Command
1019	raw := NoMethod(*s)
1020	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1021}
1022
1023// Deployable: An artifact that can be deployed in some runtime.
1024type Deployable struct {
1025	// ResourceUri: Required. Resource URI for the artifact being deployed.
1026	ResourceUri []string `json:"resourceUri,omitempty"`
1027
1028	// ForceSendFields is a list of field names (e.g. "ResourceUri") to
1029	// unconditionally include in API requests. By default, fields with
1030	// empty values are omitted from API requests. However, any non-pointer,
1031	// non-interface field appearing in ForceSendFields will be sent to the
1032	// server regardless of whether the field is empty or not. This may be
1033	// used to include empty fields in Patch requests.
1034	ForceSendFields []string `json:"-"`
1035
1036	// NullFields is a list of field names (e.g. "ResourceUri") to include
1037	// in API requests with the JSON null value. By default, fields with
1038	// empty values are omitted from API requests. However, any field with
1039	// an empty value appearing in NullFields will be sent to the server as
1040	// null. It is an error if a field in this list has a non-empty value.
1041	// This may be used to include null fields in Patch requests.
1042	NullFields []string `json:"-"`
1043}
1044
1045func (s *Deployable) MarshalJSON() ([]byte, error) {
1046	type NoMethod Deployable
1047	raw := NoMethod(*s)
1048	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1049}
1050
1051// Deployment: The period during which some deployable was active in a
1052// runtime.
1053type Deployment struct {
1054	// Address: Address of the runtime element hosting this deployment.
1055	Address string `json:"address,omitempty"`
1056
1057	// Config: Configuration used to create this deployment.
1058	Config string `json:"config,omitempty"`
1059
1060	// DeployTime: Required. Beginning of the lifetime of this deployment.
1061	DeployTime string `json:"deployTime,omitempty"`
1062
1063	// Platform: Platform hosting this deployment.
1064	//
1065	// Possible values:
1066	//   "PLATFORM_UNSPECIFIED" - Unknown.
1067	//   "GKE" - Google Container Engine.
1068	//   "FLEX" - Google App Engine: Flexible Environment.
1069	//   "CUSTOM" - Custom user-defined platform.
1070	Platform string `json:"platform,omitempty"`
1071
1072	// ResourceUri: Output only. Resource URI for the artifact being
1073	// deployed taken from the deployable field with the same name.
1074	ResourceUri []string `json:"resourceUri,omitempty"`
1075
1076	// UndeployTime: End of the lifetime of this deployment.
1077	UndeployTime string `json:"undeployTime,omitempty"`
1078
1079	// UserEmail: Identity of the user that triggered this deployment.
1080	UserEmail string `json:"userEmail,omitempty"`
1081
1082	// ForceSendFields is a list of field names (e.g. "Address") to
1083	// unconditionally include in API requests. By default, fields with
1084	// empty values are omitted from API requests. However, any non-pointer,
1085	// non-interface field appearing in ForceSendFields will be sent to the
1086	// server regardless of whether the field is empty or not. This may be
1087	// used to include empty fields in Patch requests.
1088	ForceSendFields []string `json:"-"`
1089
1090	// NullFields is a list of field names (e.g. "Address") to include in
1091	// API requests with the JSON null value. By default, fields with empty
1092	// values are omitted from API requests. However, any field with an
1093	// empty value appearing in NullFields will be sent to the server as
1094	// null. It is an error if a field in this list has a non-empty value.
1095	// This may be used to include null fields in Patch requests.
1096	NullFields []string `json:"-"`
1097}
1098
1099func (s *Deployment) MarshalJSON() ([]byte, error) {
1100	type NoMethod Deployment
1101	raw := NoMethod(*s)
1102	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1103}
1104
1105// Derived: Derived describes the derived image portion (Occurrence) of
1106// the DockerImage relationship. This image would be produced from a
1107// Dockerfile with FROM .
1108type Derived struct {
1109	// BaseResourceUrl: Output only. This contains the base image URL for
1110	// the derived image occurrence.
1111	BaseResourceUrl string `json:"baseResourceUrl,omitempty"`
1112
1113	// Distance: Output only. The number of layers by which this image
1114	// differs from the associated image basis.
1115	Distance int64 `json:"distance,omitempty"`
1116
1117	// Fingerprint: Required. The fingerprint of the derived image.
1118	Fingerprint *Fingerprint `json:"fingerprint,omitempty"`
1119
1120	// LayerInfo: This contains layer-specific metadata, if populated it has
1121	// length "distance" and is ordered with [distance] being the layer
1122	// immediately following the base image and [1] being the final layer.
1123	LayerInfo []*Layer `json:"layerInfo,omitempty"`
1124
1125	// ForceSendFields is a list of field names (e.g. "BaseResourceUrl") to
1126	// unconditionally include in API requests. By default, fields with
1127	// empty values are omitted from API requests. However, any non-pointer,
1128	// non-interface field appearing in ForceSendFields will be sent to the
1129	// server regardless of whether the field is empty or not. This may be
1130	// used to include empty fields in Patch requests.
1131	ForceSendFields []string `json:"-"`
1132
1133	// NullFields is a list of field names (e.g. "BaseResourceUrl") to
1134	// include in API requests with the JSON null value. By default, fields
1135	// with empty values are omitted from API requests. However, any field
1136	// with an empty value appearing in NullFields will be sent to the
1137	// server as null. It is an error if a field in this list has a
1138	// non-empty value. This may be used to include null fields in Patch
1139	// requests.
1140	NullFields []string `json:"-"`
1141}
1142
1143func (s *Derived) MarshalJSON() ([]byte, error) {
1144	type NoMethod Derived
1145	raw := NoMethod(*s)
1146	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1147}
1148
1149// Detail: Identifies all appearances of this vulnerability in the
1150// package for a specific distro/location. For example: glibc in
1151// cpe:/o:debian:debian_linux:8 for versions 2.1 - 2.2
1152type Detail struct {
1153	// CpeUri: Required. The CPE URI in cpe format
1154	// (https://cpe.mitre.org/specification/) in which the vulnerability
1155	// manifests. Examples include distro or storage location for vulnerable
1156	// jar.
1157	CpeUri string `json:"cpeUri,omitempty"`
1158
1159	// Description: A vendor-specific description of this note.
1160	Description string `json:"description,omitempty"`
1161
1162	// FixedLocation: The fix for this specific package version.
1163	FixedLocation *VulnerabilityLocation `json:"fixedLocation,omitempty"`
1164
1165	// IsObsolete: Whether this detail is obsolete. Occurrences are expected
1166	// not to point to obsolete details.
1167	IsObsolete bool `json:"isObsolete,omitempty"`
1168
1169	// MaxAffectedVersion: The max version of the package in which the
1170	// vulnerability exists.
1171	MaxAffectedVersion *Version `json:"maxAffectedVersion,omitempty"`
1172
1173	// MinAffectedVersion: The min version of the package in which the
1174	// vulnerability exists.
1175	MinAffectedVersion *Version `json:"minAffectedVersion,omitempty"`
1176
1177	// Package: Required. The name of the package where the vulnerability
1178	// was found.
1179	Package string `json:"package,omitempty"`
1180
1181	// PackageType: The type of package; whether native or non native(ruby
1182	// gems, node.js packages etc).
1183	PackageType string `json:"packageType,omitempty"`
1184
1185	// SeverityName: The severity (eg: distro assigned severity) for this
1186	// vulnerability.
1187	SeverityName string `json:"severityName,omitempty"`
1188
1189	// Source: The source from which the information in this Detail was
1190	// obtained.
1191	Source string `json:"source,omitempty"`
1192
1193	// SourceUpdateTime: The time this information was last changed at the
1194	// source. This is an upstream timestamp from the underlying information
1195	// source - e.g. Ubuntu security tracker.
1196	SourceUpdateTime string `json:"sourceUpdateTime,omitempty"`
1197
1198	// Vendor: The name of the vendor of the product.
1199	Vendor string `json:"vendor,omitempty"`
1200
1201	// ForceSendFields is a list of field names (e.g. "CpeUri") to
1202	// unconditionally include in API requests. By default, fields with
1203	// empty values are omitted from API requests. However, any non-pointer,
1204	// non-interface field appearing in ForceSendFields will be sent to the
1205	// server regardless of whether the field is empty or not. This may be
1206	// used to include empty fields in Patch requests.
1207	ForceSendFields []string `json:"-"`
1208
1209	// NullFields is a list of field names (e.g. "CpeUri") to include in API
1210	// requests with the JSON null value. By default, fields with empty
1211	// values are omitted from API requests. However, any field with an
1212	// empty value appearing in NullFields will be sent to the server as
1213	// null. It is an error if a field in this list has a non-empty value.
1214	// This may be used to include null fields in Patch requests.
1215	NullFields []string `json:"-"`
1216}
1217
1218func (s *Detail) MarshalJSON() ([]byte, error) {
1219	type NoMethod Detail
1220	raw := NoMethod(*s)
1221	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1222}
1223
1224// Details: Details of an attestation occurrence.
1225type Details struct {
1226	// Attestation: Required. Attestation for the resource.
1227	Attestation *Attestation `json:"attestation,omitempty"`
1228
1229	// ForceSendFields is a list of field names (e.g. "Attestation") to
1230	// unconditionally include in API requests. By default, fields with
1231	// empty values are omitted from API requests. However, any non-pointer,
1232	// non-interface field appearing in ForceSendFields will be sent to the
1233	// server regardless of whether the field is empty or not. This may be
1234	// used to include empty fields in Patch requests.
1235	ForceSendFields []string `json:"-"`
1236
1237	// NullFields is a list of field names (e.g. "Attestation") to include
1238	// in API requests with the JSON null value. By default, fields with
1239	// empty values are omitted from API requests. However, any field with
1240	// an empty value appearing in NullFields will be sent to the server as
1241	// null. It is an error if a field in this list has a non-empty value.
1242	// This may be used to include null fields in Patch requests.
1243	NullFields []string `json:"-"`
1244}
1245
1246func (s *Details) MarshalJSON() ([]byte, error) {
1247	type NoMethod Details
1248	raw := NoMethod(*s)
1249	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1250}
1251
1252// Discovered: Provides information about the analysis status of a
1253// discovered resource.
1254type Discovered struct {
1255	// AnalysisStatus: The status of discovery for the resource.
1256	//
1257	// Possible values:
1258	//   "ANALYSIS_STATUS_UNSPECIFIED" - Unknown.
1259	//   "PENDING" - Resource is known but no action has been taken yet.
1260	//   "SCANNING" - Resource is being analyzed.
1261	//   "FINISHED_SUCCESS" - Analysis has finished successfully.
1262	//   "FINISHED_FAILED" - Analysis has finished unsuccessfully, the
1263	// analysis itself is in a bad state.
1264	//   "FINISHED_UNSUPPORTED" - The resource is known not to be supported
1265	AnalysisStatus string `json:"analysisStatus,omitempty"`
1266
1267	// AnalysisStatusError: When an error is encountered this will contain a
1268	// LocalizedMessage under details to show to the user. The
1269	// LocalizedMessage is output only and populated by the API.
1270	AnalysisStatusError *Status `json:"analysisStatusError,omitempty"`
1271
1272	// ContinuousAnalysis: Whether the resource is continuously analyzed.
1273	//
1274	// Possible values:
1275	//   "CONTINUOUS_ANALYSIS_UNSPECIFIED" - Unknown.
1276	//   "ACTIVE" - The resource is continuously analyzed.
1277	//   "INACTIVE" - The resource is ignored for continuous analysis.
1278	ContinuousAnalysis string `json:"continuousAnalysis,omitempty"`
1279
1280	// LastAnalysisTime: The last time continuous analysis was done for this
1281	// resource. Deprecated, do not use.
1282	LastAnalysisTime string `json:"lastAnalysisTime,omitempty"`
1283
1284	// ForceSendFields is a list of field names (e.g. "AnalysisStatus") to
1285	// unconditionally include in API requests. By default, fields with
1286	// empty values are omitted from API requests. However, any non-pointer,
1287	// non-interface field appearing in ForceSendFields will be sent to the
1288	// server regardless of whether the field is empty or not. This may be
1289	// used to include empty fields in Patch requests.
1290	ForceSendFields []string `json:"-"`
1291
1292	// NullFields is a list of field names (e.g. "AnalysisStatus") to
1293	// include in API requests with the JSON null value. By default, fields
1294	// with empty values are omitted from API requests. However, any field
1295	// with an empty value appearing in NullFields will be sent to the
1296	// server as null. It is an error if a field in this list has a
1297	// non-empty value. This may be used to include null fields in Patch
1298	// requests.
1299	NullFields []string `json:"-"`
1300}
1301
1302func (s *Discovered) MarshalJSON() ([]byte, error) {
1303	type NoMethod Discovered
1304	raw := NoMethod(*s)
1305	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1306}
1307
1308// Discovery: A note that indicates a type of analysis a provider would
1309// perform. This note exists in a provider's project. A `Discovery`
1310// occurrence is created in a consumer's project at the start of
1311// analysis.
1312type Discovery struct {
1313	// AnalysisKind: Required. Immutable. The kind of analysis that is
1314	// handled by this discovery.
1315	//
1316	// Possible values:
1317	//   "NOTE_KIND_UNSPECIFIED" - Default value. This value is unused.
1318	//   "VULNERABILITY" - The note and occurrence represent a package
1319	// vulnerability.
1320	//   "BUILD" - The note and occurrence assert build provenance.
1321	//   "IMAGE" - This represents an image basis relationship.
1322	//   "PACKAGE" - This represents a package installed via a package
1323	// manager.
1324	//   "DEPLOYMENT" - The note and occurrence track deployment events.
1325	//   "DISCOVERY" - The note and occurrence track the initial discovery
1326	// status of a resource.
1327	//   "ATTESTATION" - This represents a logical "role" that can attest to
1328	// artifacts.
1329	//   "INTOTO" - This represents an in-toto link.
1330	AnalysisKind string `json:"analysisKind,omitempty"`
1331
1332	// ForceSendFields is a list of field names (e.g. "AnalysisKind") to
1333	// unconditionally include in API requests. By default, fields with
1334	// empty values are omitted from API requests. However, any non-pointer,
1335	// non-interface field appearing in ForceSendFields will be sent to the
1336	// server regardless of whether the field is empty or not. This may be
1337	// used to include empty fields in Patch requests.
1338	ForceSendFields []string `json:"-"`
1339
1340	// NullFields is a list of field names (e.g. "AnalysisKind") to include
1341	// in API requests with the JSON null value. By default, fields with
1342	// empty values are omitted from API requests. However, any field with
1343	// an empty value appearing in NullFields will be sent to the server as
1344	// null. It is an error if a field in this list has a non-empty value.
1345	// This may be used to include null fields in Patch requests.
1346	NullFields []string `json:"-"`
1347}
1348
1349func (s *Discovery) MarshalJSON() ([]byte, error) {
1350	type NoMethod Discovery
1351	raw := NoMethod(*s)
1352	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1353}
1354
1355// Distribution: This represents a particular channel of distribution
1356// for a given package. E.g., Debian's jessie-backports dpkg mirror.
1357type Distribution struct {
1358	// Architecture: The CPU architecture for which packages in this
1359	// distribution channel were built.
1360	//
1361	// Possible values:
1362	//   "ARCHITECTURE_UNSPECIFIED" - Unknown architecture.
1363	//   "X86" - X86 architecture.
1364	//   "X64" - X64 architecture.
1365	Architecture string `json:"architecture,omitempty"`
1366
1367	// CpeUri: Required. The cpe_uri in CPE format
1368	// (https://cpe.mitre.org/specification/) denoting the package manager
1369	// version distributing a package.
1370	CpeUri string `json:"cpeUri,omitempty"`
1371
1372	// Description: The distribution channel-specific description of this
1373	// package.
1374	Description string `json:"description,omitempty"`
1375
1376	// LatestVersion: The latest available version of this package in this
1377	// distribution channel.
1378	LatestVersion *Version `json:"latestVersion,omitempty"`
1379
1380	// Maintainer: A freeform string denoting the maintainer of this
1381	// package.
1382	Maintainer string `json:"maintainer,omitempty"`
1383
1384	// Url: The distribution channel-specific homepage for this package.
1385	Url string `json:"url,omitempty"`
1386
1387	// ForceSendFields is a list of field names (e.g. "Architecture") to
1388	// unconditionally include in API requests. By default, fields with
1389	// empty values are omitted from API requests. However, any non-pointer,
1390	// non-interface field appearing in ForceSendFields will be sent to the
1391	// server regardless of whether the field is empty or not. This may be
1392	// used to include empty fields in Patch requests.
1393	ForceSendFields []string `json:"-"`
1394
1395	// NullFields is a list of field names (e.g. "Architecture") to include
1396	// in API requests with the JSON null value. By default, fields with
1397	// empty values are omitted from API requests. However, any field with
1398	// an empty value appearing in NullFields will be sent to the server as
1399	// null. It is an error if a field in this list has a non-empty value.
1400	// This may be used to include null fields in Patch requests.
1401	NullFields []string `json:"-"`
1402}
1403
1404func (s *Distribution) MarshalJSON() ([]byte, error) {
1405	type NoMethod Distribution
1406	raw := NoMethod(*s)
1407	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1408}
1409
1410// Empty: A generic empty message that you can re-use to avoid defining
1411// duplicated empty messages in your APIs. A typical example is to use
1412// it as the request or the response type of an API method. For
1413// instance: service Foo { rpc Bar(google.protobuf.Empty) returns
1414// (google.protobuf.Empty); } The JSON representation for `Empty` is
1415// empty JSON object `{}`.
1416type Empty struct {
1417	// ServerResponse contains the HTTP response code and headers from the
1418	// server.
1419	googleapi.ServerResponse `json:"-"`
1420}
1421
1422// Environment: Defines an object for the environment field in in-toto
1423// links. The suggested fields are "variables", "filesystem", and
1424// "workdir".
1425type Environment struct {
1426	CustomValues map[string]string `json:"customValues,omitempty"`
1427
1428	// ForceSendFields is a list of field names (e.g. "CustomValues") to
1429	// unconditionally include in API requests. By default, fields with
1430	// empty values are omitted from API requests. However, any non-pointer,
1431	// non-interface field appearing in ForceSendFields will be sent to the
1432	// server regardless of whether the field is empty or not. This may be
1433	// used to include empty fields in Patch requests.
1434	ForceSendFields []string `json:"-"`
1435
1436	// NullFields is a list of field names (e.g. "CustomValues") to include
1437	// in API requests with the JSON null value. By default, fields with
1438	// empty values are omitted from API requests. However, any field with
1439	// an empty value appearing in NullFields will be sent to the server as
1440	// null. It is an error if a field in this list has a non-empty value.
1441	// This may be used to include null fields in Patch requests.
1442	NullFields []string `json:"-"`
1443}
1444
1445func (s *Environment) MarshalJSON() ([]byte, error) {
1446	type NoMethod Environment
1447	raw := NoMethod(*s)
1448	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1449}
1450
1451// Expr: Represents a textual expression in the Common Expression
1452// Language (CEL) syntax. CEL is a C-like expression language. The
1453// syntax and semantics of CEL are documented at
1454// https://github.com/google/cel-spec. Example (Comparison): title:
1455// "Summary size limit" description: "Determines if a summary is less
1456// than 100 chars" expression: "document.summary.size() < 100" Example
1457// (Equality): title: "Requestor is owner" description: "Determines if
1458// requestor is the document owner" expression: "document.owner ==
1459// request.auth.claims.email" Example (Logic): title: "Public documents"
1460// description: "Determine whether the document should be publicly
1461// visible" expression: "document.type != 'private' && document.type !=
1462// 'internal'" Example (Data Manipulation): title: "Notification string"
1463// description: "Create a notification string with a timestamp."
1464// expression: "'New message received at ' +
1465// string(document.create_time)" The exact variables and functions that
1466// may be referenced within an expression are determined by the service
1467// that evaluates it. See the service documentation for additional
1468// information.
1469type Expr struct {
1470	// Description: Optional. Description of the expression. This is a
1471	// longer text which describes the expression, e.g. when hovered over it
1472	// in a UI.
1473	Description string `json:"description,omitempty"`
1474
1475	// Expression: Textual representation of an expression in Common
1476	// Expression Language syntax.
1477	Expression string `json:"expression,omitempty"`
1478
1479	// Location: Optional. String indicating the location of the expression
1480	// for error reporting, e.g. a file name and a position in the file.
1481	Location string `json:"location,omitempty"`
1482
1483	// Title: Optional. Title for the expression, i.e. a short string
1484	// describing its purpose. This can be used e.g. in UIs which allow to
1485	// enter the expression.
1486	Title string `json:"title,omitempty"`
1487
1488	// ForceSendFields is a list of field names (e.g. "Description") to
1489	// unconditionally include in API requests. By default, fields with
1490	// empty values are omitted from API requests. However, any non-pointer,
1491	// non-interface field appearing in ForceSendFields will be sent to the
1492	// server regardless of whether the field is empty or not. This may be
1493	// used to include empty fields in Patch requests.
1494	ForceSendFields []string `json:"-"`
1495
1496	// NullFields is a list of field names (e.g. "Description") to include
1497	// in API requests with the JSON null value. By default, fields with
1498	// empty values are omitted from API requests. However, any field with
1499	// an empty value appearing in NullFields will be sent to the server as
1500	// null. It is an error if a field in this list has a non-empty value.
1501	// This may be used to include null fields in Patch requests.
1502	NullFields []string `json:"-"`
1503}
1504
1505func (s *Expr) MarshalJSON() ([]byte, error) {
1506	type NoMethod Expr
1507	raw := NoMethod(*s)
1508	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1509}
1510
1511// FileHashes: Container message for hashes of byte content of files,
1512// used in source messages to verify integrity of source input to the
1513// build.
1514type FileHashes struct {
1515	// FileHash: Required. Collection of file hashes.
1516	FileHash []*Hash `json:"fileHash,omitempty"`
1517
1518	// ForceSendFields is a list of field names (e.g. "FileHash") to
1519	// unconditionally include in API requests. By default, fields with
1520	// empty values are omitted from API requests. However, any non-pointer,
1521	// non-interface field appearing in ForceSendFields will be sent to the
1522	// server regardless of whether the field is empty or not. This may be
1523	// used to include empty fields in Patch requests.
1524	ForceSendFields []string `json:"-"`
1525
1526	// NullFields is a list of field names (e.g. "FileHash") to include in
1527	// API requests with the JSON null value. By default, fields with empty
1528	// values are omitted from API requests. However, any field with an
1529	// empty value appearing in NullFields will be sent to the server as
1530	// null. It is an error if a field in this list has a non-empty value.
1531	// This may be used to include null fields in Patch requests.
1532	NullFields []string `json:"-"`
1533}
1534
1535func (s *FileHashes) MarshalJSON() ([]byte, error) {
1536	type NoMethod FileHashes
1537	raw := NoMethod(*s)
1538	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1539}
1540
1541// Fingerprint: A set of properties that uniquely identify a given
1542// Docker image.
1543type Fingerprint struct {
1544	// V1Name: Required. The layer ID of the final layer in the Docker
1545	// image's v1 representation.
1546	V1Name string `json:"v1Name,omitempty"`
1547
1548	// V2Blob: Required. The ordered list of v2 blobs that represent a given
1549	// image.
1550	V2Blob []string `json:"v2Blob,omitempty"`
1551
1552	// V2Name: Output only. The name of the image's v2 blobs computed via:
1553	// [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1])
1554	// Only the name of the final blob is kept.
1555	V2Name string `json:"v2Name,omitempty"`
1556
1557	// ForceSendFields is a list of field names (e.g. "V1Name") to
1558	// unconditionally include in API requests. By default, fields with
1559	// empty values are omitted from API requests. However, any non-pointer,
1560	// non-interface field appearing in ForceSendFields will be sent to the
1561	// server regardless of whether the field is empty or not. This may be
1562	// used to include empty fields in Patch requests.
1563	ForceSendFields []string `json:"-"`
1564
1565	// NullFields is a list of field names (e.g. "V1Name") to include in API
1566	// requests with the JSON null value. By default, fields with empty
1567	// values are omitted from API requests. However, any field with an
1568	// empty value appearing in NullFields will be sent to the server as
1569	// null. It is an error if a field in this list has a non-empty value.
1570	// This may be used to include null fields in Patch requests.
1571	NullFields []string `json:"-"`
1572}
1573
1574func (s *Fingerprint) MarshalJSON() ([]byte, error) {
1575	type NoMethod Fingerprint
1576	raw := NoMethod(*s)
1577	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1578}
1579
1580// FixableTotalByDigest: Per resource and severity counts of fixable and
1581// total vulnerabilities.
1582type FixableTotalByDigest struct {
1583	// FixableCount: The number of fixable vulnerabilities associated with
1584	// this resource.
1585	FixableCount int64 `json:"fixableCount,omitempty,string"`
1586
1587	// Resource: The affected resource.
1588	Resource *Resource `json:"resource,omitempty"`
1589
1590	// Severity: The severity for this count. SEVERITY_UNSPECIFIED indicates
1591	// total across all severities.
1592	//
1593	// Possible values:
1594	//   "SEVERITY_UNSPECIFIED" - Unknown.
1595	//   "MINIMAL" - Minimal severity.
1596	//   "LOW" - Low severity.
1597	//   "MEDIUM" - Medium severity.
1598	//   "HIGH" - High severity.
1599	//   "CRITICAL" - Critical severity.
1600	Severity string `json:"severity,omitempty"`
1601
1602	// TotalCount: The total number of vulnerabilities associated with this
1603	// resource.
1604	TotalCount int64 `json:"totalCount,omitempty,string"`
1605
1606	// ForceSendFields is a list of field names (e.g. "FixableCount") to
1607	// unconditionally include in API requests. By default, fields with
1608	// empty values are omitted from API requests. However, any non-pointer,
1609	// non-interface field appearing in ForceSendFields will be sent to the
1610	// server regardless of whether the field is empty or not. This may be
1611	// used to include empty fields in Patch requests.
1612	ForceSendFields []string `json:"-"`
1613
1614	// NullFields is a list of field names (e.g. "FixableCount") to include
1615	// in API requests with the JSON null value. By default, fields with
1616	// empty values are omitted from API requests. However, any field with
1617	// an empty value appearing in NullFields will be sent to the server as
1618	// null. It is an error if a field in this list has a non-empty value.
1619	// This may be used to include null fields in Patch requests.
1620	NullFields []string `json:"-"`
1621}
1622
1623func (s *FixableTotalByDigest) MarshalJSON() ([]byte, error) {
1624	type NoMethod FixableTotalByDigest
1625	raw := NoMethod(*s)
1626	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1627}
1628
1629// GenericSignedAttestation: An attestation wrapper that uses the
1630// Grafeas `Signature` message. This attestation must define the
1631// `serialized_payload` that the `signatures` verify and any metadata
1632// necessary to interpret that plaintext. The signatures should always
1633// be over the `serialized_payload` bytestring.
1634type GenericSignedAttestation struct {
1635	// ContentType: Type (for example schema) of the attestation payload
1636	// that was signed. The verifier must ensure that the provided type is
1637	// one that the verifier supports, and that the attestation payload is a
1638	// valid instantiation of that type (for example by validating a JSON
1639	// schema).
1640	//
1641	// Possible values:
1642	//   "CONTENT_TYPE_UNSPECIFIED" - `ContentType` is not set.
1643	//   "SIMPLE_SIGNING_JSON" - Atomic format attestation signature. See
1644	// https://github.com/containers/image/blob/8a5d2f82a6e3263290c8e0276c3e0f64e77723e7/docs/atomic-signature.md
1645	// The payload extracted in `plaintext` is a JSON blob conforming to the
1646	// linked schema.
1647	ContentType string `json:"contentType,omitempty"`
1648
1649	// SerializedPayload: The serialized payload that is verified by one or
1650	// more `signatures`. The encoding and semantic meaning of this payload
1651	// must match what is set in `content_type`.
1652	SerializedPayload string `json:"serializedPayload,omitempty"`
1653
1654	// Signatures: One or more signatures over `serialized_payload`.
1655	// Verifier implementations should consider this attestation message
1656	// verified if at least one `signature` verifies `serialized_payload`.
1657	// See `Signature` in common.proto for more details on signature
1658	// structure and verification.
1659	Signatures []*Signature `json:"signatures,omitempty"`
1660
1661	// ForceSendFields is a list of field names (e.g. "ContentType") to
1662	// unconditionally include in API requests. By default, fields with
1663	// empty values are omitted from API requests. However, any non-pointer,
1664	// non-interface field appearing in ForceSendFields will be sent to the
1665	// server regardless of whether the field is empty or not. This may be
1666	// used to include empty fields in Patch requests.
1667	ForceSendFields []string `json:"-"`
1668
1669	// NullFields is a list of field names (e.g. "ContentType") to include
1670	// in API requests with the JSON null value. By default, fields with
1671	// empty values are omitted from API requests. However, any field with
1672	// an empty value appearing in NullFields will be sent to the server as
1673	// null. It is an error if a field in this list has a non-empty value.
1674	// This may be used to include null fields in Patch requests.
1675	NullFields []string `json:"-"`
1676}
1677
1678func (s *GenericSignedAttestation) MarshalJSON() ([]byte, error) {
1679	type NoMethod GenericSignedAttestation
1680	raw := NoMethod(*s)
1681	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1682}
1683
1684// GerritSourceContext: A SourceContext referring to a Gerrit project.
1685type GerritSourceContext struct {
1686	// AliasContext: An alias, which may be a branch or tag.
1687	AliasContext *AliasContext `json:"aliasContext,omitempty"`
1688
1689	// GerritProject: The full project name within the host. Projects may be
1690	// nested, so "project/subproject" is a valid project name. The "repo
1691	// name" is the hostURI/project.
1692	GerritProject string `json:"gerritProject,omitempty"`
1693
1694	// HostUri: The URI of a running Gerrit instance.
1695	HostUri string `json:"hostUri,omitempty"`
1696
1697	// RevisionId: A revision (commit) ID.
1698	RevisionId string `json:"revisionId,omitempty"`
1699
1700	// ForceSendFields is a list of field names (e.g. "AliasContext") to
1701	// unconditionally include in API requests. By default, fields with
1702	// empty values are omitted from API requests. However, any non-pointer,
1703	// non-interface field appearing in ForceSendFields will be sent to the
1704	// server regardless of whether the field is empty or not. This may be
1705	// used to include empty fields in Patch requests.
1706	ForceSendFields []string `json:"-"`
1707
1708	// NullFields is a list of field names (e.g. "AliasContext") to include
1709	// in API requests with the JSON null value. By default, fields with
1710	// empty values are omitted from API requests. However, any field with
1711	// an empty value appearing in NullFields will be sent to the server as
1712	// null. It is an error if a field in this list has a non-empty value.
1713	// This may be used to include null fields in Patch requests.
1714	NullFields []string `json:"-"`
1715}
1716
1717func (s *GerritSourceContext) MarshalJSON() ([]byte, error) {
1718	type NoMethod GerritSourceContext
1719	raw := NoMethod(*s)
1720	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1721}
1722
1723// GetIamPolicyRequest: Request message for `GetIamPolicy` method.
1724type GetIamPolicyRequest struct {
1725	// Options: OPTIONAL: A `GetPolicyOptions` object for specifying options
1726	// to `GetIamPolicy`.
1727	Options *GetPolicyOptions `json:"options,omitempty"`
1728
1729	// ForceSendFields is a list of field names (e.g. "Options") to
1730	// unconditionally include in API requests. By default, fields with
1731	// empty values are omitted from API requests. However, any non-pointer,
1732	// non-interface field appearing in ForceSendFields will be sent to the
1733	// server regardless of whether the field is empty or not. This may be
1734	// used to include empty fields in Patch requests.
1735	ForceSendFields []string `json:"-"`
1736
1737	// NullFields is a list of field names (e.g. "Options") to include in
1738	// API requests with the JSON null value. By default, fields with empty
1739	// values are omitted from API requests. However, any field with an
1740	// empty value appearing in NullFields will be sent to the server as
1741	// null. It is an error if a field in this list has a non-empty value.
1742	// This may be used to include null fields in Patch requests.
1743	NullFields []string `json:"-"`
1744}
1745
1746func (s *GetIamPolicyRequest) MarshalJSON() ([]byte, error) {
1747	type NoMethod GetIamPolicyRequest
1748	raw := NoMethod(*s)
1749	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1750}
1751
1752// GetPolicyOptions: Encapsulates settings provided to GetIamPolicy.
1753type GetPolicyOptions struct {
1754	// RequestedPolicyVersion: Optional. The policy format version to be
1755	// returned. Valid values are 0, 1, and 3. Requests specifying an
1756	// invalid value will be rejected. Requests for policies with any
1757	// conditional bindings must specify version 3. Policies without any
1758	// conditional bindings may specify any valid value or leave the field
1759	// unset. To learn which resources support conditions in their IAM
1760	// policies, see the IAM documentation
1761	// (https://cloud.google.com/iam/help/conditions/resource-policies).
1762	RequestedPolicyVersion int64 `json:"requestedPolicyVersion,omitempty"`
1763
1764	// ForceSendFields is a list of field names (e.g.
1765	// "RequestedPolicyVersion") to unconditionally include in API requests.
1766	// By default, fields with empty values are omitted from API requests.
1767	// However, any non-pointer, non-interface field appearing in
1768	// ForceSendFields will be sent to the server regardless of whether the
1769	// field is empty or not. This may be used to include empty fields in
1770	// Patch requests.
1771	ForceSendFields []string `json:"-"`
1772
1773	// NullFields is a list of field names (e.g. "RequestedPolicyVersion")
1774	// to include in API requests with the JSON null value. By default,
1775	// fields with empty values are omitted from API requests. However, any
1776	// field with an empty value appearing in NullFields will be sent to the
1777	// server as null. It is an error if a field in this list has a
1778	// non-empty value. This may be used to include null fields in Patch
1779	// requests.
1780	NullFields []string `json:"-"`
1781}
1782
1783func (s *GetPolicyOptions) MarshalJSON() ([]byte, error) {
1784	type NoMethod GetPolicyOptions
1785	raw := NoMethod(*s)
1786	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1787}
1788
1789// GitSourceContext: A GitSourceContext denotes a particular revision in
1790// a third party Git repository (e.g., GitHub).
1791type GitSourceContext struct {
1792	// RevisionId: Git commit hash.
1793	RevisionId string `json:"revisionId,omitempty"`
1794
1795	// Url: Git repository URL.
1796	Url string `json:"url,omitempty"`
1797
1798	// ForceSendFields is a list of field names (e.g. "RevisionId") to
1799	// unconditionally include in API requests. By default, fields with
1800	// empty values are omitted from API requests. However, any non-pointer,
1801	// non-interface field appearing in ForceSendFields will be sent to the
1802	// server regardless of whether the field is empty or not. This may be
1803	// used to include empty fields in Patch requests.
1804	ForceSendFields []string `json:"-"`
1805
1806	// NullFields is a list of field names (e.g. "RevisionId") to include in
1807	// API requests with the JSON null value. By default, fields with empty
1808	// values are omitted from API requests. However, any field with an
1809	// empty value appearing in NullFields will be sent to the server as
1810	// null. It is an error if a field in this list has a non-empty value.
1811	// This may be used to include null fields in Patch requests.
1812	NullFields []string `json:"-"`
1813}
1814
1815func (s *GitSourceContext) MarshalJSON() ([]byte, error) {
1816	type NoMethod GitSourceContext
1817	raw := NoMethod(*s)
1818	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1819}
1820
1821// GoogleDevtoolsContaineranalysisV1alpha1OperationMetadata: Metadata
1822// for all operations used and required for all operations that created
1823// by Container Analysis Providers
1824type GoogleDevtoolsContaineranalysisV1alpha1OperationMetadata struct {
1825	// CreateTime: Output only. The time this operation was created.
1826	CreateTime string `json:"createTime,omitempty"`
1827
1828	// EndTime: Output only. The time that this operation was marked
1829	// completed or failed.
1830	EndTime string `json:"endTime,omitempty"`
1831
1832	// ForceSendFields is a list of field names (e.g. "CreateTime") to
1833	// unconditionally include in API requests. By default, fields with
1834	// empty values are omitted from API requests. However, any non-pointer,
1835	// non-interface field appearing in ForceSendFields will be sent to the
1836	// server regardless of whether the field is empty or not. This may be
1837	// used to include empty fields in Patch requests.
1838	ForceSendFields []string `json:"-"`
1839
1840	// NullFields is a list of field names (e.g. "CreateTime") to include in
1841	// API requests with the JSON null value. By default, fields with empty
1842	// values are omitted from API requests. However, any field with an
1843	// empty value appearing in NullFields will be sent to the server as
1844	// null. It is an error if a field in this list has a non-empty value.
1845	// This may be used to include null fields in Patch requests.
1846	NullFields []string `json:"-"`
1847}
1848
1849func (s *GoogleDevtoolsContaineranalysisV1alpha1OperationMetadata) MarshalJSON() ([]byte, error) {
1850	type NoMethod GoogleDevtoolsContaineranalysisV1alpha1OperationMetadata
1851	raw := NoMethod(*s)
1852	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1853}
1854
1855// GrafeasV1beta1BuildDetails: Details of a build occurrence.
1856type GrafeasV1beta1BuildDetails struct {
1857	// Provenance: Required. The actual provenance for the build.
1858	Provenance *BuildProvenance `json:"provenance,omitempty"`
1859
1860	// ProvenanceBytes: Serialized JSON representation of the provenance,
1861	// used in generating the build signature in the corresponding build
1862	// note. After verifying the signature, `provenance_bytes` can be
1863	// unmarshalled and compared to the provenance to confirm that it is
1864	// unchanged. A base64-encoded string representation of the provenance
1865	// bytes is used for the signature in order to interoperate with openssl
1866	// which expects this format for signature verification. The serialized
1867	// form is captured both to avoid ambiguity in how the provenance is
1868	// marshalled to json as well to prevent incompatibilities with future
1869	// changes.
1870	ProvenanceBytes string `json:"provenanceBytes,omitempty"`
1871
1872	// ForceSendFields is a list of field names (e.g. "Provenance") to
1873	// unconditionally include in API requests. By default, fields with
1874	// empty values are omitted from API requests. However, any non-pointer,
1875	// non-interface field appearing in ForceSendFields will be sent to the
1876	// server regardless of whether the field is empty or not. This may be
1877	// used to include empty fields in Patch requests.
1878	ForceSendFields []string `json:"-"`
1879
1880	// NullFields is a list of field names (e.g. "Provenance") to include in
1881	// API requests with the JSON null value. By default, fields with empty
1882	// values are omitted from API requests. However, any field with an
1883	// empty value appearing in NullFields will be sent to the server as
1884	// null. It is an error if a field in this list has a non-empty value.
1885	// This may be used to include null fields in Patch requests.
1886	NullFields []string `json:"-"`
1887}
1888
1889func (s *GrafeasV1beta1BuildDetails) MarshalJSON() ([]byte, error) {
1890	type NoMethod GrafeasV1beta1BuildDetails
1891	raw := NoMethod(*s)
1892	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1893}
1894
1895// GrafeasV1beta1DeploymentDetails: Details of a deployment occurrence.
1896type GrafeasV1beta1DeploymentDetails struct {
1897	// Deployment: Required. Deployment history for the resource.
1898	Deployment *Deployment `json:"deployment,omitempty"`
1899
1900	// ForceSendFields is a list of field names (e.g. "Deployment") to
1901	// unconditionally include in API requests. By default, fields with
1902	// empty values are omitted from API requests. However, any non-pointer,
1903	// non-interface field appearing in ForceSendFields will be sent to the
1904	// server regardless of whether the field is empty or not. This may be
1905	// used to include empty fields in Patch requests.
1906	ForceSendFields []string `json:"-"`
1907
1908	// NullFields is a list of field names (e.g. "Deployment") to include in
1909	// API requests with the JSON null value. By default, fields with empty
1910	// values are omitted from API requests. However, any field with an
1911	// empty value appearing in NullFields will be sent to the server as
1912	// null. It is an error if a field in this list has a non-empty value.
1913	// This may be used to include null fields in Patch requests.
1914	NullFields []string `json:"-"`
1915}
1916
1917func (s *GrafeasV1beta1DeploymentDetails) MarshalJSON() ([]byte, error) {
1918	type NoMethod GrafeasV1beta1DeploymentDetails
1919	raw := NoMethod(*s)
1920	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1921}
1922
1923// GrafeasV1beta1DiscoveryDetails: Details of a discovery occurrence.
1924type GrafeasV1beta1DiscoveryDetails struct {
1925	// Discovered: Required. Analysis status for the discovered resource.
1926	Discovered *Discovered `json:"discovered,omitempty"`
1927
1928	// ForceSendFields is a list of field names (e.g. "Discovered") to
1929	// unconditionally include in API requests. By default, fields with
1930	// empty values are omitted from API requests. However, any non-pointer,
1931	// non-interface field appearing in ForceSendFields will be sent to the
1932	// server regardless of whether the field is empty or not. This may be
1933	// used to include empty fields in Patch requests.
1934	ForceSendFields []string `json:"-"`
1935
1936	// NullFields is a list of field names (e.g. "Discovered") to include in
1937	// API requests with the JSON null value. By default, fields with empty
1938	// values are omitted from API requests. However, any field with an
1939	// empty value appearing in NullFields will be sent to the server as
1940	// null. It is an error if a field in this list has a non-empty value.
1941	// This may be used to include null fields in Patch requests.
1942	NullFields []string `json:"-"`
1943}
1944
1945func (s *GrafeasV1beta1DiscoveryDetails) MarshalJSON() ([]byte, error) {
1946	type NoMethod GrafeasV1beta1DiscoveryDetails
1947	raw := NoMethod(*s)
1948	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1949}
1950
1951// GrafeasV1beta1ImageDetails: Details of an image occurrence.
1952type GrafeasV1beta1ImageDetails struct {
1953	// DerivedImage: Required. Immutable. The child image derived from the
1954	// base image.
1955	DerivedImage *Derived `json:"derivedImage,omitempty"`
1956
1957	// ForceSendFields is a list of field names (e.g. "DerivedImage") to
1958	// unconditionally include in API requests. By default, fields with
1959	// empty values are omitted from API requests. However, any non-pointer,
1960	// non-interface field appearing in ForceSendFields will be sent to the
1961	// server regardless of whether the field is empty or not. This may be
1962	// used to include empty fields in Patch requests.
1963	ForceSendFields []string `json:"-"`
1964
1965	// NullFields is a list of field names (e.g. "DerivedImage") to include
1966	// in API requests with the JSON null value. By default, fields with
1967	// empty values are omitted from API requests. However, any field with
1968	// an empty value appearing in NullFields will be sent to the server as
1969	// null. It is an error if a field in this list has a non-empty value.
1970	// This may be used to include null fields in Patch requests.
1971	NullFields []string `json:"-"`
1972}
1973
1974func (s *GrafeasV1beta1ImageDetails) MarshalJSON() ([]byte, error) {
1975	type NoMethod GrafeasV1beta1ImageDetails
1976	raw := NoMethod(*s)
1977	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1978}
1979
1980type GrafeasV1beta1IntotoArtifact struct {
1981	Hashes *ArtifactHashes `json:"hashes,omitempty"`
1982
1983	ResourceUri string `json:"resourceUri,omitempty"`
1984
1985	// ForceSendFields is a list of field names (e.g. "Hashes") to
1986	// unconditionally include in API requests. By default, fields with
1987	// empty values are omitted from API requests. However, any non-pointer,
1988	// non-interface field appearing in ForceSendFields will be sent to the
1989	// server regardless of whether the field is empty or not. This may be
1990	// used to include empty fields in Patch requests.
1991	ForceSendFields []string `json:"-"`
1992
1993	// NullFields is a list of field names (e.g. "Hashes") to include in API
1994	// requests with the JSON null value. By default, fields with empty
1995	// values are omitted from API requests. However, any field with an
1996	// empty value appearing in NullFields will be sent to the server as
1997	// null. It is an error if a field in this list has a non-empty value.
1998	// This may be used to include null fields in Patch requests.
1999	NullFields []string `json:"-"`
2000}
2001
2002func (s *GrafeasV1beta1IntotoArtifact) MarshalJSON() ([]byte, error) {
2003	type NoMethod GrafeasV1beta1IntotoArtifact
2004	raw := NoMethod(*s)
2005	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2006}
2007
2008// GrafeasV1beta1IntotoDetails: This corresponds to a signed in-toto
2009// link - it is made up of one or more signatures and the in-toto link
2010// itself. This is used for occurrences of a Grafeas in-toto note.
2011type GrafeasV1beta1IntotoDetails struct {
2012	Signatures []*GrafeasV1beta1IntotoSignature `json:"signatures,omitempty"`
2013
2014	Signed *Link `json:"signed,omitempty"`
2015
2016	// ForceSendFields is a list of field names (e.g. "Signatures") to
2017	// unconditionally include in API requests. By default, fields with
2018	// empty values are omitted from API requests. However, any non-pointer,
2019	// non-interface field appearing in ForceSendFields will be sent to the
2020	// server regardless of whether the field is empty or not. This may be
2021	// used to include empty fields in Patch requests.
2022	ForceSendFields []string `json:"-"`
2023
2024	// NullFields is a list of field names (e.g. "Signatures") to include in
2025	// API requests with the JSON null value. By default, fields with empty
2026	// values are omitted from API requests. However, any field with an
2027	// empty value appearing in NullFields will be sent to the server as
2028	// null. It is an error if a field in this list has a non-empty value.
2029	// This may be used to include null fields in Patch requests.
2030	NullFields []string `json:"-"`
2031}
2032
2033func (s *GrafeasV1beta1IntotoDetails) MarshalJSON() ([]byte, error) {
2034	type NoMethod GrafeasV1beta1IntotoDetails
2035	raw := NoMethod(*s)
2036	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2037}
2038
2039// GrafeasV1beta1IntotoSignature: A signature object consists of the
2040// KeyID used and the signature itself.
2041type GrafeasV1beta1IntotoSignature struct {
2042	Keyid string `json:"keyid,omitempty"`
2043
2044	Sig string `json:"sig,omitempty"`
2045
2046	// ForceSendFields is a list of field names (e.g. "Keyid") to
2047	// unconditionally include in API requests. By default, fields with
2048	// empty values are omitted from API requests. However, any non-pointer,
2049	// non-interface field appearing in ForceSendFields will be sent to the
2050	// server regardless of whether the field is empty or not. This may be
2051	// used to include empty fields in Patch requests.
2052	ForceSendFields []string `json:"-"`
2053
2054	// NullFields is a list of field names (e.g. "Keyid") to include in API
2055	// requests with the JSON null value. By default, fields with empty
2056	// values are omitted from API requests. However, any field with an
2057	// empty value appearing in NullFields will be sent to the server as
2058	// null. It is an error if a field in this list has a non-empty value.
2059	// This may be used to include null fields in Patch requests.
2060	NullFields []string `json:"-"`
2061}
2062
2063func (s *GrafeasV1beta1IntotoSignature) MarshalJSON() ([]byte, error) {
2064	type NoMethod GrafeasV1beta1IntotoSignature
2065	raw := NoMethod(*s)
2066	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2067}
2068
2069// GrafeasV1beta1PackageDetails: Details of a package occurrence.
2070type GrafeasV1beta1PackageDetails struct {
2071	// Installation: Required. Where the package was installed.
2072	Installation *Installation `json:"installation,omitempty"`
2073
2074	// ForceSendFields is a list of field names (e.g. "Installation") to
2075	// unconditionally include in API requests. By default, fields with
2076	// empty values are omitted from API requests. However, any non-pointer,
2077	// non-interface field appearing in ForceSendFields will be sent to the
2078	// server regardless of whether the field is empty or not. This may be
2079	// used to include empty fields in Patch requests.
2080	ForceSendFields []string `json:"-"`
2081
2082	// NullFields is a list of field names (e.g. "Installation") to include
2083	// in API requests with the JSON null value. By default, fields with
2084	// empty values are omitted from API requests. However, any field with
2085	// an empty value appearing in NullFields will be sent to the server as
2086	// null. It is an error if a field in this list has a non-empty value.
2087	// This may be used to include null fields in Patch requests.
2088	NullFields []string `json:"-"`
2089}
2090
2091func (s *GrafeasV1beta1PackageDetails) MarshalJSON() ([]byte, error) {
2092	type NoMethod GrafeasV1beta1PackageDetails
2093	raw := NoMethod(*s)
2094	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2095}
2096
2097// GrafeasV1beta1VulnerabilityDetails: Details of a vulnerability
2098// Occurrence.
2099type GrafeasV1beta1VulnerabilityDetails struct {
2100	// CvssScore: Output only. The CVSS score of this vulnerability. CVSS
2101	// score is on a scale of 0-10 where 0 indicates low severity and 10
2102	// indicates high severity.
2103	CvssScore float64 `json:"cvssScore,omitempty"`
2104
2105	// EffectiveSeverity: The distro assigned severity for this
2106	// vulnerability when it is available, and note provider assigned
2107	// severity when distro has not yet assigned a severity for this
2108	// vulnerability.
2109	//
2110	// Possible values:
2111	//   "SEVERITY_UNSPECIFIED" - Unknown.
2112	//   "MINIMAL" - Minimal severity.
2113	//   "LOW" - Low severity.
2114	//   "MEDIUM" - Medium severity.
2115	//   "HIGH" - High severity.
2116	//   "CRITICAL" - Critical severity.
2117	EffectiveSeverity string `json:"effectiveSeverity,omitempty"`
2118
2119	// LongDescription: Output only. A detailed description of this
2120	// vulnerability.
2121	LongDescription string `json:"longDescription,omitempty"`
2122
2123	// PackageIssue: Required. The set of affected locations and their fixes
2124	// (if available) within the associated resource.
2125	PackageIssue []*PackageIssue `json:"packageIssue,omitempty"`
2126
2127	// RelatedUrls: Output only. URLs related to this vulnerability.
2128	RelatedUrls []*RelatedUrl `json:"relatedUrls,omitempty"`
2129
2130	// Severity: Output only. The note provider assigned Severity of the
2131	// vulnerability.
2132	//
2133	// Possible values:
2134	//   "SEVERITY_UNSPECIFIED" - Unknown.
2135	//   "MINIMAL" - Minimal severity.
2136	//   "LOW" - Low severity.
2137	//   "MEDIUM" - Medium severity.
2138	//   "HIGH" - High severity.
2139	//   "CRITICAL" - Critical severity.
2140	Severity string `json:"severity,omitempty"`
2141
2142	// ShortDescription: Output only. A one sentence description of this
2143	// vulnerability.
2144	ShortDescription string `json:"shortDescription,omitempty"`
2145
2146	// Type: The type of package; whether native or non native(ruby gems,
2147	// node.js packages etc)
2148	Type string `json:"type,omitempty"`
2149
2150	// ForceSendFields is a list of field names (e.g. "CvssScore") to
2151	// unconditionally include in API requests. By default, fields with
2152	// empty values are omitted from API requests. However, any non-pointer,
2153	// non-interface field appearing in ForceSendFields will be sent to the
2154	// server regardless of whether the field is empty or not. This may be
2155	// used to include empty fields in Patch requests.
2156	ForceSendFields []string `json:"-"`
2157
2158	// NullFields is a list of field names (e.g. "CvssScore") to include in
2159	// API requests with the JSON null value. By default, fields with empty
2160	// values are omitted from API requests. However, any field with an
2161	// empty value appearing in NullFields will be sent to the server as
2162	// null. It is an error if a field in this list has a non-empty value.
2163	// This may be used to include null fields in Patch requests.
2164	NullFields []string `json:"-"`
2165}
2166
2167func (s *GrafeasV1beta1VulnerabilityDetails) MarshalJSON() ([]byte, error) {
2168	type NoMethod GrafeasV1beta1VulnerabilityDetails
2169	raw := NoMethod(*s)
2170	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2171}
2172
2173func (s *GrafeasV1beta1VulnerabilityDetails) UnmarshalJSON(data []byte) error {
2174	type NoMethod GrafeasV1beta1VulnerabilityDetails
2175	var s1 struct {
2176		CvssScore gensupport.JSONFloat64 `json:"cvssScore"`
2177		*NoMethod
2178	}
2179	s1.NoMethod = (*NoMethod)(s)
2180	if err := json.Unmarshal(data, &s1); err != nil {
2181		return err
2182	}
2183	s.CvssScore = float64(s1.CvssScore)
2184	return nil
2185}
2186
2187// Hash: Container message for hash values.
2188type Hash struct {
2189	// Type: Required. The type of hash that was performed.
2190	//
2191	// Possible values:
2192	//   "HASH_TYPE_UNSPECIFIED" - Unknown.
2193	//   "SHA256" - A SHA-256 hash.
2194	Type string `json:"type,omitempty"`
2195
2196	// Value: Required. The hash value.
2197	Value string `json:"value,omitempty"`
2198
2199	// ForceSendFields is a list of field names (e.g. "Type") to
2200	// unconditionally include in API requests. By default, fields with
2201	// empty values are omitted from API requests. However, any non-pointer,
2202	// non-interface field appearing in ForceSendFields will be sent to the
2203	// server regardless of whether the field is empty or not. This may be
2204	// used to include empty fields in Patch requests.
2205	ForceSendFields []string `json:"-"`
2206
2207	// NullFields is a list of field names (e.g. "Type") to include in API
2208	// requests with the JSON null value. By default, fields with empty
2209	// values are omitted from API requests. However, any field with an
2210	// empty value appearing in NullFields will be sent to the server as
2211	// null. It is an error if a field in this list has a non-empty value.
2212	// This may be used to include null fields in Patch requests.
2213	NullFields []string `json:"-"`
2214}
2215
2216func (s *Hash) MarshalJSON() ([]byte, error) {
2217	type NoMethod Hash
2218	raw := NoMethod(*s)
2219	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2220}
2221
2222// Hint: This submessage provides human-readable hints about the purpose
2223// of the authority. Because the name of a note acts as its resource
2224// reference, it is important to disambiguate the canonical name of the
2225// Note (which might be a UUID for security purposes) from "readable"
2226// names more suitable for debug output. Note that these hints should
2227// not be used to look up authorities in security sensitive contexts,
2228// such as when looking up attestations to verify.
2229type Hint struct {
2230	// HumanReadableName: Required. The human readable name of this
2231	// attestation authority, for example "qa".
2232	HumanReadableName string `json:"humanReadableName,omitempty"`
2233
2234	// ForceSendFields is a list of field names (e.g. "HumanReadableName")
2235	// to unconditionally include in API requests. By default, fields with
2236	// empty values are omitted from API requests. However, any non-pointer,
2237	// non-interface field appearing in ForceSendFields will be sent to the
2238	// server regardless of whether the field is empty or not. This may be
2239	// used to include empty fields in Patch requests.
2240	ForceSendFields []string `json:"-"`
2241
2242	// NullFields is a list of field names (e.g. "HumanReadableName") to
2243	// include in API requests with the JSON null value. By default, fields
2244	// with empty values are omitted from API requests. However, any field
2245	// with an empty value appearing in NullFields will be sent to the
2246	// server as null. It is an error if a field in this list has a
2247	// non-empty value. This may be used to include null fields in Patch
2248	// requests.
2249	NullFields []string `json:"-"`
2250}
2251
2252func (s *Hint) MarshalJSON() ([]byte, error) {
2253	type NoMethod Hint
2254	raw := NoMethod(*s)
2255	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2256}
2257
2258// InToto: This contains the fields corresponding to the definition of a
2259// software supply chain step in an in-toto layout. This information
2260// goes into a Grafeas note.
2261type InToto struct {
2262	// ExpectedCommand: This field contains the expected command used to
2263	// perform the step.
2264	ExpectedCommand []string `json:"expectedCommand,omitempty"`
2265
2266	// ExpectedMaterials: The following fields contain in-toto artifact
2267	// rules identifying the artifacts that enter this supply chain step,
2268	// and exit the supply chain step, i.e. materials and products of the
2269	// step.
2270	ExpectedMaterials []*ArtifactRule `json:"expectedMaterials,omitempty"`
2271
2272	ExpectedProducts []*ArtifactRule `json:"expectedProducts,omitempty"`
2273
2274	// SigningKeys: This field contains the public keys that can be used to
2275	// verify the signatures on the step metadata.
2276	SigningKeys []*SigningKey `json:"signingKeys,omitempty"`
2277
2278	// StepName: This field identifies the name of the step in the supply
2279	// chain.
2280	StepName string `json:"stepName,omitempty"`
2281
2282	// Threshold: This field contains a value that indicates the minimum
2283	// number of keys that need to be used to sign the step's in-toto link.
2284	Threshold int64 `json:"threshold,omitempty,string"`
2285
2286	// ForceSendFields is a list of field names (e.g. "ExpectedCommand") to
2287	// unconditionally include in API requests. By default, fields with
2288	// empty values are omitted from API requests. However, any non-pointer,
2289	// non-interface field appearing in ForceSendFields will be sent to the
2290	// server regardless of whether the field is empty or not. This may be
2291	// used to include empty fields in Patch requests.
2292	ForceSendFields []string `json:"-"`
2293
2294	// NullFields is a list of field names (e.g. "ExpectedCommand") to
2295	// include in API requests with the JSON null value. By default, fields
2296	// with empty values are omitted from API requests. However, any field
2297	// with an empty value appearing in NullFields will be sent to the
2298	// server as null. It is an error if a field in this list has a
2299	// non-empty value. This may be used to include null fields in Patch
2300	// requests.
2301	NullFields []string `json:"-"`
2302}
2303
2304func (s *InToto) MarshalJSON() ([]byte, error) {
2305	type NoMethod InToto
2306	raw := NoMethod(*s)
2307	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2308}
2309
2310// Installation: This represents how a particular software package may
2311// be installed on a system.
2312type Installation struct {
2313	// Location: Required. All of the places within the filesystem versions
2314	// of this package have been found.
2315	Location []*Location `json:"location,omitempty"`
2316
2317	// Name: Output only. The name of the installed package.
2318	Name string `json:"name,omitempty"`
2319
2320	// ForceSendFields is a list of field names (e.g. "Location") to
2321	// unconditionally include in API requests. By default, fields with
2322	// empty values are omitted from API requests. However, any non-pointer,
2323	// non-interface field appearing in ForceSendFields will be sent to the
2324	// server regardless of whether the field is empty or not. This may be
2325	// used to include empty fields in Patch requests.
2326	ForceSendFields []string `json:"-"`
2327
2328	// NullFields is a list of field names (e.g. "Location") to include in
2329	// API requests with the JSON null value. By default, fields with empty
2330	// values are omitted from API requests. However, any field with an
2331	// empty value appearing in NullFields will be sent to the server as
2332	// null. It is an error if a field in this list has a non-empty value.
2333	// This may be used to include null fields in Patch requests.
2334	NullFields []string `json:"-"`
2335}
2336
2337func (s *Installation) MarshalJSON() ([]byte, error) {
2338	type NoMethod Installation
2339	raw := NoMethod(*s)
2340	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2341}
2342
2343type KnowledgeBase struct {
2344	// Name: The KB name (generally of the form KB[0-9]+ i.e. KB123456).
2345	Name string `json:"name,omitempty"`
2346
2347	// Url: A link to the KB in the Windows update catalog -
2348	// https://www.catalog.update.microsoft.com/
2349	Url string `json:"url,omitempty"`
2350
2351	// ForceSendFields is a list of field names (e.g. "Name") to
2352	// unconditionally include in API requests. By default, fields with
2353	// empty values are omitted from API requests. However, any non-pointer,
2354	// non-interface field appearing in ForceSendFields will be sent to the
2355	// server regardless of whether the field is empty or not. This may be
2356	// used to include empty fields in Patch requests.
2357	ForceSendFields []string `json:"-"`
2358
2359	// NullFields is a list of field names (e.g. "Name") to include in API
2360	// requests with the JSON null value. By default, fields with empty
2361	// values are omitted from API requests. However, any field with an
2362	// empty value appearing in NullFields will be sent to the server as
2363	// null. It is an error if a field in this list has a non-empty value.
2364	// This may be used to include null fields in Patch requests.
2365	NullFields []string `json:"-"`
2366}
2367
2368func (s *KnowledgeBase) MarshalJSON() ([]byte, error) {
2369	type NoMethod KnowledgeBase
2370	raw := NoMethod(*s)
2371	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2372}
2373
2374// Layer: Layer holds metadata specific to a layer of a Docker image.
2375type Layer struct {
2376	// Arguments: The recovered arguments to the Dockerfile directive.
2377	Arguments string `json:"arguments,omitempty"`
2378
2379	// Directive: Required. The recovered Dockerfile directive used to
2380	// construct this layer.
2381	//
2382	// Possible values:
2383	//   "DIRECTIVE_UNSPECIFIED" - Default value for unsupported/missing
2384	// directive.
2385	//   "MAINTAINER" - https://docs.docker.com/engine/reference/builder/
2386	//   "RUN" - https://docs.docker.com/engine/reference/builder/
2387	//   "CMD" - https://docs.docker.com/engine/reference/builder/
2388	//   "LABEL" - https://docs.docker.com/engine/reference/builder/
2389	//   "EXPOSE" - https://docs.docker.com/engine/reference/builder/
2390	//   "ENV" - https://docs.docker.com/engine/reference/builder/
2391	//   "ADD" - https://docs.docker.com/engine/reference/builder/
2392	//   "COPY" - https://docs.docker.com/engine/reference/builder/
2393	//   "ENTRYPOINT" - https://docs.docker.com/engine/reference/builder/
2394	//   "VOLUME" - https://docs.docker.com/engine/reference/builder/
2395	//   "USER" - https://docs.docker.com/engine/reference/builder/
2396	//   "WORKDIR" - https://docs.docker.com/engine/reference/builder/
2397	//   "ARG" - https://docs.docker.com/engine/reference/builder/
2398	//   "ONBUILD" - https://docs.docker.com/engine/reference/builder/
2399	//   "STOPSIGNAL" - https://docs.docker.com/engine/reference/builder/
2400	//   "HEALTHCHECK" - https://docs.docker.com/engine/reference/builder/
2401	//   "SHELL" - https://docs.docker.com/engine/reference/builder/
2402	Directive string `json:"directive,omitempty"`
2403
2404	// ForceSendFields is a list of field names (e.g. "Arguments") to
2405	// unconditionally include in API requests. By default, fields with
2406	// empty values are omitted from API requests. However, any non-pointer,
2407	// non-interface field appearing in ForceSendFields will be sent to the
2408	// server regardless of whether the field is empty or not. This may be
2409	// used to include empty fields in Patch requests.
2410	ForceSendFields []string `json:"-"`
2411
2412	// NullFields is a list of field names (e.g. "Arguments") to include in
2413	// API requests with the JSON null value. By default, fields with empty
2414	// values are omitted from API requests. However, any field with an
2415	// empty value appearing in NullFields will be sent to the server as
2416	// null. It is an error if a field in this list has a non-empty value.
2417	// This may be used to include null fields in Patch requests.
2418	NullFields []string `json:"-"`
2419}
2420
2421func (s *Layer) MarshalJSON() ([]byte, error) {
2422	type NoMethod Layer
2423	raw := NoMethod(*s)
2424	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2425}
2426
2427// Link: This corresponds to an in-toto link.
2428type Link struct {
2429	// Byproducts: ByProducts are data generated as part of a software
2430	// supply chain step, but are not the actual result of the step.
2431	Byproducts *ByProducts `json:"byproducts,omitempty"`
2432
2433	// Command: This field contains the full command executed for the step.
2434	// This can also be empty if links are generated for operations that
2435	// aren't directly mapped to a specific command. Each term in the
2436	// command is an independent string in the list. An example of a command
2437	// in the in-toto metadata field is: "command": ["git", "clone",
2438	// "https://github.com/in-toto/demo-project.git"]
2439	Command []string `json:"command,omitempty"`
2440
2441	// Environment: This is a field that can be used to capture information
2442	// about the environment. It is suggested for this field to contain
2443	// information that details environment variables, filesystem
2444	// information, and the present working directory. The recommended
2445	// structure of this field is: "environment": { "custom_values": {
2446	// "variables": "", "filesystem": "", "workdir": "", "": "..." } }
2447	Environment *Environment `json:"environment,omitempty"`
2448
2449	// Materials: Materials are the supply chain artifacts that go into the
2450	// step and are used for the operation performed. The key of the map is
2451	// the path of the artifact and the structure contains the recorded hash
2452	// information. An example is: "materials": [ { "resource_uri":
2453	// "foo/bar", "hashes": { "sha256": "ebebf...", : } } ]
2454	Materials []*GrafeasV1beta1IntotoArtifact `json:"materials,omitempty"`
2455
2456	// Products: Products are the supply chain artifacts generated as a
2457	// result of the step. The structure is identical to that of materials.
2458	Products []*GrafeasV1beta1IntotoArtifact `json:"products,omitempty"`
2459
2460	// ForceSendFields is a list of field names (e.g. "Byproducts") to
2461	// unconditionally include in API requests. By default, fields with
2462	// empty values are omitted from API requests. However, any non-pointer,
2463	// non-interface field appearing in ForceSendFields will be sent to the
2464	// server regardless of whether the field is empty or not. This may be
2465	// used to include empty fields in Patch requests.
2466	ForceSendFields []string `json:"-"`
2467
2468	// NullFields is a list of field names (e.g. "Byproducts") to include in
2469	// API requests with the JSON null value. By default, fields with empty
2470	// values are omitted from API requests. However, any field with an
2471	// empty value appearing in NullFields will be sent to the server as
2472	// null. It is an error if a field in this list has a non-empty value.
2473	// This may be used to include null fields in Patch requests.
2474	NullFields []string `json:"-"`
2475}
2476
2477func (s *Link) MarshalJSON() ([]byte, error) {
2478	type NoMethod Link
2479	raw := NoMethod(*s)
2480	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2481}
2482
2483// ListNoteOccurrencesResponse: Response for listing occurrences for a
2484// note.
2485type ListNoteOccurrencesResponse struct {
2486	// NextPageToken: Token to provide to skip to a particular spot in the
2487	// list.
2488	NextPageToken string `json:"nextPageToken,omitempty"`
2489
2490	// Occurrences: The occurrences attached to the specified note.
2491	Occurrences []*Occurrence `json:"occurrences,omitempty"`
2492
2493	// ServerResponse contains the HTTP response code and headers from the
2494	// server.
2495	googleapi.ServerResponse `json:"-"`
2496
2497	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
2498	// unconditionally include in API requests. By default, fields with
2499	// empty values are omitted from API requests. However, any non-pointer,
2500	// non-interface field appearing in ForceSendFields will be sent to the
2501	// server regardless of whether the field is empty or not. This may be
2502	// used to include empty fields in Patch requests.
2503	ForceSendFields []string `json:"-"`
2504
2505	// NullFields is a list of field names (e.g. "NextPageToken") to include
2506	// in API requests with the JSON null value. By default, fields with
2507	// empty values are omitted from API requests. However, any field with
2508	// an empty value appearing in NullFields will be sent to the server as
2509	// null. It is an error if a field in this list has a non-empty value.
2510	// This may be used to include null fields in Patch requests.
2511	NullFields []string `json:"-"`
2512}
2513
2514func (s *ListNoteOccurrencesResponse) MarshalJSON() ([]byte, error) {
2515	type NoMethod ListNoteOccurrencesResponse
2516	raw := NoMethod(*s)
2517	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2518}
2519
2520// ListNotesResponse: Response for listing notes.
2521type ListNotesResponse struct {
2522	// NextPageToken: The next pagination token in the list response. It
2523	// should be used as `page_token` for the following request. An empty
2524	// value means no more results.
2525	NextPageToken string `json:"nextPageToken,omitempty"`
2526
2527	// Notes: The notes requested.
2528	Notes []*Note `json:"notes,omitempty"`
2529
2530	// ServerResponse contains the HTTP response code and headers from the
2531	// server.
2532	googleapi.ServerResponse `json:"-"`
2533
2534	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
2535	// unconditionally include in API requests. By default, fields with
2536	// empty values are omitted from API requests. However, any non-pointer,
2537	// non-interface field appearing in ForceSendFields will be sent to the
2538	// server regardless of whether the field is empty or not. This may be
2539	// used to include empty fields in Patch requests.
2540	ForceSendFields []string `json:"-"`
2541
2542	// NullFields is a list of field names (e.g. "NextPageToken") to include
2543	// in API requests with the JSON null value. By default, fields with
2544	// empty values are omitted from API requests. However, any field with
2545	// an empty value appearing in NullFields will be sent to the server as
2546	// null. It is an error if a field in this list has a non-empty value.
2547	// This may be used to include null fields in Patch requests.
2548	NullFields []string `json:"-"`
2549}
2550
2551func (s *ListNotesResponse) MarshalJSON() ([]byte, error) {
2552	type NoMethod ListNotesResponse
2553	raw := NoMethod(*s)
2554	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2555}
2556
2557// ListOccurrencesResponse: Response for listing occurrences.
2558type ListOccurrencesResponse struct {
2559	// NextPageToken: The next pagination token in the list response. It
2560	// should be used as `page_token` for the following request. An empty
2561	// value means no more results.
2562	NextPageToken string `json:"nextPageToken,omitempty"`
2563
2564	// Occurrences: The occurrences requested.
2565	Occurrences []*Occurrence `json:"occurrences,omitempty"`
2566
2567	// ServerResponse contains the HTTP response code and headers from the
2568	// server.
2569	googleapi.ServerResponse `json:"-"`
2570
2571	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
2572	// unconditionally include in API requests. By default, fields with
2573	// empty values are omitted from API requests. However, any non-pointer,
2574	// non-interface field appearing in ForceSendFields will be sent to the
2575	// server regardless of whether the field is empty or not. This may be
2576	// used to include empty fields in Patch requests.
2577	ForceSendFields []string `json:"-"`
2578
2579	// NullFields is a list of field names (e.g. "NextPageToken") to include
2580	// in API requests with the JSON null value. By default, fields with
2581	// empty values are omitted from API requests. However, any field with
2582	// an empty value appearing in NullFields will be sent to the server as
2583	// null. It is an error if a field in this list has a non-empty value.
2584	// This may be used to include null fields in Patch requests.
2585	NullFields []string `json:"-"`
2586}
2587
2588func (s *ListOccurrencesResponse) MarshalJSON() ([]byte, error) {
2589	type NoMethod ListOccurrencesResponse
2590	raw := NoMethod(*s)
2591	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2592}
2593
2594// ListScanConfigsResponse: Response for listing scan configurations.
2595type ListScanConfigsResponse struct {
2596	// NextPageToken: The next pagination token in the list response. It
2597	// should be used as `page_token` for the following request. An empty
2598	// value means no more results.
2599	NextPageToken string `json:"nextPageToken,omitempty"`
2600
2601	// ScanConfigs: The scan configurations requested.
2602	ScanConfigs []*ScanConfig `json:"scanConfigs,omitempty"`
2603
2604	// ServerResponse contains the HTTP response code and headers from the
2605	// server.
2606	googleapi.ServerResponse `json:"-"`
2607
2608	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
2609	// unconditionally include in API requests. By default, fields with
2610	// empty values are omitted from API requests. However, any non-pointer,
2611	// non-interface field appearing in ForceSendFields will be sent to the
2612	// server regardless of whether the field is empty or not. This may be
2613	// used to include empty fields in Patch requests.
2614	ForceSendFields []string `json:"-"`
2615
2616	// NullFields is a list of field names (e.g. "NextPageToken") to include
2617	// in API requests with the JSON null value. By default, fields with
2618	// empty values are omitted from API requests. However, any field with
2619	// an empty value appearing in NullFields will be sent to the server as
2620	// null. It is an error if a field in this list has a non-empty value.
2621	// This may be used to include null fields in Patch requests.
2622	NullFields []string `json:"-"`
2623}
2624
2625func (s *ListScanConfigsResponse) MarshalJSON() ([]byte, error) {
2626	type NoMethod ListScanConfigsResponse
2627	raw := NoMethod(*s)
2628	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2629}
2630
2631// Location: An occurrence of a particular package installation found
2632// within a system's filesystem. E.g., glibc was found in
2633// `/var/lib/dpkg/status`.
2634type Location struct {
2635	// CpeUri: Required. The CPE URI in CPE format
2636	// (https://cpe.mitre.org/specification/) denoting the package manager
2637	// version distributing a package.
2638	CpeUri string `json:"cpeUri,omitempty"`
2639
2640	// Path: The path from which we gathered that this package/version is
2641	// installed.
2642	Path string `json:"path,omitempty"`
2643
2644	// Version: The version installed at this location.
2645	Version *Version `json:"version,omitempty"`
2646
2647	// ForceSendFields is a list of field names (e.g. "CpeUri") to
2648	// unconditionally include in API requests. By default, fields with
2649	// empty values are omitted from API requests. However, any non-pointer,
2650	// non-interface field appearing in ForceSendFields will be sent to the
2651	// server regardless of whether the field is empty or not. This may be
2652	// used to include empty fields in Patch requests.
2653	ForceSendFields []string `json:"-"`
2654
2655	// NullFields is a list of field names (e.g. "CpeUri") to include in API
2656	// requests with the JSON null value. By default, fields with empty
2657	// values are omitted from API requests. However, any field with an
2658	// empty value appearing in NullFields will be sent to the server as
2659	// null. It is an error if a field in this list has a non-empty value.
2660	// This may be used to include null fields in Patch requests.
2661	NullFields []string `json:"-"`
2662}
2663
2664func (s *Location) MarshalJSON() ([]byte, error) {
2665	type NoMethod Location
2666	raw := NoMethod(*s)
2667	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2668}
2669
2670// Note: A type of analysis that can be done for a resource.
2671type Note struct {
2672	// AttestationAuthority: A note describing an attestation role.
2673	AttestationAuthority *Authority `json:"attestationAuthority,omitempty"`
2674
2675	// BaseImage: A note describing a base image.
2676	BaseImage *Basis `json:"baseImage,omitempty"`
2677
2678	// Build: A note describing build provenance for a verifiable build.
2679	Build *Build `json:"build,omitempty"`
2680
2681	// CreateTime: Output only. The time this note was created. This field
2682	// can be used as a filter in list requests.
2683	CreateTime string `json:"createTime,omitempty"`
2684
2685	// Deployable: A note describing something that can be deployed.
2686	Deployable *Deployable `json:"deployable,omitempty"`
2687
2688	// Discovery: A note describing the initial analysis of a resource.
2689	Discovery *Discovery `json:"discovery,omitempty"`
2690
2691	// ExpirationTime: Time of expiration for this note. Empty if note does
2692	// not expire.
2693	ExpirationTime string `json:"expirationTime,omitempty"`
2694
2695	// Intoto: A note describing an in-toto link.
2696	Intoto *InToto `json:"intoto,omitempty"`
2697
2698	// Kind: Output only. The type of analysis. This field can be used as a
2699	// filter in list requests.
2700	//
2701	// Possible values:
2702	//   "NOTE_KIND_UNSPECIFIED" - Default value. This value is unused.
2703	//   "VULNERABILITY" - The note and occurrence represent a package
2704	// vulnerability.
2705	//   "BUILD" - The note and occurrence assert build provenance.
2706	//   "IMAGE" - This represents an image basis relationship.
2707	//   "PACKAGE" - This represents a package installed via a package
2708	// manager.
2709	//   "DEPLOYMENT" - The note and occurrence track deployment events.
2710	//   "DISCOVERY" - The note and occurrence track the initial discovery
2711	// status of a resource.
2712	//   "ATTESTATION" - This represents a logical "role" that can attest to
2713	// artifacts.
2714	//   "INTOTO" - This represents an in-toto link.
2715	Kind string `json:"kind,omitempty"`
2716
2717	// LongDescription: A detailed description of this note.
2718	LongDescription string `json:"longDescription,omitempty"`
2719
2720	// Name: Output only. The name of the note in the form of
2721	// `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
2722	Name string `json:"name,omitempty"`
2723
2724	// Package: A note describing a package hosted by various package
2725	// managers.
2726	Package *Package `json:"package,omitempty"`
2727
2728	// RelatedNoteNames: Other notes related to this note.
2729	RelatedNoteNames []string `json:"relatedNoteNames,omitempty"`
2730
2731	// RelatedUrl: URLs associated with this note.
2732	RelatedUrl []*RelatedUrl `json:"relatedUrl,omitempty"`
2733
2734	// ShortDescription: A one sentence description of this note.
2735	ShortDescription string `json:"shortDescription,omitempty"`
2736
2737	// UpdateTime: Output only. The time this note was last updated. This
2738	// field can be used as a filter in list requests.
2739	UpdateTime string `json:"updateTime,omitempty"`
2740
2741	// Vulnerability: A note describing a package vulnerability.
2742	Vulnerability *Vulnerability `json:"vulnerability,omitempty"`
2743
2744	// ServerResponse contains the HTTP response code and headers from the
2745	// server.
2746	googleapi.ServerResponse `json:"-"`
2747
2748	// ForceSendFields is a list of field names (e.g.
2749	// "AttestationAuthority") to unconditionally include in API requests.
2750	// By default, fields with empty values are omitted from API requests.
2751	// However, any non-pointer, non-interface field appearing in
2752	// ForceSendFields will be sent to the server regardless of whether the
2753	// field is empty or not. This may be used to include empty fields in
2754	// Patch requests.
2755	ForceSendFields []string `json:"-"`
2756
2757	// NullFields is a list of field names (e.g. "AttestationAuthority") to
2758	// include in API requests with the JSON null value. By default, fields
2759	// with empty values are omitted from API requests. However, any field
2760	// with an empty value appearing in NullFields will be sent to the
2761	// server as null. It is an error if a field in this list has a
2762	// non-empty value. This may be used to include null fields in Patch
2763	// requests.
2764	NullFields []string `json:"-"`
2765}
2766
2767func (s *Note) MarshalJSON() ([]byte, error) {
2768	type NoMethod Note
2769	raw := NoMethod(*s)
2770	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2771}
2772
2773// Occurrence: An instance of an analysis type that has been found on a
2774// resource.
2775type Occurrence struct {
2776	// Attestation: Describes an attestation of an artifact.
2777	Attestation *Details `json:"attestation,omitempty"`
2778
2779	// Build: Describes a verifiable build.
2780	Build *GrafeasV1beta1BuildDetails `json:"build,omitempty"`
2781
2782	// CreateTime: Output only. The time this occurrence was created.
2783	CreateTime string `json:"createTime,omitempty"`
2784
2785	// Deployment: Describes the deployment of an artifact on a runtime.
2786	Deployment *GrafeasV1beta1DeploymentDetails `json:"deployment,omitempty"`
2787
2788	// DerivedImage: Describes how this resource derives from the basis in
2789	// the associated note.
2790	DerivedImage *GrafeasV1beta1ImageDetails `json:"derivedImage,omitempty"`
2791
2792	// Discovered: Describes when a resource was discovered.
2793	Discovered *GrafeasV1beta1DiscoveryDetails `json:"discovered,omitempty"`
2794
2795	// Installation: Describes the installation of a package on the linked
2796	// resource.
2797	Installation *GrafeasV1beta1PackageDetails `json:"installation,omitempty"`
2798
2799	// Intoto: Describes a specific in-toto link.
2800	Intoto *GrafeasV1beta1IntotoDetails `json:"intoto,omitempty"`
2801
2802	// Kind: Output only. This explicitly denotes which of the occurrence
2803	// details are specified. This field can be used as a filter in list
2804	// requests.
2805	//
2806	// Possible values:
2807	//   "NOTE_KIND_UNSPECIFIED" - Default value. This value is unused.
2808	//   "VULNERABILITY" - The note and occurrence represent a package
2809	// vulnerability.
2810	//   "BUILD" - The note and occurrence assert build provenance.
2811	//   "IMAGE" - This represents an image basis relationship.
2812	//   "PACKAGE" - This represents a package installed via a package
2813	// manager.
2814	//   "DEPLOYMENT" - The note and occurrence track deployment events.
2815	//   "DISCOVERY" - The note and occurrence track the initial discovery
2816	// status of a resource.
2817	//   "ATTESTATION" - This represents a logical "role" that can attest to
2818	// artifacts.
2819	//   "INTOTO" - This represents an in-toto link.
2820	Kind string `json:"kind,omitempty"`
2821
2822	// Name: Output only. The name of the occurrence in the form of
2823	// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
2824	Name string `json:"name,omitempty"`
2825
2826	// NoteName: Required. Immutable. The analysis note associated with this
2827	// occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
2828	// This field can be used as a filter in list requests.
2829	NoteName string `json:"noteName,omitempty"`
2830
2831	// Remediation: A description of actions that can be taken to remedy the
2832	// note.
2833	Remediation string `json:"remediation,omitempty"`
2834
2835	// Resource: Required. Immutable. The resource for which the occurrence
2836	// applies.
2837	Resource *Resource `json:"resource,omitempty"`
2838
2839	// UpdateTime: Output only. The time this occurrence was last updated.
2840	UpdateTime string `json:"updateTime,omitempty"`
2841
2842	// Vulnerability: Describes a security vulnerability.
2843	Vulnerability *GrafeasV1beta1VulnerabilityDetails `json:"vulnerability,omitempty"`
2844
2845	// ServerResponse contains the HTTP response code and headers from the
2846	// server.
2847	googleapi.ServerResponse `json:"-"`
2848
2849	// ForceSendFields is a list of field names (e.g. "Attestation") to
2850	// unconditionally include in API requests. By default, fields with
2851	// empty values are omitted from API requests. However, any non-pointer,
2852	// non-interface field appearing in ForceSendFields will be sent to the
2853	// server regardless of whether the field is empty or not. This may be
2854	// used to include empty fields in Patch requests.
2855	ForceSendFields []string `json:"-"`
2856
2857	// NullFields is a list of field names (e.g. "Attestation") to include
2858	// in API requests with the JSON null value. By default, fields with
2859	// empty values are omitted from API requests. However, any field with
2860	// an empty value appearing in NullFields will be sent to the server as
2861	// null. It is an error if a field in this list has a non-empty value.
2862	// This may be used to include null fields in Patch requests.
2863	NullFields []string `json:"-"`
2864}
2865
2866func (s *Occurrence) MarshalJSON() ([]byte, error) {
2867	type NoMethod Occurrence
2868	raw := NoMethod(*s)
2869	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2870}
2871
2872// Package: This represents a particular package that is distributed
2873// over various channels. E.g., glibc (aka libc6) is distributed by
2874// many, at various versions.
2875type Package struct {
2876	// Distribution: The various channels by which a package is distributed.
2877	Distribution []*Distribution `json:"distribution,omitempty"`
2878
2879	// Name: Required. Immutable. The name of the package.
2880	Name string `json:"name,omitempty"`
2881
2882	// ForceSendFields is a list of field names (e.g. "Distribution") to
2883	// unconditionally include in API requests. By default, fields with
2884	// empty values are omitted from API requests. However, any non-pointer,
2885	// non-interface field appearing in ForceSendFields will be sent to the
2886	// server regardless of whether the field is empty or not. This may be
2887	// used to include empty fields in Patch requests.
2888	ForceSendFields []string `json:"-"`
2889
2890	// NullFields is a list of field names (e.g. "Distribution") to include
2891	// in API requests with the JSON null value. By default, fields with
2892	// empty values are omitted from API requests. However, any field with
2893	// an empty value appearing in NullFields will be sent to the server as
2894	// null. It is an error if a field in this list has a non-empty value.
2895	// This may be used to include null fields in Patch requests.
2896	NullFields []string `json:"-"`
2897}
2898
2899func (s *Package) MarshalJSON() ([]byte, error) {
2900	type NoMethod Package
2901	raw := NoMethod(*s)
2902	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2903}
2904
2905// PackageIssue: This message wraps a location affected by a
2906// vulnerability and its associated fix (if one is available).
2907type PackageIssue struct {
2908	// AffectedLocation: Required. The location of the vulnerability.
2909	AffectedLocation *VulnerabilityLocation `json:"affectedLocation,omitempty"`
2910
2911	// FixedLocation: The location of the available fix for vulnerability.
2912	FixedLocation *VulnerabilityLocation `json:"fixedLocation,omitempty"`
2913
2914	// SeverityName: Deprecated, use Details.effective_severity instead The
2915	// severity (e.g., distro assigned severity) for this vulnerability.
2916	SeverityName string `json:"severityName,omitempty"`
2917
2918	// ForceSendFields is a list of field names (e.g. "AffectedLocation") to
2919	// unconditionally include in API requests. By default, fields with
2920	// empty values are omitted from API requests. However, any non-pointer,
2921	// non-interface field appearing in ForceSendFields will be sent to the
2922	// server regardless of whether the field is empty or not. This may be
2923	// used to include empty fields in Patch requests.
2924	ForceSendFields []string `json:"-"`
2925
2926	// NullFields is a list of field names (e.g. "AffectedLocation") to
2927	// include in API requests with the JSON null value. By default, fields
2928	// with empty values are omitted from API requests. However, any field
2929	// with an empty value appearing in NullFields will be sent to the
2930	// server as null. It is an error if a field in this list has a
2931	// non-empty value. This may be used to include null fields in Patch
2932	// requests.
2933	NullFields []string `json:"-"`
2934}
2935
2936func (s *PackageIssue) MarshalJSON() ([]byte, error) {
2937	type NoMethod PackageIssue
2938	raw := NoMethod(*s)
2939	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2940}
2941
2942// PgpSignedAttestation: An attestation wrapper with a PGP-compatible
2943// signature. This message only supports `ATTACHED` signatures, where
2944// the payload that is signed is included alongside the signature itself
2945// in the same file.
2946type PgpSignedAttestation struct {
2947	// ContentType: Type (for example schema) of the attestation payload
2948	// that was signed. The verifier must ensure that the provided type is
2949	// one that the verifier supports, and that the attestation payload is a
2950	// valid instantiation of that type (for example by validating a JSON
2951	// schema).
2952	//
2953	// Possible values:
2954	//   "CONTENT_TYPE_UNSPECIFIED" - `ContentType` is not set.
2955	//   "SIMPLE_SIGNING_JSON" - Atomic format attestation signature. See
2956	// https://github.com/containers/image/blob/8a5d2f82a6e3263290c8e0276c3e0f64e77723e7/docs/atomic-signature.md
2957	// The payload extracted from `signature` is a JSON blob conforming to
2958	// the linked schema.
2959	ContentType string `json:"contentType,omitempty"`
2960
2961	// PgpKeyId: The cryptographic fingerprint of the key used to generate
2962	// the signature, as output by, e.g. `gpg --list-keys`. This should be
2963	// the version 4, full 160-bit fingerprint, expressed as a 40 character
2964	// hexidecimal string. See
2965	// https://tools.ietf.org/html/rfc4880#section-12.2 for details.
2966	// Implementations may choose to acknowledge "LONG", "SHORT", or other
2967	// abbreviated key IDs, but only the full fingerprint is guaranteed to
2968	// work. In gpg, the full fingerprint can be retrieved from the `fpr`
2969	// field returned when calling --list-keys with --with-colons. For
2970	// example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \
2971	// --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:......
2972	// fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the
2973	// fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
2974	PgpKeyId string `json:"pgpKeyId,omitempty"`
2975
2976	// Signature: Required. The raw content of the signature, as output by
2977	// GNU Privacy Guard (GPG) or equivalent. Since this message only
2978	// supports attached signatures, the payload that was signed must be
2979	// attached. While the signature format supported is dependent on the
2980	// verification implementation, currently only ASCII-armored (`--armor`
2981	// to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg)
2982	// are supported. Concretely, `gpg --sign --armor --output=signature.gpg
2983	// payload.json` will create the signature content expected in this
2984	// field in `signature.gpg` for the `payload.json` attestation payload.
2985	Signature string `json:"signature,omitempty"`
2986
2987	// ForceSendFields is a list of field names (e.g. "ContentType") to
2988	// unconditionally include in API requests. By default, fields with
2989	// empty values are omitted from API requests. However, any non-pointer,
2990	// non-interface field appearing in ForceSendFields will be sent to the
2991	// server regardless of whether the field is empty or not. This may be
2992	// used to include empty fields in Patch requests.
2993	ForceSendFields []string `json:"-"`
2994
2995	// NullFields is a list of field names (e.g. "ContentType") to include
2996	// in API requests with the JSON null value. By default, fields with
2997	// empty values are omitted from API requests. However, any field with
2998	// an empty value appearing in NullFields will be sent to the server as
2999	// null. It is an error if a field in this list has a non-empty value.
3000	// This may be used to include null fields in Patch requests.
3001	NullFields []string `json:"-"`
3002}
3003
3004func (s *PgpSignedAttestation) MarshalJSON() ([]byte, error) {
3005	type NoMethod PgpSignedAttestation
3006	raw := NoMethod(*s)
3007	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3008}
3009
3010// Policy: An Identity and Access Management (IAM) policy, which
3011// specifies access controls for Google Cloud resources. A `Policy` is a
3012// collection of `bindings`. A `binding` binds one or more `members` to
3013// a single `role`. Members can be user accounts, service accounts,
3014// Google groups, and domains (such as G Suite). A `role` is a named
3015// list of permissions; each `role` can be an IAM predefined role or a
3016// user-created custom role. For some types of Google Cloud resources, a
3017// `binding` can also specify a `condition`, which is a logical
3018// expression that allows access to a resource only if the expression
3019// evaluates to `true`. A condition can add constraints based on
3020// attributes of the request, the resource, or both. To learn which
3021// resources support conditions in their IAM policies, see the IAM
3022// documentation
3023// (https://cloud.google.com/iam/help/conditions/resource-policies).
3024// **JSON example:** { "bindings": [ { "role":
3025// "roles/resourcemanager.organizationAdmin", "members": [
3026// "user:mike@example.com", "group:admins@example.com",
3027// "domain:google.com",
3028// "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, {
3029// "role": "roles/resourcemanager.organizationViewer", "members": [
3030// "user:eve@example.com" ], "condition": { "title": "expirable access",
3031// "description": "Does not grant access after Sep 2020", "expression":
3032// "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ],
3033// "etag": "BwWWja0YfJA=", "version": 3 } **YAML example:** bindings: -
3034// members: - user:mike@example.com - group:admins@example.com -
3035// domain:google.com -
3036// serviceAccount:my-project-id@appspot.gserviceaccount.com role:
3037// roles/resourcemanager.organizationAdmin - members: -
3038// user:eve@example.com role: roles/resourcemanager.organizationViewer
3039// condition: title: expirable access description: Does not grant access
3040// after Sep 2020 expression: request.time <
3041// timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version:
3042// 3 For a description of IAM and its features, see the IAM
3043// documentation (https://cloud.google.com/iam/docs/).
3044type Policy struct {
3045	// Bindings: Associates a list of `members` to a `role`. Optionally, may
3046	// specify a `condition` that determines how and when the `bindings` are
3047	// applied. Each of the `bindings` must contain at least one member.
3048	Bindings []*Binding `json:"bindings,omitempty"`
3049
3050	// Etag: `etag` is used for optimistic concurrency control as a way to
3051	// help prevent simultaneous updates of a policy from overwriting each
3052	// other. It is strongly suggested that systems make use of the `etag`
3053	// in the read-modify-write cycle to perform policy updates in order to
3054	// avoid race conditions: An `etag` is returned in the response to
3055	// `getIamPolicy`, and systems are expected to put that etag in the
3056	// request to `setIamPolicy` to ensure that their change will be applied
3057	// to the same version of the policy. **Important:** If you use IAM
3058	// Conditions, you must include the `etag` field whenever you call
3059	// `setIamPolicy`. If you omit this field, then IAM allows you to
3060	// overwrite a version `3` policy with a version `1` policy, and all of
3061	// the conditions in the version `3` policy are lost.
3062	Etag string `json:"etag,omitempty"`
3063
3064	// Version: Specifies the format of the policy. Valid values are `0`,
3065	// `1`, and `3`. Requests that specify an invalid value are rejected.
3066	// Any operation that affects conditional role bindings must specify
3067	// version `3`. This requirement applies to the following operations: *
3068	// Getting a policy that includes a conditional role binding * Adding a
3069	// conditional role binding to a policy * Changing a conditional role
3070	// binding in a policy * Removing any role binding, with or without a
3071	// condition, from a policy that includes conditions **Important:** If
3072	// you use IAM Conditions, you must include the `etag` field whenever
3073	// you call `setIamPolicy`. If you omit this field, then IAM allows you
3074	// to overwrite a version `3` policy with a version `1` policy, and all
3075	// of the conditions in the version `3` policy are lost. If a policy
3076	// does not include any conditions, operations on that policy may
3077	// specify any valid version or leave the field unset. To learn which
3078	// resources support conditions in their IAM policies, see the IAM
3079	// documentation
3080	// (https://cloud.google.com/iam/help/conditions/resource-policies).
3081	Version int64 `json:"version,omitempty"`
3082
3083	// ServerResponse contains the HTTP response code and headers from the
3084	// server.
3085	googleapi.ServerResponse `json:"-"`
3086
3087	// ForceSendFields is a list of field names (e.g. "Bindings") to
3088	// unconditionally include in API requests. By default, fields with
3089	// empty values are omitted from API requests. However, any non-pointer,
3090	// non-interface field appearing in ForceSendFields will be sent to the
3091	// server regardless of whether the field is empty or not. This may be
3092	// used to include empty fields in Patch requests.
3093	ForceSendFields []string `json:"-"`
3094
3095	// NullFields is a list of field names (e.g. "Bindings") to include in
3096	// API requests with the JSON null value. By default, fields with empty
3097	// values are omitted from API requests. However, any field with an
3098	// empty value appearing in NullFields will be sent to the server as
3099	// null. It is an error if a field in this list has a non-empty value.
3100	// This may be used to include null fields in Patch requests.
3101	NullFields []string `json:"-"`
3102}
3103
3104func (s *Policy) MarshalJSON() ([]byte, error) {
3105	type NoMethod Policy
3106	raw := NoMethod(*s)
3107	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3108}
3109
3110// ProjectRepoId: Selects a repo using a Google Cloud Platform project
3111// ID (e.g., winged-cargo-31) and a repo name within that project.
3112type ProjectRepoId struct {
3113	// ProjectId: The ID of the project.
3114	ProjectId string `json:"projectId,omitempty"`
3115
3116	// RepoName: The name of the repo. Leave empty for the default repo.
3117	RepoName string `json:"repoName,omitempty"`
3118
3119	// ForceSendFields is a list of field names (e.g. "ProjectId") to
3120	// unconditionally include in API requests. By default, fields with
3121	// empty values are omitted from API requests. However, any non-pointer,
3122	// non-interface field appearing in ForceSendFields will be sent to the
3123	// server regardless of whether the field is empty or not. This may be
3124	// used to include empty fields in Patch requests.
3125	ForceSendFields []string `json:"-"`
3126
3127	// NullFields is a list of field names (e.g. "ProjectId") to include in
3128	// API requests with the JSON null value. By default, fields with empty
3129	// values are omitted from API requests. However, any field with an
3130	// empty value appearing in NullFields will be sent to the server as
3131	// null. It is an error if a field in this list has a non-empty value.
3132	// This may be used to include null fields in Patch requests.
3133	NullFields []string `json:"-"`
3134}
3135
3136func (s *ProjectRepoId) MarshalJSON() ([]byte, error) {
3137	type NoMethod ProjectRepoId
3138	raw := NoMethod(*s)
3139	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3140}
3141
3142// RelatedUrl: Metadata for any related URL information.
3143type RelatedUrl struct {
3144	// Label: Label to describe usage of the URL.
3145	Label string `json:"label,omitempty"`
3146
3147	// Url: Specific URL associated with the resource.
3148	Url string `json:"url,omitempty"`
3149
3150	// ForceSendFields is a list of field names (e.g. "Label") to
3151	// unconditionally include in API requests. By default, fields with
3152	// empty values are omitted from API requests. However, any non-pointer,
3153	// non-interface field appearing in ForceSendFields will be sent to the
3154	// server regardless of whether the field is empty or not. This may be
3155	// used to include empty fields in Patch requests.
3156	ForceSendFields []string `json:"-"`
3157
3158	// NullFields is a list of field names (e.g. "Label") to include in API
3159	// requests with the JSON null value. By default, fields with empty
3160	// values are omitted from API requests. However, any field with an
3161	// empty value appearing in NullFields will be sent to the server as
3162	// null. It is an error if a field in this list has a non-empty value.
3163	// This may be used to include null fields in Patch requests.
3164	NullFields []string `json:"-"`
3165}
3166
3167func (s *RelatedUrl) MarshalJSON() ([]byte, error) {
3168	type NoMethod RelatedUrl
3169	raw := NoMethod(*s)
3170	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3171}
3172
3173// RepoId: A unique identifier for a Cloud Repo.
3174type RepoId struct {
3175	// ProjectRepoId: A combination of a project ID and a repo name.
3176	ProjectRepoId *ProjectRepoId `json:"projectRepoId,omitempty"`
3177
3178	// Uid: A server-assigned, globally unique identifier.
3179	Uid string `json:"uid,omitempty"`
3180
3181	// ForceSendFields is a list of field names (e.g. "ProjectRepoId") to
3182	// unconditionally include in API requests. By default, fields with
3183	// empty values are omitted from API requests. However, any non-pointer,
3184	// non-interface field appearing in ForceSendFields will be sent to the
3185	// server regardless of whether the field is empty or not. This may be
3186	// used to include empty fields in Patch requests.
3187	ForceSendFields []string `json:"-"`
3188
3189	// NullFields is a list of field names (e.g. "ProjectRepoId") to include
3190	// in API requests with the JSON null value. By default, fields with
3191	// empty values are omitted from API requests. However, any field with
3192	// an empty value appearing in NullFields will be sent to the server as
3193	// null. It is an error if a field in this list has a non-empty value.
3194	// This may be used to include null fields in Patch requests.
3195	NullFields []string `json:"-"`
3196}
3197
3198func (s *RepoId) MarshalJSON() ([]byte, error) {
3199	type NoMethod RepoId
3200	raw := NoMethod(*s)
3201	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3202}
3203
3204// Resource: An entity that can have metadata. For example, a Docker
3205// image.
3206type Resource struct {
3207	// ContentHash: Deprecated, do not use. Use uri instead. The hash of the
3208	// resource content. For example, the Docker digest.
3209	ContentHash *Hash `json:"contentHash,omitempty"`
3210
3211	// Name: Deprecated, do not use. Use uri instead. The name of the
3212	// resource. For example, the name of a Docker image - "Debian".
3213	Name string `json:"name,omitempty"`
3214
3215	// Uri: Required. The unique URI of the resource. For example,
3216	// `https://gcr.io/project/image@sha256:foo` for a Docker image.
3217	Uri string `json:"uri,omitempty"`
3218
3219	// ForceSendFields is a list of field names (e.g. "ContentHash") to
3220	// unconditionally include in API requests. By default, fields with
3221	// empty values are omitted from API requests. However, any non-pointer,
3222	// non-interface field appearing in ForceSendFields will be sent to the
3223	// server regardless of whether the field is empty or not. This may be
3224	// used to include empty fields in Patch requests.
3225	ForceSendFields []string `json:"-"`
3226
3227	// NullFields is a list of field names (e.g. "ContentHash") to include
3228	// in API requests with the JSON null value. By default, fields with
3229	// empty values are omitted from API requests. However, any field with
3230	// an empty value appearing in NullFields will be sent to the server as
3231	// null. It is an error if a field in this list has a non-empty value.
3232	// This may be used to include null fields in Patch requests.
3233	NullFields []string `json:"-"`
3234}
3235
3236func (s *Resource) MarshalJSON() ([]byte, error) {
3237	type NoMethod Resource
3238	raw := NoMethod(*s)
3239	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3240}
3241
3242// ScanConfig: A scan configuration specifies whether Cloud components
3243// in a project have a particular type of analysis being run. For
3244// example, it can configure whether vulnerability scanning is being
3245// done on Docker images or not.
3246type ScanConfig struct {
3247	// CreateTime: Output only. The time this scan config was created.
3248	CreateTime string `json:"createTime,omitempty"`
3249
3250	// Description: Output only. A human-readable description of what the
3251	// scan configuration does.
3252	Description string `json:"description,omitempty"`
3253
3254	// Enabled: Whether the scan is enabled.
3255	Enabled bool `json:"enabled,omitempty"`
3256
3257	// Name: Output only. The name of the scan configuration in the form of
3258	// `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
3259	Name string `json:"name,omitempty"`
3260
3261	// UpdateTime: Output only. The time this scan config was last updated.
3262	UpdateTime string `json:"updateTime,omitempty"`
3263
3264	// ServerResponse contains the HTTP response code and headers from the
3265	// server.
3266	googleapi.ServerResponse `json:"-"`
3267
3268	// ForceSendFields is a list of field names (e.g. "CreateTime") to
3269	// unconditionally include in API requests. By default, fields with
3270	// empty values are omitted from API requests. However, any non-pointer,
3271	// non-interface field appearing in ForceSendFields will be sent to the
3272	// server regardless of whether the field is empty or not. This may be
3273	// used to include empty fields in Patch requests.
3274	ForceSendFields []string `json:"-"`
3275
3276	// NullFields is a list of field names (e.g. "CreateTime") to include in
3277	// API requests with the JSON null value. By default, fields with empty
3278	// values are omitted from API requests. However, any field with an
3279	// empty value appearing in NullFields will be sent to the server as
3280	// null. It is an error if a field in this list has a non-empty value.
3281	// This may be used to include null fields in Patch requests.
3282	NullFields []string `json:"-"`
3283}
3284
3285func (s *ScanConfig) MarshalJSON() ([]byte, error) {
3286	type NoMethod ScanConfig
3287	raw := NoMethod(*s)
3288	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3289}
3290
3291// SetIamPolicyRequest: Request message for `SetIamPolicy` method.
3292type SetIamPolicyRequest struct {
3293	// Policy: REQUIRED: The complete policy to be applied to the
3294	// `resource`. The size of the policy is limited to a few 10s of KB. An
3295	// empty policy is a valid policy but certain Cloud Platform services
3296	// (such as Projects) might reject them.
3297	Policy *Policy `json:"policy,omitempty"`
3298
3299	// ForceSendFields is a list of field names (e.g. "Policy") to
3300	// unconditionally include in API requests. By default, fields with
3301	// empty values are omitted from API requests. However, any non-pointer,
3302	// non-interface field appearing in ForceSendFields will be sent to the
3303	// server regardless of whether the field is empty or not. This may be
3304	// used to include empty fields in Patch requests.
3305	ForceSendFields []string `json:"-"`
3306
3307	// NullFields is a list of field names (e.g. "Policy") to include in API
3308	// requests with the JSON null value. By default, fields with empty
3309	// values are omitted from API requests. However, any field with an
3310	// empty value appearing in NullFields will be sent to the server as
3311	// null. It is an error if a field in this list has a non-empty value.
3312	// This may be used to include null fields in Patch requests.
3313	NullFields []string `json:"-"`
3314}
3315
3316func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
3317	type NoMethod SetIamPolicyRequest
3318	raw := NoMethod(*s)
3319	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3320}
3321
3322// Signature: Verifiers (e.g. Kritis implementations) MUST verify
3323// signatures with respect to the trust anchors defined in policy (e.g.
3324// a Kritis policy). Typically this means that the verifier has been
3325// configured with a map from `public_key_id` to public key material
3326// (and any required parameters, e.g. signing algorithm). In particular,
3327// verification implementations MUST NOT treat the signature
3328// `public_key_id` as anything more than a key lookup hint. The
3329// `public_key_id` DOES NOT validate or authenticate a public key; it
3330// only provides a mechanism for quickly selecting a public key ALREADY
3331// CONFIGURED on the verifier through a trusted channel. Verification
3332// implementations MUST reject signatures in any of the following
3333// circumstances: * The `public_key_id` is not recognized by the
3334// verifier. * The public key that `public_key_id` refers to does not
3335// verify the signature with respect to the payload. The `signature`
3336// contents SHOULD NOT be "attached" (where the payload is included with
3337// the serialized `signature` bytes). Verifiers MUST ignore any
3338// "attached" payload and only verify signatures with respect to
3339// explicitly provided payload (e.g. a `payload` field on the proto
3340// message that holds this Signature, or the canonical serialization of
3341// the proto message that holds this signature).
3342type Signature struct {
3343	// PublicKeyId: The identifier for the public key that verifies this
3344	// signature. * The `public_key_id` is required. * The `public_key_id`
3345	// SHOULD be an RFC3986 conformant URI. * When possible, the
3346	// `public_key_id` SHOULD be an immutable reference, such as a
3347	// cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4
3348	// public key fingerprint: *
3349	// "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See
3350	// https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for
3351	// more details on this scheme. RFC6920 digest-named
3352	// SubjectPublicKeyInfo (digest of the DER serialization): *
3353	// "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" *
3354	// "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95
3355	// a1271589a5"
3356	PublicKeyId string `json:"publicKeyId,omitempty"`
3357
3358	// Signature: The content of the signature, an opaque bytestring. The
3359	// payload that this signature verifies MUST be unambiguously provided
3360	// with the Signature during verification. A wrapper message might
3361	// provide the payload explicitly. Alternatively, a message might have a
3362	// canonical serialization that can always be unambiguously computed to
3363	// derive the payload.
3364	Signature string `json:"signature,omitempty"`
3365
3366	// ForceSendFields is a list of field names (e.g. "PublicKeyId") to
3367	// unconditionally include in API requests. By default, fields with
3368	// empty values are omitted from API requests. However, any non-pointer,
3369	// non-interface field appearing in ForceSendFields will be sent to the
3370	// server regardless of whether the field is empty or not. This may be
3371	// used to include empty fields in Patch requests.
3372	ForceSendFields []string `json:"-"`
3373
3374	// NullFields is a list of field names (e.g. "PublicKeyId") to include
3375	// in API requests with the JSON null value. By default, fields with
3376	// empty values are omitted from API requests. However, any field with
3377	// an empty value appearing in NullFields will be sent to the server as
3378	// null. It is an error if a field in this list has a non-empty value.
3379	// This may be used to include null fields in Patch requests.
3380	NullFields []string `json:"-"`
3381}
3382
3383func (s *Signature) MarshalJSON() ([]byte, error) {
3384	type NoMethod Signature
3385	raw := NoMethod(*s)
3386	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3387}
3388
3389// SigningKey: This defines the format used to record keys used in the
3390// software supply chain. An in-toto link is attested using one or more
3391// keys defined in the in-toto layout. An example of this is: {
3392// "key_id":
3393// "776a00e29f3559e0141b3b096f696abc6cfb0c657ab40f441132b345b0...",
3394// "key_type": "rsa", "public_key_value": "-----BEGIN PUBLIC
3395// KEY-----\nMIIBojANBgkqhkiG9w0B...", "key_scheme": "rsassa-pss-sha256"
3396// } The format for in-toto's key definition can be found in section 4.2
3397// of the in-toto specification.
3398type SigningKey struct {
3399	// KeyId: key_id is an identifier for the signing key.
3400	KeyId string `json:"keyId,omitempty"`
3401
3402	// KeyScheme: This field contains the corresponding signature scheme.
3403	// Eg: "rsassa-pss-sha256".
3404	KeyScheme string `json:"keyScheme,omitempty"`
3405
3406	// KeyType: This field identifies the specific signing method. Eg:
3407	// "rsa", "ed25519", and "ecdsa".
3408	KeyType string `json:"keyType,omitempty"`
3409
3410	// PublicKeyValue: This field contains the actual public key.
3411	PublicKeyValue string `json:"publicKeyValue,omitempty"`
3412
3413	// ForceSendFields is a list of field names (e.g. "KeyId") to
3414	// unconditionally include in API requests. By default, fields with
3415	// empty values are omitted from API requests. However, any non-pointer,
3416	// non-interface field appearing in ForceSendFields will be sent to the
3417	// server regardless of whether the field is empty or not. This may be
3418	// used to include empty fields in Patch requests.
3419	ForceSendFields []string `json:"-"`
3420
3421	// NullFields is a list of field names (e.g. "KeyId") to include in API
3422	// requests with the JSON null value. By default, fields with empty
3423	// values are omitted from API requests. However, any field with an
3424	// empty value appearing in NullFields will be sent to the server as
3425	// null. It is an error if a field in this list has a non-empty value.
3426	// This may be used to include null fields in Patch requests.
3427	NullFields []string `json:"-"`
3428}
3429
3430func (s *SigningKey) MarshalJSON() ([]byte, error) {
3431	type NoMethod SigningKey
3432	raw := NoMethod(*s)
3433	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3434}
3435
3436// Source: Source describes the location of the source used for the
3437// build.
3438type Source struct {
3439	// AdditionalContexts: If provided, some of the source code used for the
3440	// build may be found in these locations, in the case where the source
3441	// repository had multiple remotes or submodules. This list will not
3442	// include the context specified in the context field.
3443	AdditionalContexts []*SourceContext `json:"additionalContexts,omitempty"`
3444
3445	// ArtifactStorageSourceUri: If provided, the input binary artifacts for
3446	// the build came from this location.
3447	ArtifactStorageSourceUri string `json:"artifactStorageSourceUri,omitempty"`
3448
3449	// Context: If provided, the source code used for the build came from
3450	// this location.
3451	Context *SourceContext `json:"context,omitempty"`
3452
3453	// FileHashes: Hash(es) of the build source, which can be used to verify
3454	// that the original source integrity was maintained in the build. The
3455	// keys to this map are file paths used as build source and the values
3456	// contain the hash values for those files. If the build source came in
3457	// a single package such as a gzipped tarfile (.tar.gz), the FileHash
3458	// will be for the single path to that file.
3459	FileHashes map[string]FileHashes `json:"fileHashes,omitempty"`
3460
3461	// ForceSendFields is a list of field names (e.g. "AdditionalContexts")
3462	// to unconditionally include in API requests. By default, fields with
3463	// empty values are omitted from API requests. However, any non-pointer,
3464	// non-interface field appearing in ForceSendFields will be sent to the
3465	// server regardless of whether the field is empty or not. This may be
3466	// used to include empty fields in Patch requests.
3467	ForceSendFields []string `json:"-"`
3468
3469	// NullFields is a list of field names (e.g. "AdditionalContexts") to
3470	// include in API requests with the JSON null value. By default, fields
3471	// with empty values are omitted from API requests. However, any field
3472	// with an empty value appearing in NullFields will be sent to the
3473	// server as null. It is an error if a field in this list has a
3474	// non-empty value. This may be used to include null fields in Patch
3475	// requests.
3476	NullFields []string `json:"-"`
3477}
3478
3479func (s *Source) MarshalJSON() ([]byte, error) {
3480	type NoMethod Source
3481	raw := NoMethod(*s)
3482	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3483}
3484
3485// SourceContext: A SourceContext is a reference to a tree of files. A
3486// SourceContext together with a path point to a unique revision of a
3487// single file or directory.
3488type SourceContext struct {
3489	// CloudRepo: A SourceContext referring to a revision in a Google Cloud
3490	// Source Repo.
3491	CloudRepo *CloudRepoSourceContext `json:"cloudRepo,omitempty"`
3492
3493	// Gerrit: A SourceContext referring to a Gerrit project.
3494	Gerrit *GerritSourceContext `json:"gerrit,omitempty"`
3495
3496	// Git: A SourceContext referring to any third party Git repo (e.g.,
3497	// GitHub).
3498	Git *GitSourceContext `json:"git,omitempty"`
3499
3500	// Labels: Labels with user defined metadata.
3501	Labels map[string]string `json:"labels,omitempty"`
3502
3503	// ForceSendFields is a list of field names (e.g. "CloudRepo") to
3504	// unconditionally include in API requests. By default, fields with
3505	// empty values are omitted from API requests. However, any non-pointer,
3506	// non-interface field appearing in ForceSendFields will be sent to the
3507	// server regardless of whether the field is empty or not. This may be
3508	// used to include empty fields in Patch requests.
3509	ForceSendFields []string `json:"-"`
3510
3511	// NullFields is a list of field names (e.g. "CloudRepo") to include in
3512	// API requests with the JSON null value. By default, fields with empty
3513	// values are omitted from API requests. However, any field with an
3514	// empty value appearing in NullFields will be sent to the server as
3515	// null. It is an error if a field in this list has a non-empty value.
3516	// This may be used to include null fields in Patch requests.
3517	NullFields []string `json:"-"`
3518}
3519
3520func (s *SourceContext) MarshalJSON() ([]byte, error) {
3521	type NoMethod SourceContext
3522	raw := NoMethod(*s)
3523	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3524}
3525
3526// Status: The `Status` type defines a logical error model that is
3527// suitable for different programming environments, including REST APIs
3528// and RPC APIs. It is used by gRPC (https://github.com/grpc). Each
3529// `Status` message contains three pieces of data: error code, error
3530// message, and error details. You can find out more about this error
3531// model and how to work with it in the API Design Guide
3532// (https://cloud.google.com/apis/design/errors).
3533type Status struct {
3534	// Code: The status code, which should be an enum value of
3535	// google.rpc.Code.
3536	Code int64 `json:"code,omitempty"`
3537
3538	// Details: A list of messages that carry the error details. There is a
3539	// common set of message types for APIs to use.
3540	Details []googleapi.RawMessage `json:"details,omitempty"`
3541
3542	// Message: A developer-facing error message, which should be in
3543	// English. Any user-facing error message should be localized and sent
3544	// in the google.rpc.Status.details field, or localized by the client.
3545	Message string `json:"message,omitempty"`
3546
3547	// ForceSendFields is a list of field names (e.g. "Code") to
3548	// unconditionally include in API requests. By default, fields with
3549	// empty values are omitted from API requests. However, any non-pointer,
3550	// non-interface field appearing in ForceSendFields will be sent to the
3551	// server regardless of whether the field is empty or not. This may be
3552	// used to include empty fields in Patch requests.
3553	ForceSendFields []string `json:"-"`
3554
3555	// NullFields is a list of field names (e.g. "Code") to include in API
3556	// requests with the JSON null value. By default, fields with empty
3557	// values are omitted from API requests. However, any field with an
3558	// empty value appearing in NullFields will be sent to the server as
3559	// null. It is an error if a field in this list has a non-empty value.
3560	// This may be used to include null fields in Patch requests.
3561	NullFields []string `json:"-"`
3562}
3563
3564func (s *Status) MarshalJSON() ([]byte, error) {
3565	type NoMethod Status
3566	raw := NoMethod(*s)
3567	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3568}
3569
3570// TestIamPermissionsRequest: Request message for `TestIamPermissions`
3571// method.
3572type TestIamPermissionsRequest struct {
3573	// Permissions: The set of permissions to check for the `resource`.
3574	// Permissions with wildcards (such as '*' or 'storage.*') are not
3575	// allowed. For more information see IAM Overview
3576	// (https://cloud.google.com/iam/docs/overview#permissions).
3577	Permissions []string `json:"permissions,omitempty"`
3578
3579	// ForceSendFields is a list of field names (e.g. "Permissions") to
3580	// unconditionally include in API requests. By default, fields with
3581	// empty values are omitted from API requests. However, any non-pointer,
3582	// non-interface field appearing in ForceSendFields will be sent to the
3583	// server regardless of whether the field is empty or not. This may be
3584	// used to include empty fields in Patch requests.
3585	ForceSendFields []string `json:"-"`
3586
3587	// NullFields is a list of field names (e.g. "Permissions") to include
3588	// in API requests with the JSON null value. By default, fields with
3589	// empty values are omitted from API requests. However, any field with
3590	// an empty value appearing in NullFields will be sent to the server as
3591	// null. It is an error if a field in this list has a non-empty value.
3592	// This may be used to include null fields in Patch requests.
3593	NullFields []string `json:"-"`
3594}
3595
3596func (s *TestIamPermissionsRequest) MarshalJSON() ([]byte, error) {
3597	type NoMethod TestIamPermissionsRequest
3598	raw := NoMethod(*s)
3599	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3600}
3601
3602// TestIamPermissionsResponse: Response message for `TestIamPermissions`
3603// method.
3604type TestIamPermissionsResponse struct {
3605	// Permissions: A subset of `TestPermissionsRequest.permissions` that
3606	// the caller is allowed.
3607	Permissions []string `json:"permissions,omitempty"`
3608
3609	// ServerResponse contains the HTTP response code and headers from the
3610	// server.
3611	googleapi.ServerResponse `json:"-"`
3612
3613	// ForceSendFields is a list of field names (e.g. "Permissions") to
3614	// unconditionally include in API requests. By default, fields with
3615	// empty values are omitted from API requests. However, any non-pointer,
3616	// non-interface field appearing in ForceSendFields will be sent to the
3617	// server regardless of whether the field is empty or not. This may be
3618	// used to include empty fields in Patch requests.
3619	ForceSendFields []string `json:"-"`
3620
3621	// NullFields is a list of field names (e.g. "Permissions") to include
3622	// in API requests with the JSON null value. By default, fields with
3623	// empty values are omitted from API requests. However, any field with
3624	// an empty value appearing in NullFields will be sent to the server as
3625	// null. It is an error if a field in this list has a non-empty value.
3626	// This may be used to include null fields in Patch requests.
3627	NullFields []string `json:"-"`
3628}
3629
3630func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) {
3631	type NoMethod TestIamPermissionsResponse
3632	raw := NoMethod(*s)
3633	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3634}
3635
3636// Version: Version contains structured information about the version of
3637// a package.
3638type Version struct {
3639	// Epoch: Used to correct mistakes in the version numbering scheme.
3640	Epoch int64 `json:"epoch,omitempty"`
3641
3642	// Inclusive: Whether this version is specifying part of an inclusive
3643	// range. Grafeas does not have the capability to specify version
3644	// ranges; instead we have fields that specify start version and end
3645	// versions. At times this is insufficient - we also need to specify
3646	// whether the version is included in the range or is excluded from the
3647	// range. This boolean is expected to be set to true when the version is
3648	// included in a range.
3649	Inclusive bool `json:"inclusive,omitempty"`
3650
3651	// Kind: Required. Distinguishes between sentinel MIN/MAX versions and
3652	// normal versions.
3653	//
3654	// Possible values:
3655	//   "VERSION_KIND_UNSPECIFIED" - Unknown.
3656	//   "NORMAL" - A standard package version.
3657	//   "MINIMUM" - A special version representing negative infinity.
3658	//   "MAXIMUM" - A special version representing positive infinity.
3659	Kind string `json:"kind,omitempty"`
3660
3661	// Name: Required only when version kind is NORMAL. The main part of the
3662	// version name.
3663	Name string `json:"name,omitempty"`
3664
3665	// Revision: The iteration of the package build from the above version.
3666	Revision string `json:"revision,omitempty"`
3667
3668	// ForceSendFields is a list of field names (e.g. "Epoch") to
3669	// unconditionally include in API requests. By default, fields with
3670	// empty values are omitted from API requests. However, any non-pointer,
3671	// non-interface field appearing in ForceSendFields will be sent to the
3672	// server regardless of whether the field is empty or not. This may be
3673	// used to include empty fields in Patch requests.
3674	ForceSendFields []string `json:"-"`
3675
3676	// NullFields is a list of field names (e.g. "Epoch") to include in API
3677	// requests with the JSON null value. By default, fields with empty
3678	// values are omitted from API requests. However, any field with an
3679	// empty value appearing in NullFields will be sent to the server as
3680	// null. It is an error if a field in this list has a non-empty value.
3681	// This may be used to include null fields in Patch requests.
3682	NullFields []string `json:"-"`
3683}
3684
3685func (s *Version) MarshalJSON() ([]byte, error) {
3686	type NoMethod Version
3687	raw := NoMethod(*s)
3688	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3689}
3690
3691// Vulnerability: Vulnerability provides metadata about a security
3692// vulnerability in a Note.
3693type Vulnerability struct {
3694	// CvssScore: The CVSS score for this vulnerability.
3695	CvssScore float64 `json:"cvssScore,omitempty"`
3696
3697	// CvssV3: The full description of the CVSSv3.
3698	CvssV3 *CVSSv3 `json:"cvssV3,omitempty"`
3699
3700	// Details: All information about the package to specifically identify
3701	// this vulnerability. One entry per (version range and cpe_uri) the
3702	// package vulnerability has manifested in.
3703	Details []*Detail `json:"details,omitempty"`
3704
3705	// Severity: Note provider assigned impact of the vulnerability.
3706	//
3707	// Possible values:
3708	//   "SEVERITY_UNSPECIFIED" - Unknown.
3709	//   "MINIMAL" - Minimal severity.
3710	//   "LOW" - Low severity.
3711	//   "MEDIUM" - Medium severity.
3712	//   "HIGH" - High severity.
3713	//   "CRITICAL" - Critical severity.
3714	Severity string `json:"severity,omitempty"`
3715
3716	// SourceUpdateTime: The time this information was last changed at the
3717	// source. This is an upstream timestamp from the underlying information
3718	// source - e.g. Ubuntu security tracker.
3719	SourceUpdateTime string `json:"sourceUpdateTime,omitempty"`
3720
3721	// WindowsDetails: Windows details get their own format because the
3722	// information format and model don't match a normal detail.
3723	// Specifically Windows updates are done as patches, thus Windows
3724	// vulnerabilities really are a missing package, rather than a package
3725	// being at an incorrect version.
3726	WindowsDetails []*WindowsDetail `json:"windowsDetails,omitempty"`
3727
3728	// ForceSendFields is a list of field names (e.g. "CvssScore") to
3729	// unconditionally include in API requests. By default, fields with
3730	// empty values are omitted from API requests. However, any non-pointer,
3731	// non-interface field appearing in ForceSendFields will be sent to the
3732	// server regardless of whether the field is empty or not. This may be
3733	// used to include empty fields in Patch requests.
3734	ForceSendFields []string `json:"-"`
3735
3736	// NullFields is a list of field names (e.g. "CvssScore") to include in
3737	// API requests with the JSON null value. By default, fields with empty
3738	// values are omitted from API requests. However, any field with an
3739	// empty value appearing in NullFields will be sent to the server as
3740	// null. It is an error if a field in this list has a non-empty value.
3741	// This may be used to include null fields in Patch requests.
3742	NullFields []string `json:"-"`
3743}
3744
3745func (s *Vulnerability) MarshalJSON() ([]byte, error) {
3746	type NoMethod Vulnerability
3747	raw := NoMethod(*s)
3748	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3749}
3750
3751func (s *Vulnerability) UnmarshalJSON(data []byte) error {
3752	type NoMethod Vulnerability
3753	var s1 struct {
3754		CvssScore gensupport.JSONFloat64 `json:"cvssScore"`
3755		*NoMethod
3756	}
3757	s1.NoMethod = (*NoMethod)(s)
3758	if err := json.Unmarshal(data, &s1); err != nil {
3759		return err
3760	}
3761	s.CvssScore = float64(s1.CvssScore)
3762	return nil
3763}
3764
3765// VulnerabilityLocation: The location of the vulnerability.
3766type VulnerabilityLocation struct {
3767	// CpeUri: Required. The CPE URI in cpe format
3768	// (https://cpe.mitre.org/specification/) format. Examples include
3769	// distro or storage location for vulnerable jar.
3770	CpeUri string `json:"cpeUri,omitempty"`
3771
3772	// Package: Required. The package being described.
3773	Package string `json:"package,omitempty"`
3774
3775	// Version: Required. The version of the package being described.
3776	Version *Version `json:"version,omitempty"`
3777
3778	// ForceSendFields is a list of field names (e.g. "CpeUri") to
3779	// unconditionally include in API requests. By default, fields with
3780	// empty values are omitted from API requests. However, any non-pointer,
3781	// non-interface field appearing in ForceSendFields will be sent to the
3782	// server regardless of whether the field is empty or not. This may be
3783	// used to include empty fields in Patch requests.
3784	ForceSendFields []string `json:"-"`
3785
3786	// NullFields is a list of field names (e.g. "CpeUri") to include in API
3787	// requests with the JSON null value. By default, fields with empty
3788	// values are omitted from API requests. However, any field with an
3789	// empty value appearing in NullFields will be sent to the server as
3790	// null. It is an error if a field in this list has a non-empty value.
3791	// This may be used to include null fields in Patch requests.
3792	NullFields []string `json:"-"`
3793}
3794
3795func (s *VulnerabilityLocation) MarshalJSON() ([]byte, error) {
3796	type NoMethod VulnerabilityLocation
3797	raw := NoMethod(*s)
3798	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3799}
3800
3801// VulnerabilityOccurrencesSummary: A summary of how many vulnerability
3802// occurrences there are per resource and severity type.
3803type VulnerabilityOccurrencesSummary struct {
3804	// Counts: A listing by resource of the number of fixable and total
3805	// vulnerabilities.
3806	Counts []*FixableTotalByDigest `json:"counts,omitempty"`
3807
3808	// ServerResponse contains the HTTP response code and headers from the
3809	// server.
3810	googleapi.ServerResponse `json:"-"`
3811
3812	// ForceSendFields is a list of field names (e.g. "Counts") to
3813	// unconditionally include in API requests. By default, fields with
3814	// empty values are omitted from API requests. However, any non-pointer,
3815	// non-interface field appearing in ForceSendFields will be sent to the
3816	// server regardless of whether the field is empty or not. This may be
3817	// used to include empty fields in Patch requests.
3818	ForceSendFields []string `json:"-"`
3819
3820	// NullFields is a list of field names (e.g. "Counts") to include in API
3821	// requests with the JSON null value. By default, fields with empty
3822	// values are omitted from API requests. However, any field with an
3823	// empty value appearing in NullFields will be sent to the server as
3824	// null. It is an error if a field in this list has a non-empty value.
3825	// This may be used to include null fields in Patch requests.
3826	NullFields []string `json:"-"`
3827}
3828
3829func (s *VulnerabilityOccurrencesSummary) MarshalJSON() ([]byte, error) {
3830	type NoMethod VulnerabilityOccurrencesSummary
3831	raw := NoMethod(*s)
3832	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3833}
3834
3835type WindowsDetail struct {
3836	// CpeUri: Required. The CPE URI in cpe format
3837	// (https://cpe.mitre.org/specification/) in which the vulnerability
3838	// manifests. Examples include distro or storage location for vulnerable
3839	// jar.
3840	CpeUri string `json:"cpeUri,omitempty"`
3841
3842	// Description: The description of the vulnerability.
3843	Description string `json:"description,omitempty"`
3844
3845	// FixingKbs: Required. The names of the KBs which have hotfixes to
3846	// mitigate this vulnerability. Note that there may be multiple hotfixes
3847	// (and thus multiple KBs) that mitigate a given vulnerability.
3848	// Currently any listed kb's presence is considered a fix.
3849	FixingKbs []*KnowledgeBase `json:"fixingKbs,omitempty"`
3850
3851	// Name: Required. The name of the vulnerability.
3852	Name string `json:"name,omitempty"`
3853
3854	// ForceSendFields is a list of field names (e.g. "CpeUri") to
3855	// unconditionally include in API requests. By default, fields with
3856	// empty values are omitted from API requests. However, any non-pointer,
3857	// non-interface field appearing in ForceSendFields will be sent to the
3858	// server regardless of whether the field is empty or not. This may be
3859	// used to include empty fields in Patch requests.
3860	ForceSendFields []string `json:"-"`
3861
3862	// NullFields is a list of field names (e.g. "CpeUri") to include in API
3863	// requests with the JSON null value. By default, fields with empty
3864	// values are omitted from API requests. However, any field with an
3865	// empty value appearing in NullFields will be sent to the server as
3866	// null. It is an error if a field in this list has a non-empty value.
3867	// This may be used to include null fields in Patch requests.
3868	NullFields []string `json:"-"`
3869}
3870
3871func (s *WindowsDetail) MarshalJSON() ([]byte, error) {
3872	type NoMethod WindowsDetail
3873	raw := NoMethod(*s)
3874	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3875}
3876
3877// method id "containeranalysis.projects.notes.batchCreate":
3878
3879type ProjectsNotesBatchCreateCall struct {
3880	s                       *Service
3881	parent                  string
3882	batchcreatenotesrequest *BatchCreateNotesRequest
3883	urlParams_              gensupport.URLParams
3884	ctx_                    context.Context
3885	header_                 http.Header
3886}
3887
3888// BatchCreate: Creates new notes in batch.
3889//
3890// - parent: The name of the project in the form of
3891//   `projects/[PROJECT_ID]`, under which the notes are to be created.
3892func (r *ProjectsNotesService) BatchCreate(parent string, batchcreatenotesrequest *BatchCreateNotesRequest) *ProjectsNotesBatchCreateCall {
3893	c := &ProjectsNotesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
3894	c.parent = parent
3895	c.batchcreatenotesrequest = batchcreatenotesrequest
3896	return c
3897}
3898
3899// Fields allows partial responses to be retrieved. See
3900// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
3901// for more information.
3902func (c *ProjectsNotesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsNotesBatchCreateCall {
3903	c.urlParams_.Set("fields", googleapi.CombineFields(s))
3904	return c
3905}
3906
3907// Context sets the context to be used in this call's Do method. Any
3908// pending HTTP request will be aborted if the provided context is
3909// canceled.
3910func (c *ProjectsNotesBatchCreateCall) Context(ctx context.Context) *ProjectsNotesBatchCreateCall {
3911	c.ctx_ = ctx
3912	return c
3913}
3914
3915// Header returns an http.Header that can be modified by the caller to
3916// add HTTP headers to the request.
3917func (c *ProjectsNotesBatchCreateCall) Header() http.Header {
3918	if c.header_ == nil {
3919		c.header_ = make(http.Header)
3920	}
3921	return c.header_
3922}
3923
3924func (c *ProjectsNotesBatchCreateCall) doRequest(alt string) (*http.Response, error) {
3925	reqHeaders := make(http.Header)
3926	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
3927	for k, v := range c.header_ {
3928		reqHeaders[k] = v
3929	}
3930	reqHeaders.Set("User-Agent", c.s.userAgent())
3931	var body io.Reader = nil
3932	body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchcreatenotesrequest)
3933	if err != nil {
3934		return nil, err
3935	}
3936	reqHeaders.Set("Content-Type", "application/json")
3937	c.urlParams_.Set("alt", alt)
3938	c.urlParams_.Set("prettyPrint", "false")
3939	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/notes:batchCreate")
3940	urls += "?" + c.urlParams_.Encode()
3941	req, err := http.NewRequest("POST", urls, body)
3942	if err != nil {
3943		return nil, err
3944	}
3945	req.Header = reqHeaders
3946	googleapi.Expand(req.URL, map[string]string{
3947		"parent": c.parent,
3948	})
3949	return gensupport.SendRequest(c.ctx_, c.s.client, req)
3950}
3951
3952// Do executes the "containeranalysis.projects.notes.batchCreate" call.
3953// Exactly one of *BatchCreateNotesResponse or error will be non-nil.
3954// Any non-2xx status code is an error. Response headers are in either
3955// *BatchCreateNotesResponse.ServerResponse.Header or (if a response was
3956// returned at all) in error.(*googleapi.Error).Header. Use
3957// googleapi.IsNotModified to check whether the returned error was
3958// because http.StatusNotModified was returned.
3959func (c *ProjectsNotesBatchCreateCall) Do(opts ...googleapi.CallOption) (*BatchCreateNotesResponse, error) {
3960	gensupport.SetOptions(c.urlParams_, opts...)
3961	res, err := c.doRequest("json")
3962	if res != nil && res.StatusCode == http.StatusNotModified {
3963		if res.Body != nil {
3964			res.Body.Close()
3965		}
3966		return nil, &googleapi.Error{
3967			Code:   res.StatusCode,
3968			Header: res.Header,
3969		}
3970	}
3971	if err != nil {
3972		return nil, err
3973	}
3974	defer googleapi.CloseBody(res)
3975	if err := googleapi.CheckResponse(res); err != nil {
3976		return nil, err
3977	}
3978	ret := &BatchCreateNotesResponse{
3979		ServerResponse: googleapi.ServerResponse{
3980			Header:         res.Header,
3981			HTTPStatusCode: res.StatusCode,
3982		},
3983	}
3984	target := &ret
3985	if err := gensupport.DecodeResponse(target, res); err != nil {
3986		return nil, err
3987	}
3988	return ret, nil
3989	// {
3990	//   "description": "Creates new notes in batch.",
3991	//   "flatPath": "v1beta1/projects/{projectsId}/notes:batchCreate",
3992	//   "httpMethod": "POST",
3993	//   "id": "containeranalysis.projects.notes.batchCreate",
3994	//   "parameterOrder": [
3995	//     "parent"
3996	//   ],
3997	//   "parameters": {
3998	//     "parent": {
3999	//       "description": "Required. The name of the project in the form of `projects/[PROJECT_ID]`, under which the notes are to be created.",
4000	//       "location": "path",
4001	//       "pattern": "^projects/[^/]+$",
4002	//       "required": true,
4003	//       "type": "string"
4004	//     }
4005	//   },
4006	//   "path": "v1beta1/{+parent}/notes:batchCreate",
4007	//   "request": {
4008	//     "$ref": "BatchCreateNotesRequest"
4009	//   },
4010	//   "response": {
4011	//     "$ref": "BatchCreateNotesResponse"
4012	//   },
4013	//   "scopes": [
4014	//     "https://www.googleapis.com/auth/cloud-platform"
4015	//   ]
4016	// }
4017
4018}
4019
4020// method id "containeranalysis.projects.notes.create":
4021
4022type ProjectsNotesCreateCall struct {
4023	s          *Service
4024	parent     string
4025	note       *Note
4026	urlParams_ gensupport.URLParams
4027	ctx_       context.Context
4028	header_    http.Header
4029}
4030
4031// Create: Creates a new note.
4032//
4033// - parent: The name of the project in the form of
4034//   `projects/[PROJECT_ID]`, under which the note is to be created.
4035func (r *ProjectsNotesService) Create(parent string, note *Note) *ProjectsNotesCreateCall {
4036	c := &ProjectsNotesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4037	c.parent = parent
4038	c.note = note
4039	return c
4040}
4041
4042// NoteId sets the optional parameter "noteId": Required. The ID to use
4043// for this note.
4044func (c *ProjectsNotesCreateCall) NoteId(noteId string) *ProjectsNotesCreateCall {
4045	c.urlParams_.Set("noteId", noteId)
4046	return c
4047}
4048
4049// Fields allows partial responses to be retrieved. See
4050// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4051// for more information.
4052func (c *ProjectsNotesCreateCall) Fields(s ...googleapi.Field) *ProjectsNotesCreateCall {
4053	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4054	return c
4055}
4056
4057// Context sets the context to be used in this call's Do method. Any
4058// pending HTTP request will be aborted if the provided context is
4059// canceled.
4060func (c *ProjectsNotesCreateCall) Context(ctx context.Context) *ProjectsNotesCreateCall {
4061	c.ctx_ = ctx
4062	return c
4063}
4064
4065// Header returns an http.Header that can be modified by the caller to
4066// add HTTP headers to the request.
4067func (c *ProjectsNotesCreateCall) Header() http.Header {
4068	if c.header_ == nil {
4069		c.header_ = make(http.Header)
4070	}
4071	return c.header_
4072}
4073
4074func (c *ProjectsNotesCreateCall) doRequest(alt string) (*http.Response, error) {
4075	reqHeaders := make(http.Header)
4076	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
4077	for k, v := range c.header_ {
4078		reqHeaders[k] = v
4079	}
4080	reqHeaders.Set("User-Agent", c.s.userAgent())
4081	var body io.Reader = nil
4082	body, err := googleapi.WithoutDataWrapper.JSONReader(c.note)
4083	if err != nil {
4084		return nil, err
4085	}
4086	reqHeaders.Set("Content-Type", "application/json")
4087	c.urlParams_.Set("alt", alt)
4088	c.urlParams_.Set("prettyPrint", "false")
4089	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/notes")
4090	urls += "?" + c.urlParams_.Encode()
4091	req, err := http.NewRequest("POST", urls, body)
4092	if err != nil {
4093		return nil, err
4094	}
4095	req.Header = reqHeaders
4096	googleapi.Expand(req.URL, map[string]string{
4097		"parent": c.parent,
4098	})
4099	return gensupport.SendRequest(c.ctx_, c.s.client, req)
4100}
4101
4102// Do executes the "containeranalysis.projects.notes.create" call.
4103// Exactly one of *Note or error will be non-nil. Any non-2xx status
4104// code is an error. Response headers are in either
4105// *Note.ServerResponse.Header or (if a response was returned at all) in
4106// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
4107// whether the returned error was because http.StatusNotModified was
4108// returned.
4109func (c *ProjectsNotesCreateCall) Do(opts ...googleapi.CallOption) (*Note, error) {
4110	gensupport.SetOptions(c.urlParams_, opts...)
4111	res, err := c.doRequest("json")
4112	if res != nil && res.StatusCode == http.StatusNotModified {
4113		if res.Body != nil {
4114			res.Body.Close()
4115		}
4116		return nil, &googleapi.Error{
4117			Code:   res.StatusCode,
4118			Header: res.Header,
4119		}
4120	}
4121	if err != nil {
4122		return nil, err
4123	}
4124	defer googleapi.CloseBody(res)
4125	if err := googleapi.CheckResponse(res); err != nil {
4126		return nil, err
4127	}
4128	ret := &Note{
4129		ServerResponse: googleapi.ServerResponse{
4130			Header:         res.Header,
4131			HTTPStatusCode: res.StatusCode,
4132		},
4133	}
4134	target := &ret
4135	if err := gensupport.DecodeResponse(target, res); err != nil {
4136		return nil, err
4137	}
4138	return ret, nil
4139	// {
4140	//   "description": "Creates a new note.",
4141	//   "flatPath": "v1beta1/projects/{projectsId}/notes",
4142	//   "httpMethod": "POST",
4143	//   "id": "containeranalysis.projects.notes.create",
4144	//   "parameterOrder": [
4145	//     "parent"
4146	//   ],
4147	//   "parameters": {
4148	//     "noteId": {
4149	//       "description": "Required. The ID to use for this note.",
4150	//       "location": "query",
4151	//       "type": "string"
4152	//     },
4153	//     "parent": {
4154	//       "description": "Required. The name of the project in the form of `projects/[PROJECT_ID]`, under which the note is to be created.",
4155	//       "location": "path",
4156	//       "pattern": "^projects/[^/]+$",
4157	//       "required": true,
4158	//       "type": "string"
4159	//     }
4160	//   },
4161	//   "path": "v1beta1/{+parent}/notes",
4162	//   "request": {
4163	//     "$ref": "Note"
4164	//   },
4165	//   "response": {
4166	//     "$ref": "Note"
4167	//   },
4168	//   "scopes": [
4169	//     "https://www.googleapis.com/auth/cloud-platform"
4170	//   ]
4171	// }
4172
4173}
4174
4175// method id "containeranalysis.projects.notes.delete":
4176
4177type ProjectsNotesDeleteCall struct {
4178	s          *Service
4179	name       string
4180	urlParams_ gensupport.URLParams
4181	ctx_       context.Context
4182	header_    http.Header
4183}
4184
4185// Delete: Deletes the specified note.
4186//
4187// - name: The name of the note in the form of
4188//   `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
4189func (r *ProjectsNotesService) Delete(name string) *ProjectsNotesDeleteCall {
4190	c := &ProjectsNotesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4191	c.name = name
4192	return c
4193}
4194
4195// Fields allows partial responses to be retrieved. See
4196// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4197// for more information.
4198func (c *ProjectsNotesDeleteCall) Fields(s ...googleapi.Field) *ProjectsNotesDeleteCall {
4199	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4200	return c
4201}
4202
4203// Context sets the context to be used in this call's Do method. Any
4204// pending HTTP request will be aborted if the provided context is
4205// canceled.
4206func (c *ProjectsNotesDeleteCall) Context(ctx context.Context) *ProjectsNotesDeleteCall {
4207	c.ctx_ = ctx
4208	return c
4209}
4210
4211// Header returns an http.Header that can be modified by the caller to
4212// add HTTP headers to the request.
4213func (c *ProjectsNotesDeleteCall) Header() http.Header {
4214	if c.header_ == nil {
4215		c.header_ = make(http.Header)
4216	}
4217	return c.header_
4218}
4219
4220func (c *ProjectsNotesDeleteCall) doRequest(alt string) (*http.Response, error) {
4221	reqHeaders := make(http.Header)
4222	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
4223	for k, v := range c.header_ {
4224		reqHeaders[k] = v
4225	}
4226	reqHeaders.Set("User-Agent", c.s.userAgent())
4227	var body io.Reader = nil
4228	c.urlParams_.Set("alt", alt)
4229	c.urlParams_.Set("prettyPrint", "false")
4230	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
4231	urls += "?" + c.urlParams_.Encode()
4232	req, err := http.NewRequest("DELETE", urls, body)
4233	if err != nil {
4234		return nil, err
4235	}
4236	req.Header = reqHeaders
4237	googleapi.Expand(req.URL, map[string]string{
4238		"name": c.name,
4239	})
4240	return gensupport.SendRequest(c.ctx_, c.s.client, req)
4241}
4242
4243// Do executes the "containeranalysis.projects.notes.delete" call.
4244// Exactly one of *Empty or error will be non-nil. Any non-2xx status
4245// code is an error. Response headers are in either
4246// *Empty.ServerResponse.Header or (if a response was returned at all)
4247// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
4248// check whether the returned error was because http.StatusNotModified
4249// was returned.
4250func (c *ProjectsNotesDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
4251	gensupport.SetOptions(c.urlParams_, opts...)
4252	res, err := c.doRequest("json")
4253	if res != nil && res.StatusCode == http.StatusNotModified {
4254		if res.Body != nil {
4255			res.Body.Close()
4256		}
4257		return nil, &googleapi.Error{
4258			Code:   res.StatusCode,
4259			Header: res.Header,
4260		}
4261	}
4262	if err != nil {
4263		return nil, err
4264	}
4265	defer googleapi.CloseBody(res)
4266	if err := googleapi.CheckResponse(res); err != nil {
4267		return nil, err
4268	}
4269	ret := &Empty{
4270		ServerResponse: googleapi.ServerResponse{
4271			Header:         res.Header,
4272			HTTPStatusCode: res.StatusCode,
4273		},
4274	}
4275	target := &ret
4276	if err := gensupport.DecodeResponse(target, res); err != nil {
4277		return nil, err
4278	}
4279	return ret, nil
4280	// {
4281	//   "description": "Deletes the specified note.",
4282	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}",
4283	//   "httpMethod": "DELETE",
4284	//   "id": "containeranalysis.projects.notes.delete",
4285	//   "parameterOrder": [
4286	//     "name"
4287	//   ],
4288	//   "parameters": {
4289	//     "name": {
4290	//       "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.",
4291	//       "location": "path",
4292	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
4293	//       "required": true,
4294	//       "type": "string"
4295	//     }
4296	//   },
4297	//   "path": "v1beta1/{+name}",
4298	//   "response": {
4299	//     "$ref": "Empty"
4300	//   },
4301	//   "scopes": [
4302	//     "https://www.googleapis.com/auth/cloud-platform"
4303	//   ]
4304	// }
4305
4306}
4307
4308// method id "containeranalysis.projects.notes.get":
4309
4310type ProjectsNotesGetCall struct {
4311	s            *Service
4312	name         string
4313	urlParams_   gensupport.URLParams
4314	ifNoneMatch_ string
4315	ctx_         context.Context
4316	header_      http.Header
4317}
4318
4319// Get: Gets the specified note.
4320//
4321// - name: The name of the note in the form of
4322//   `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
4323func (r *ProjectsNotesService) Get(name string) *ProjectsNotesGetCall {
4324	c := &ProjectsNotesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4325	c.name = name
4326	return c
4327}
4328
4329// Fields allows partial responses to be retrieved. See
4330// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4331// for more information.
4332func (c *ProjectsNotesGetCall) Fields(s ...googleapi.Field) *ProjectsNotesGetCall {
4333	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4334	return c
4335}
4336
4337// IfNoneMatch sets the optional parameter which makes the operation
4338// fail if the object's ETag matches the given value. This is useful for
4339// getting updates only after the object has changed since the last
4340// request. Use googleapi.IsNotModified to check whether the response
4341// error from Do is the result of In-None-Match.
4342func (c *ProjectsNotesGetCall) IfNoneMatch(entityTag string) *ProjectsNotesGetCall {
4343	c.ifNoneMatch_ = entityTag
4344	return c
4345}
4346
4347// Context sets the context to be used in this call's Do method. Any
4348// pending HTTP request will be aborted if the provided context is
4349// canceled.
4350func (c *ProjectsNotesGetCall) Context(ctx context.Context) *ProjectsNotesGetCall {
4351	c.ctx_ = ctx
4352	return c
4353}
4354
4355// Header returns an http.Header that can be modified by the caller to
4356// add HTTP headers to the request.
4357func (c *ProjectsNotesGetCall) Header() http.Header {
4358	if c.header_ == nil {
4359		c.header_ = make(http.Header)
4360	}
4361	return c.header_
4362}
4363
4364func (c *ProjectsNotesGetCall) doRequest(alt string) (*http.Response, error) {
4365	reqHeaders := make(http.Header)
4366	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
4367	for k, v := range c.header_ {
4368		reqHeaders[k] = v
4369	}
4370	reqHeaders.Set("User-Agent", c.s.userAgent())
4371	if c.ifNoneMatch_ != "" {
4372		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
4373	}
4374	var body io.Reader = nil
4375	c.urlParams_.Set("alt", alt)
4376	c.urlParams_.Set("prettyPrint", "false")
4377	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
4378	urls += "?" + c.urlParams_.Encode()
4379	req, err := http.NewRequest("GET", urls, body)
4380	if err != nil {
4381		return nil, err
4382	}
4383	req.Header = reqHeaders
4384	googleapi.Expand(req.URL, map[string]string{
4385		"name": c.name,
4386	})
4387	return gensupport.SendRequest(c.ctx_, c.s.client, req)
4388}
4389
4390// Do executes the "containeranalysis.projects.notes.get" call.
4391// Exactly one of *Note or error will be non-nil. Any non-2xx status
4392// code is an error. Response headers are in either
4393// *Note.ServerResponse.Header or (if a response was returned at all) in
4394// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
4395// whether the returned error was because http.StatusNotModified was
4396// returned.
4397func (c *ProjectsNotesGetCall) Do(opts ...googleapi.CallOption) (*Note, error) {
4398	gensupport.SetOptions(c.urlParams_, opts...)
4399	res, err := c.doRequest("json")
4400	if res != nil && res.StatusCode == http.StatusNotModified {
4401		if res.Body != nil {
4402			res.Body.Close()
4403		}
4404		return nil, &googleapi.Error{
4405			Code:   res.StatusCode,
4406			Header: res.Header,
4407		}
4408	}
4409	if err != nil {
4410		return nil, err
4411	}
4412	defer googleapi.CloseBody(res)
4413	if err := googleapi.CheckResponse(res); err != nil {
4414		return nil, err
4415	}
4416	ret := &Note{
4417		ServerResponse: googleapi.ServerResponse{
4418			Header:         res.Header,
4419			HTTPStatusCode: res.StatusCode,
4420		},
4421	}
4422	target := &ret
4423	if err := gensupport.DecodeResponse(target, res); err != nil {
4424		return nil, err
4425	}
4426	return ret, nil
4427	// {
4428	//   "description": "Gets the specified note.",
4429	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}",
4430	//   "httpMethod": "GET",
4431	//   "id": "containeranalysis.projects.notes.get",
4432	//   "parameterOrder": [
4433	//     "name"
4434	//   ],
4435	//   "parameters": {
4436	//     "name": {
4437	//       "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.",
4438	//       "location": "path",
4439	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
4440	//       "required": true,
4441	//       "type": "string"
4442	//     }
4443	//   },
4444	//   "path": "v1beta1/{+name}",
4445	//   "response": {
4446	//     "$ref": "Note"
4447	//   },
4448	//   "scopes": [
4449	//     "https://www.googleapis.com/auth/cloud-platform"
4450	//   ]
4451	// }
4452
4453}
4454
4455// method id "containeranalysis.projects.notes.getIamPolicy":
4456
4457type ProjectsNotesGetIamPolicyCall struct {
4458	s                   *Service
4459	resource            string
4460	getiampolicyrequest *GetIamPolicyRequest
4461	urlParams_          gensupport.URLParams
4462	ctx_                context.Context
4463	header_             http.Header
4464}
4465
4466// GetIamPolicy: Gets the access control policy for a note or an
4467// occurrence resource. Requires `containeranalysis.notes.setIamPolicy`
4468// or `containeranalysis.occurrences.setIamPolicy` permission if the
4469// resource is a note or occurrence, respectively. The resource takes
4470// the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and
4471// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.
4472//
4473// - resource: REQUIRED: The resource for which the policy is being
4474//   requested. See the operation documentation for the appropriate
4475//   value for this field.
4476func (r *ProjectsNotesService) GetIamPolicy(resource string, getiampolicyrequest *GetIamPolicyRequest) *ProjectsNotesGetIamPolicyCall {
4477	c := &ProjectsNotesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4478	c.resource = resource
4479	c.getiampolicyrequest = getiampolicyrequest
4480	return c
4481}
4482
4483// Fields allows partial responses to be retrieved. See
4484// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4485// for more information.
4486func (c *ProjectsNotesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsNotesGetIamPolicyCall {
4487	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4488	return c
4489}
4490
4491// Context sets the context to be used in this call's Do method. Any
4492// pending HTTP request will be aborted if the provided context is
4493// canceled.
4494func (c *ProjectsNotesGetIamPolicyCall) Context(ctx context.Context) *ProjectsNotesGetIamPolicyCall {
4495	c.ctx_ = ctx
4496	return c
4497}
4498
4499// Header returns an http.Header that can be modified by the caller to
4500// add HTTP headers to the request.
4501func (c *ProjectsNotesGetIamPolicyCall) Header() http.Header {
4502	if c.header_ == nil {
4503		c.header_ = make(http.Header)
4504	}
4505	return c.header_
4506}
4507
4508func (c *ProjectsNotesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
4509	reqHeaders := make(http.Header)
4510	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
4511	for k, v := range c.header_ {
4512		reqHeaders[k] = v
4513	}
4514	reqHeaders.Set("User-Agent", c.s.userAgent())
4515	var body io.Reader = nil
4516	body, err := googleapi.WithoutDataWrapper.JSONReader(c.getiampolicyrequest)
4517	if err != nil {
4518		return nil, err
4519	}
4520	reqHeaders.Set("Content-Type", "application/json")
4521	c.urlParams_.Set("alt", alt)
4522	c.urlParams_.Set("prettyPrint", "false")
4523	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:getIamPolicy")
4524	urls += "?" + c.urlParams_.Encode()
4525	req, err := http.NewRequest("POST", urls, body)
4526	if err != nil {
4527		return nil, err
4528	}
4529	req.Header = reqHeaders
4530	googleapi.Expand(req.URL, map[string]string{
4531		"resource": c.resource,
4532	})
4533	return gensupport.SendRequest(c.ctx_, c.s.client, req)
4534}
4535
4536// Do executes the "containeranalysis.projects.notes.getIamPolicy" call.
4537// Exactly one of *Policy or error will be non-nil. Any non-2xx status
4538// code is an error. Response headers are in either
4539// *Policy.ServerResponse.Header or (if a response was returned at all)
4540// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
4541// check whether the returned error was because http.StatusNotModified
4542// was returned.
4543func (c *ProjectsNotesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
4544	gensupport.SetOptions(c.urlParams_, opts...)
4545	res, err := c.doRequest("json")
4546	if res != nil && res.StatusCode == http.StatusNotModified {
4547		if res.Body != nil {
4548			res.Body.Close()
4549		}
4550		return nil, &googleapi.Error{
4551			Code:   res.StatusCode,
4552			Header: res.Header,
4553		}
4554	}
4555	if err != nil {
4556		return nil, err
4557	}
4558	defer googleapi.CloseBody(res)
4559	if err := googleapi.CheckResponse(res); err != nil {
4560		return nil, err
4561	}
4562	ret := &Policy{
4563		ServerResponse: googleapi.ServerResponse{
4564			Header:         res.Header,
4565			HTTPStatusCode: res.StatusCode,
4566		},
4567	}
4568	target := &ret
4569	if err := gensupport.DecodeResponse(target, res); err != nil {
4570		return nil, err
4571	}
4572	return ret, nil
4573	// {
4574	//   "description": "Gets the access control policy for a note or an occurrence resource. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.",
4575	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}:getIamPolicy",
4576	//   "httpMethod": "POST",
4577	//   "id": "containeranalysis.projects.notes.getIamPolicy",
4578	//   "parameterOrder": [
4579	//     "resource"
4580	//   ],
4581	//   "parameters": {
4582	//     "resource": {
4583	//       "description": "REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.",
4584	//       "location": "path",
4585	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
4586	//       "required": true,
4587	//       "type": "string"
4588	//     }
4589	//   },
4590	//   "path": "v1beta1/{+resource}:getIamPolicy",
4591	//   "request": {
4592	//     "$ref": "GetIamPolicyRequest"
4593	//   },
4594	//   "response": {
4595	//     "$ref": "Policy"
4596	//   },
4597	//   "scopes": [
4598	//     "https://www.googleapis.com/auth/cloud-platform"
4599	//   ]
4600	// }
4601
4602}
4603
4604// method id "containeranalysis.projects.notes.list":
4605
4606type ProjectsNotesListCall struct {
4607	s            *Service
4608	parent       string
4609	urlParams_   gensupport.URLParams
4610	ifNoneMatch_ string
4611	ctx_         context.Context
4612	header_      http.Header
4613}
4614
4615// List: Lists notes for the specified project.
4616//
4617// - parent: The name of the project to list notes for in the form of
4618//   `projects/[PROJECT_ID]`.
4619func (r *ProjectsNotesService) List(parent string) *ProjectsNotesListCall {
4620	c := &ProjectsNotesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4621	c.parent = parent
4622	return c
4623}
4624
4625// Filter sets the optional parameter "filter": The filter expression.
4626func (c *ProjectsNotesListCall) Filter(filter string) *ProjectsNotesListCall {
4627	c.urlParams_.Set("filter", filter)
4628	return c
4629}
4630
4631// PageSize sets the optional parameter "pageSize": Number of notes to
4632// return in the list. Must be positive. Max allowed page size is 1000.
4633// If not specified, page size defaults to 20.
4634func (c *ProjectsNotesListCall) PageSize(pageSize int64) *ProjectsNotesListCall {
4635	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
4636	return c
4637}
4638
4639// PageToken sets the optional parameter "pageToken": Token to provide
4640// to skip to a particular spot in the list.
4641func (c *ProjectsNotesListCall) PageToken(pageToken string) *ProjectsNotesListCall {
4642	c.urlParams_.Set("pageToken", pageToken)
4643	return c
4644}
4645
4646// Fields allows partial responses to be retrieved. See
4647// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4648// for more information.
4649func (c *ProjectsNotesListCall) Fields(s ...googleapi.Field) *ProjectsNotesListCall {
4650	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4651	return c
4652}
4653
4654// IfNoneMatch sets the optional parameter which makes the operation
4655// fail if the object's ETag matches the given value. This is useful for
4656// getting updates only after the object has changed since the last
4657// request. Use googleapi.IsNotModified to check whether the response
4658// error from Do is the result of In-None-Match.
4659func (c *ProjectsNotesListCall) IfNoneMatch(entityTag string) *ProjectsNotesListCall {
4660	c.ifNoneMatch_ = entityTag
4661	return c
4662}
4663
4664// Context sets the context to be used in this call's Do method. Any
4665// pending HTTP request will be aborted if the provided context is
4666// canceled.
4667func (c *ProjectsNotesListCall) Context(ctx context.Context) *ProjectsNotesListCall {
4668	c.ctx_ = ctx
4669	return c
4670}
4671
4672// Header returns an http.Header that can be modified by the caller to
4673// add HTTP headers to the request.
4674func (c *ProjectsNotesListCall) Header() http.Header {
4675	if c.header_ == nil {
4676		c.header_ = make(http.Header)
4677	}
4678	return c.header_
4679}
4680
4681func (c *ProjectsNotesListCall) doRequest(alt string) (*http.Response, error) {
4682	reqHeaders := make(http.Header)
4683	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
4684	for k, v := range c.header_ {
4685		reqHeaders[k] = v
4686	}
4687	reqHeaders.Set("User-Agent", c.s.userAgent())
4688	if c.ifNoneMatch_ != "" {
4689		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
4690	}
4691	var body io.Reader = nil
4692	c.urlParams_.Set("alt", alt)
4693	c.urlParams_.Set("prettyPrint", "false")
4694	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/notes")
4695	urls += "?" + c.urlParams_.Encode()
4696	req, err := http.NewRequest("GET", urls, body)
4697	if err != nil {
4698		return nil, err
4699	}
4700	req.Header = reqHeaders
4701	googleapi.Expand(req.URL, map[string]string{
4702		"parent": c.parent,
4703	})
4704	return gensupport.SendRequest(c.ctx_, c.s.client, req)
4705}
4706
4707// Do executes the "containeranalysis.projects.notes.list" call.
4708// Exactly one of *ListNotesResponse or error will be non-nil. Any
4709// non-2xx status code is an error. Response headers are in either
4710// *ListNotesResponse.ServerResponse.Header or (if a response was
4711// returned at all) in error.(*googleapi.Error).Header. Use
4712// googleapi.IsNotModified to check whether the returned error was
4713// because http.StatusNotModified was returned.
4714func (c *ProjectsNotesListCall) Do(opts ...googleapi.CallOption) (*ListNotesResponse, error) {
4715	gensupport.SetOptions(c.urlParams_, opts...)
4716	res, err := c.doRequest("json")
4717	if res != nil && res.StatusCode == http.StatusNotModified {
4718		if res.Body != nil {
4719			res.Body.Close()
4720		}
4721		return nil, &googleapi.Error{
4722			Code:   res.StatusCode,
4723			Header: res.Header,
4724		}
4725	}
4726	if err != nil {
4727		return nil, err
4728	}
4729	defer googleapi.CloseBody(res)
4730	if err := googleapi.CheckResponse(res); err != nil {
4731		return nil, err
4732	}
4733	ret := &ListNotesResponse{
4734		ServerResponse: googleapi.ServerResponse{
4735			Header:         res.Header,
4736			HTTPStatusCode: res.StatusCode,
4737		},
4738	}
4739	target := &ret
4740	if err := gensupport.DecodeResponse(target, res); err != nil {
4741		return nil, err
4742	}
4743	return ret, nil
4744	// {
4745	//   "description": "Lists notes for the specified project.",
4746	//   "flatPath": "v1beta1/projects/{projectsId}/notes",
4747	//   "httpMethod": "GET",
4748	//   "id": "containeranalysis.projects.notes.list",
4749	//   "parameterOrder": [
4750	//     "parent"
4751	//   ],
4752	//   "parameters": {
4753	//     "filter": {
4754	//       "description": "The filter expression.",
4755	//       "location": "query",
4756	//       "type": "string"
4757	//     },
4758	//     "pageSize": {
4759	//       "description": "Number of notes to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.",
4760	//       "format": "int32",
4761	//       "location": "query",
4762	//       "type": "integer"
4763	//     },
4764	//     "pageToken": {
4765	//       "description": "Token to provide to skip to a particular spot in the list.",
4766	//       "location": "query",
4767	//       "type": "string"
4768	//     },
4769	//     "parent": {
4770	//       "description": "Required. The name of the project to list notes for in the form of `projects/[PROJECT_ID]`.",
4771	//       "location": "path",
4772	//       "pattern": "^projects/[^/]+$",
4773	//       "required": true,
4774	//       "type": "string"
4775	//     }
4776	//   },
4777	//   "path": "v1beta1/{+parent}/notes",
4778	//   "response": {
4779	//     "$ref": "ListNotesResponse"
4780	//   },
4781	//   "scopes": [
4782	//     "https://www.googleapis.com/auth/cloud-platform"
4783	//   ]
4784	// }
4785
4786}
4787
4788// Pages invokes f for each page of results.
4789// A non-nil error returned from f will halt the iteration.
4790// The provided context supersedes any context provided to the Context method.
4791func (c *ProjectsNotesListCall) Pages(ctx context.Context, f func(*ListNotesResponse) error) error {
4792	c.ctx_ = ctx
4793	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
4794	for {
4795		x, err := c.Do()
4796		if err != nil {
4797			return err
4798		}
4799		if err := f(x); err != nil {
4800			return err
4801		}
4802		if x.NextPageToken == "" {
4803			return nil
4804		}
4805		c.PageToken(x.NextPageToken)
4806	}
4807}
4808
4809// method id "containeranalysis.projects.notes.patch":
4810
4811type ProjectsNotesPatchCall struct {
4812	s          *Service
4813	name       string
4814	note       *Note
4815	urlParams_ gensupport.URLParams
4816	ctx_       context.Context
4817	header_    http.Header
4818}
4819
4820// Patch: Updates the specified note.
4821//
4822// - name: The name of the note in the form of
4823//   `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
4824func (r *ProjectsNotesService) Patch(name string, note *Note) *ProjectsNotesPatchCall {
4825	c := &ProjectsNotesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4826	c.name = name
4827	c.note = note
4828	return c
4829}
4830
4831// UpdateMask sets the optional parameter "updateMask": The fields to
4832// update.
4833func (c *ProjectsNotesPatchCall) UpdateMask(updateMask string) *ProjectsNotesPatchCall {
4834	c.urlParams_.Set("updateMask", updateMask)
4835	return c
4836}
4837
4838// Fields allows partial responses to be retrieved. See
4839// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4840// for more information.
4841func (c *ProjectsNotesPatchCall) Fields(s ...googleapi.Field) *ProjectsNotesPatchCall {
4842	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4843	return c
4844}
4845
4846// Context sets the context to be used in this call's Do method. Any
4847// pending HTTP request will be aborted if the provided context is
4848// canceled.
4849func (c *ProjectsNotesPatchCall) Context(ctx context.Context) *ProjectsNotesPatchCall {
4850	c.ctx_ = ctx
4851	return c
4852}
4853
4854// Header returns an http.Header that can be modified by the caller to
4855// add HTTP headers to the request.
4856func (c *ProjectsNotesPatchCall) Header() http.Header {
4857	if c.header_ == nil {
4858		c.header_ = make(http.Header)
4859	}
4860	return c.header_
4861}
4862
4863func (c *ProjectsNotesPatchCall) doRequest(alt string) (*http.Response, error) {
4864	reqHeaders := make(http.Header)
4865	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
4866	for k, v := range c.header_ {
4867		reqHeaders[k] = v
4868	}
4869	reqHeaders.Set("User-Agent", c.s.userAgent())
4870	var body io.Reader = nil
4871	body, err := googleapi.WithoutDataWrapper.JSONReader(c.note)
4872	if err != nil {
4873		return nil, err
4874	}
4875	reqHeaders.Set("Content-Type", "application/json")
4876	c.urlParams_.Set("alt", alt)
4877	c.urlParams_.Set("prettyPrint", "false")
4878	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
4879	urls += "?" + c.urlParams_.Encode()
4880	req, err := http.NewRequest("PATCH", urls, body)
4881	if err != nil {
4882		return nil, err
4883	}
4884	req.Header = reqHeaders
4885	googleapi.Expand(req.URL, map[string]string{
4886		"name": c.name,
4887	})
4888	return gensupport.SendRequest(c.ctx_, c.s.client, req)
4889}
4890
4891// Do executes the "containeranalysis.projects.notes.patch" call.
4892// Exactly one of *Note or error will be non-nil. Any non-2xx status
4893// code is an error. Response headers are in either
4894// *Note.ServerResponse.Header or (if a response was returned at all) in
4895// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
4896// whether the returned error was because http.StatusNotModified was
4897// returned.
4898func (c *ProjectsNotesPatchCall) Do(opts ...googleapi.CallOption) (*Note, error) {
4899	gensupport.SetOptions(c.urlParams_, opts...)
4900	res, err := c.doRequest("json")
4901	if res != nil && res.StatusCode == http.StatusNotModified {
4902		if res.Body != nil {
4903			res.Body.Close()
4904		}
4905		return nil, &googleapi.Error{
4906			Code:   res.StatusCode,
4907			Header: res.Header,
4908		}
4909	}
4910	if err != nil {
4911		return nil, err
4912	}
4913	defer googleapi.CloseBody(res)
4914	if err := googleapi.CheckResponse(res); err != nil {
4915		return nil, err
4916	}
4917	ret := &Note{
4918		ServerResponse: googleapi.ServerResponse{
4919			Header:         res.Header,
4920			HTTPStatusCode: res.StatusCode,
4921		},
4922	}
4923	target := &ret
4924	if err := gensupport.DecodeResponse(target, res); err != nil {
4925		return nil, err
4926	}
4927	return ret, nil
4928	// {
4929	//   "description": "Updates the specified note.",
4930	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}",
4931	//   "httpMethod": "PATCH",
4932	//   "id": "containeranalysis.projects.notes.patch",
4933	//   "parameterOrder": [
4934	//     "name"
4935	//   ],
4936	//   "parameters": {
4937	//     "name": {
4938	//       "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.",
4939	//       "location": "path",
4940	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
4941	//       "required": true,
4942	//       "type": "string"
4943	//     },
4944	//     "updateMask": {
4945	//       "description": "The fields to update.",
4946	//       "format": "google-fieldmask",
4947	//       "location": "query",
4948	//       "type": "string"
4949	//     }
4950	//   },
4951	//   "path": "v1beta1/{+name}",
4952	//   "request": {
4953	//     "$ref": "Note"
4954	//   },
4955	//   "response": {
4956	//     "$ref": "Note"
4957	//   },
4958	//   "scopes": [
4959	//     "https://www.googleapis.com/auth/cloud-platform"
4960	//   ]
4961	// }
4962
4963}
4964
4965// method id "containeranalysis.projects.notes.setIamPolicy":
4966
4967type ProjectsNotesSetIamPolicyCall struct {
4968	s                   *Service
4969	resource            string
4970	setiampolicyrequest *SetIamPolicyRequest
4971	urlParams_          gensupport.URLParams
4972	ctx_                context.Context
4973	header_             http.Header
4974}
4975
4976// SetIamPolicy: Sets the access control policy on the specified note or
4977// occurrence. Requires `containeranalysis.notes.setIamPolicy` or
4978// `containeranalysis.occurrences.setIamPolicy` permission if the
4979// resource is a note or an occurrence, respectively. The resource takes
4980// the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and
4981// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.
4982//
4983// - resource: REQUIRED: The resource for which the policy is being
4984//   specified. See the operation documentation for the appropriate
4985//   value for this field.
4986func (r *ProjectsNotesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsNotesSetIamPolicyCall {
4987	c := &ProjectsNotesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
4988	c.resource = resource
4989	c.setiampolicyrequest = setiampolicyrequest
4990	return c
4991}
4992
4993// Fields allows partial responses to be retrieved. See
4994// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
4995// for more information.
4996func (c *ProjectsNotesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsNotesSetIamPolicyCall {
4997	c.urlParams_.Set("fields", googleapi.CombineFields(s))
4998	return c
4999}
5000
5001// Context sets the context to be used in this call's Do method. Any
5002// pending HTTP request will be aborted if the provided context is
5003// canceled.
5004func (c *ProjectsNotesSetIamPolicyCall) Context(ctx context.Context) *ProjectsNotesSetIamPolicyCall {
5005	c.ctx_ = ctx
5006	return c
5007}
5008
5009// Header returns an http.Header that can be modified by the caller to
5010// add HTTP headers to the request.
5011func (c *ProjectsNotesSetIamPolicyCall) Header() http.Header {
5012	if c.header_ == nil {
5013		c.header_ = make(http.Header)
5014	}
5015	return c.header_
5016}
5017
5018func (c *ProjectsNotesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
5019	reqHeaders := make(http.Header)
5020	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5021	for k, v := range c.header_ {
5022		reqHeaders[k] = v
5023	}
5024	reqHeaders.Set("User-Agent", c.s.userAgent())
5025	var body io.Reader = nil
5026	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
5027	if err != nil {
5028		return nil, err
5029	}
5030	reqHeaders.Set("Content-Type", "application/json")
5031	c.urlParams_.Set("alt", alt)
5032	c.urlParams_.Set("prettyPrint", "false")
5033	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:setIamPolicy")
5034	urls += "?" + c.urlParams_.Encode()
5035	req, err := http.NewRequest("POST", urls, body)
5036	if err != nil {
5037		return nil, err
5038	}
5039	req.Header = reqHeaders
5040	googleapi.Expand(req.URL, map[string]string{
5041		"resource": c.resource,
5042	})
5043	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5044}
5045
5046// Do executes the "containeranalysis.projects.notes.setIamPolicy" call.
5047// Exactly one of *Policy or error will be non-nil. Any non-2xx status
5048// code is an error. Response headers are in either
5049// *Policy.ServerResponse.Header or (if a response was returned at all)
5050// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
5051// check whether the returned error was because http.StatusNotModified
5052// was returned.
5053func (c *ProjectsNotesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
5054	gensupport.SetOptions(c.urlParams_, opts...)
5055	res, err := c.doRequest("json")
5056	if res != nil && res.StatusCode == http.StatusNotModified {
5057		if res.Body != nil {
5058			res.Body.Close()
5059		}
5060		return nil, &googleapi.Error{
5061			Code:   res.StatusCode,
5062			Header: res.Header,
5063		}
5064	}
5065	if err != nil {
5066		return nil, err
5067	}
5068	defer googleapi.CloseBody(res)
5069	if err := googleapi.CheckResponse(res); err != nil {
5070		return nil, err
5071	}
5072	ret := &Policy{
5073		ServerResponse: googleapi.ServerResponse{
5074			Header:         res.Header,
5075			HTTPStatusCode: res.StatusCode,
5076		},
5077	}
5078	target := &ret
5079	if err := gensupport.DecodeResponse(target, res); err != nil {
5080		return nil, err
5081	}
5082	return ret, nil
5083	// {
5084	//   "description": "Sets the access control policy on the specified note or occurrence. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or an occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.",
5085	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}:setIamPolicy",
5086	//   "httpMethod": "POST",
5087	//   "id": "containeranalysis.projects.notes.setIamPolicy",
5088	//   "parameterOrder": [
5089	//     "resource"
5090	//   ],
5091	//   "parameters": {
5092	//     "resource": {
5093	//       "description": "REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.",
5094	//       "location": "path",
5095	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
5096	//       "required": true,
5097	//       "type": "string"
5098	//     }
5099	//   },
5100	//   "path": "v1beta1/{+resource}:setIamPolicy",
5101	//   "request": {
5102	//     "$ref": "SetIamPolicyRequest"
5103	//   },
5104	//   "response": {
5105	//     "$ref": "Policy"
5106	//   },
5107	//   "scopes": [
5108	//     "https://www.googleapis.com/auth/cloud-platform"
5109	//   ]
5110	// }
5111
5112}
5113
5114// method id "containeranalysis.projects.notes.testIamPermissions":
5115
5116type ProjectsNotesTestIamPermissionsCall struct {
5117	s                         *Service
5118	resource                  string
5119	testiampermissionsrequest *TestIamPermissionsRequest
5120	urlParams_                gensupport.URLParams
5121	ctx_                      context.Context
5122	header_                   http.Header
5123}
5124
5125// TestIamPermissions: Returns the permissions that a caller has on the
5126// specified note or occurrence. Requires list permission on the project
5127// (for example, `containeranalysis.notes.list`). The resource takes the
5128// format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and
5129// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.
5130//
5131// - resource: REQUIRED: The resource for which the policy detail is
5132//   being requested. See the operation documentation for the
5133//   appropriate value for this field.
5134func (r *ProjectsNotesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsNotesTestIamPermissionsCall {
5135	c := &ProjectsNotesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
5136	c.resource = resource
5137	c.testiampermissionsrequest = testiampermissionsrequest
5138	return c
5139}
5140
5141// Fields allows partial responses to be retrieved. See
5142// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
5143// for more information.
5144func (c *ProjectsNotesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsNotesTestIamPermissionsCall {
5145	c.urlParams_.Set("fields", googleapi.CombineFields(s))
5146	return c
5147}
5148
5149// Context sets the context to be used in this call's Do method. Any
5150// pending HTTP request will be aborted if the provided context is
5151// canceled.
5152func (c *ProjectsNotesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsNotesTestIamPermissionsCall {
5153	c.ctx_ = ctx
5154	return c
5155}
5156
5157// Header returns an http.Header that can be modified by the caller to
5158// add HTTP headers to the request.
5159func (c *ProjectsNotesTestIamPermissionsCall) Header() http.Header {
5160	if c.header_ == nil {
5161		c.header_ = make(http.Header)
5162	}
5163	return c.header_
5164}
5165
5166func (c *ProjectsNotesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
5167	reqHeaders := make(http.Header)
5168	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5169	for k, v := range c.header_ {
5170		reqHeaders[k] = v
5171	}
5172	reqHeaders.Set("User-Agent", c.s.userAgent())
5173	var body io.Reader = nil
5174	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
5175	if err != nil {
5176		return nil, err
5177	}
5178	reqHeaders.Set("Content-Type", "application/json")
5179	c.urlParams_.Set("alt", alt)
5180	c.urlParams_.Set("prettyPrint", "false")
5181	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:testIamPermissions")
5182	urls += "?" + c.urlParams_.Encode()
5183	req, err := http.NewRequest("POST", urls, body)
5184	if err != nil {
5185		return nil, err
5186	}
5187	req.Header = reqHeaders
5188	googleapi.Expand(req.URL, map[string]string{
5189		"resource": c.resource,
5190	})
5191	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5192}
5193
5194// Do executes the "containeranalysis.projects.notes.testIamPermissions" call.
5195// Exactly one of *TestIamPermissionsResponse or error will be non-nil.
5196// Any non-2xx status code is an error. Response headers are in either
5197// *TestIamPermissionsResponse.ServerResponse.Header or (if a response
5198// was returned at all) in error.(*googleapi.Error).Header. Use
5199// googleapi.IsNotModified to check whether the returned error was
5200// because http.StatusNotModified was returned.
5201func (c *ProjectsNotesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
5202	gensupport.SetOptions(c.urlParams_, opts...)
5203	res, err := c.doRequest("json")
5204	if res != nil && res.StatusCode == http.StatusNotModified {
5205		if res.Body != nil {
5206			res.Body.Close()
5207		}
5208		return nil, &googleapi.Error{
5209			Code:   res.StatusCode,
5210			Header: res.Header,
5211		}
5212	}
5213	if err != nil {
5214		return nil, err
5215	}
5216	defer googleapi.CloseBody(res)
5217	if err := googleapi.CheckResponse(res); err != nil {
5218		return nil, err
5219	}
5220	ret := &TestIamPermissionsResponse{
5221		ServerResponse: googleapi.ServerResponse{
5222			Header:         res.Header,
5223			HTTPStatusCode: res.StatusCode,
5224		},
5225	}
5226	target := &ret
5227	if err := gensupport.DecodeResponse(target, res); err != nil {
5228		return nil, err
5229	}
5230	return ret, nil
5231	// {
5232	//   "description": "Returns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example, `containeranalysis.notes.list`). The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.",
5233	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}:testIamPermissions",
5234	//   "httpMethod": "POST",
5235	//   "id": "containeranalysis.projects.notes.testIamPermissions",
5236	//   "parameterOrder": [
5237	//     "resource"
5238	//   ],
5239	//   "parameters": {
5240	//     "resource": {
5241	//       "description": "REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.",
5242	//       "location": "path",
5243	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
5244	//       "required": true,
5245	//       "type": "string"
5246	//     }
5247	//   },
5248	//   "path": "v1beta1/{+resource}:testIamPermissions",
5249	//   "request": {
5250	//     "$ref": "TestIamPermissionsRequest"
5251	//   },
5252	//   "response": {
5253	//     "$ref": "TestIamPermissionsResponse"
5254	//   },
5255	//   "scopes": [
5256	//     "https://www.googleapis.com/auth/cloud-platform"
5257	//   ]
5258	// }
5259
5260}
5261
5262// method id "containeranalysis.projects.notes.occurrences.list":
5263
5264type ProjectsNotesOccurrencesListCall struct {
5265	s            *Service
5266	name         string
5267	urlParams_   gensupport.URLParams
5268	ifNoneMatch_ string
5269	ctx_         context.Context
5270	header_      http.Header
5271}
5272
5273// List: Lists occurrences referencing the specified note. Provider
5274// projects can use this method to get all occurrences across consumer
5275// projects referencing the specified note.
5276//
5277// - name: The name of the note to list occurrences for in the form of
5278//   `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
5279func (r *ProjectsNotesOccurrencesService) List(name string) *ProjectsNotesOccurrencesListCall {
5280	c := &ProjectsNotesOccurrencesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
5281	c.name = name
5282	return c
5283}
5284
5285// Filter sets the optional parameter "filter": The filter expression.
5286func (c *ProjectsNotesOccurrencesListCall) Filter(filter string) *ProjectsNotesOccurrencesListCall {
5287	c.urlParams_.Set("filter", filter)
5288	return c
5289}
5290
5291// PageSize sets the optional parameter "pageSize": Number of
5292// occurrences to return in the list.
5293func (c *ProjectsNotesOccurrencesListCall) PageSize(pageSize int64) *ProjectsNotesOccurrencesListCall {
5294	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
5295	return c
5296}
5297
5298// PageToken sets the optional parameter "pageToken": Token to provide
5299// to skip to a particular spot in the list.
5300func (c *ProjectsNotesOccurrencesListCall) PageToken(pageToken string) *ProjectsNotesOccurrencesListCall {
5301	c.urlParams_.Set("pageToken", pageToken)
5302	return c
5303}
5304
5305// Fields allows partial responses to be retrieved. See
5306// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
5307// for more information.
5308func (c *ProjectsNotesOccurrencesListCall) Fields(s ...googleapi.Field) *ProjectsNotesOccurrencesListCall {
5309	c.urlParams_.Set("fields", googleapi.CombineFields(s))
5310	return c
5311}
5312
5313// IfNoneMatch sets the optional parameter which makes the operation
5314// fail if the object's ETag matches the given value. This is useful for
5315// getting updates only after the object has changed since the last
5316// request. Use googleapi.IsNotModified to check whether the response
5317// error from Do is the result of In-None-Match.
5318func (c *ProjectsNotesOccurrencesListCall) IfNoneMatch(entityTag string) *ProjectsNotesOccurrencesListCall {
5319	c.ifNoneMatch_ = entityTag
5320	return c
5321}
5322
5323// Context sets the context to be used in this call's Do method. Any
5324// pending HTTP request will be aborted if the provided context is
5325// canceled.
5326func (c *ProjectsNotesOccurrencesListCall) Context(ctx context.Context) *ProjectsNotesOccurrencesListCall {
5327	c.ctx_ = ctx
5328	return c
5329}
5330
5331// Header returns an http.Header that can be modified by the caller to
5332// add HTTP headers to the request.
5333func (c *ProjectsNotesOccurrencesListCall) Header() http.Header {
5334	if c.header_ == nil {
5335		c.header_ = make(http.Header)
5336	}
5337	return c.header_
5338}
5339
5340func (c *ProjectsNotesOccurrencesListCall) doRequest(alt string) (*http.Response, error) {
5341	reqHeaders := make(http.Header)
5342	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5343	for k, v := range c.header_ {
5344		reqHeaders[k] = v
5345	}
5346	reqHeaders.Set("User-Agent", c.s.userAgent())
5347	if c.ifNoneMatch_ != "" {
5348		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
5349	}
5350	var body io.Reader = nil
5351	c.urlParams_.Set("alt", alt)
5352	c.urlParams_.Set("prettyPrint", "false")
5353	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/occurrences")
5354	urls += "?" + c.urlParams_.Encode()
5355	req, err := http.NewRequest("GET", urls, body)
5356	if err != nil {
5357		return nil, err
5358	}
5359	req.Header = reqHeaders
5360	googleapi.Expand(req.URL, map[string]string{
5361		"name": c.name,
5362	})
5363	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5364}
5365
5366// Do executes the "containeranalysis.projects.notes.occurrences.list" call.
5367// Exactly one of *ListNoteOccurrencesResponse or error will be non-nil.
5368// Any non-2xx status code is an error. Response headers are in either
5369// *ListNoteOccurrencesResponse.ServerResponse.Header or (if a response
5370// was returned at all) in error.(*googleapi.Error).Header. Use
5371// googleapi.IsNotModified to check whether the returned error was
5372// because http.StatusNotModified was returned.
5373func (c *ProjectsNotesOccurrencesListCall) Do(opts ...googleapi.CallOption) (*ListNoteOccurrencesResponse, error) {
5374	gensupport.SetOptions(c.urlParams_, opts...)
5375	res, err := c.doRequest("json")
5376	if res != nil && res.StatusCode == http.StatusNotModified {
5377		if res.Body != nil {
5378			res.Body.Close()
5379		}
5380		return nil, &googleapi.Error{
5381			Code:   res.StatusCode,
5382			Header: res.Header,
5383		}
5384	}
5385	if err != nil {
5386		return nil, err
5387	}
5388	defer googleapi.CloseBody(res)
5389	if err := googleapi.CheckResponse(res); err != nil {
5390		return nil, err
5391	}
5392	ret := &ListNoteOccurrencesResponse{
5393		ServerResponse: googleapi.ServerResponse{
5394			Header:         res.Header,
5395			HTTPStatusCode: res.StatusCode,
5396		},
5397	}
5398	target := &ret
5399	if err := gensupport.DecodeResponse(target, res); err != nil {
5400		return nil, err
5401	}
5402	return ret, nil
5403	// {
5404	//   "description": "Lists occurrences referencing the specified note. Provider projects can use this method to get all occurrences across consumer projects referencing the specified note.",
5405	//   "flatPath": "v1beta1/projects/{projectsId}/notes/{notesId}/occurrences",
5406	//   "httpMethod": "GET",
5407	//   "id": "containeranalysis.projects.notes.occurrences.list",
5408	//   "parameterOrder": [
5409	//     "name"
5410	//   ],
5411	//   "parameters": {
5412	//     "filter": {
5413	//       "description": "The filter expression.",
5414	//       "location": "query",
5415	//       "type": "string"
5416	//     },
5417	//     "name": {
5418	//       "description": "Required. The name of the note to list occurrences for in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.",
5419	//       "location": "path",
5420	//       "pattern": "^projects/[^/]+/notes/[^/]+$",
5421	//       "required": true,
5422	//       "type": "string"
5423	//     },
5424	//     "pageSize": {
5425	//       "description": "Number of occurrences to return in the list.",
5426	//       "format": "int32",
5427	//       "location": "query",
5428	//       "type": "integer"
5429	//     },
5430	//     "pageToken": {
5431	//       "description": "Token to provide to skip to a particular spot in the list.",
5432	//       "location": "query",
5433	//       "type": "string"
5434	//     }
5435	//   },
5436	//   "path": "v1beta1/{+name}/occurrences",
5437	//   "response": {
5438	//     "$ref": "ListNoteOccurrencesResponse"
5439	//   },
5440	//   "scopes": [
5441	//     "https://www.googleapis.com/auth/cloud-platform"
5442	//   ]
5443	// }
5444
5445}
5446
5447// Pages invokes f for each page of results.
5448// A non-nil error returned from f will halt the iteration.
5449// The provided context supersedes any context provided to the Context method.
5450func (c *ProjectsNotesOccurrencesListCall) Pages(ctx context.Context, f func(*ListNoteOccurrencesResponse) error) error {
5451	c.ctx_ = ctx
5452	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
5453	for {
5454		x, err := c.Do()
5455		if err != nil {
5456			return err
5457		}
5458		if err := f(x); err != nil {
5459			return err
5460		}
5461		if x.NextPageToken == "" {
5462			return nil
5463		}
5464		c.PageToken(x.NextPageToken)
5465	}
5466}
5467
5468// method id "containeranalysis.projects.occurrences.batchCreate":
5469
5470type ProjectsOccurrencesBatchCreateCall struct {
5471	s                             *Service
5472	parent                        string
5473	batchcreateoccurrencesrequest *BatchCreateOccurrencesRequest
5474	urlParams_                    gensupport.URLParams
5475	ctx_                          context.Context
5476	header_                       http.Header
5477}
5478
5479// BatchCreate: Creates new occurrences in batch.
5480//
5481// - parent: The name of the project in the form of
5482//   `projects/[PROJECT_ID]`, under which the occurrences are to be
5483//   created.
5484func (r *ProjectsOccurrencesService) BatchCreate(parent string, batchcreateoccurrencesrequest *BatchCreateOccurrencesRequest) *ProjectsOccurrencesBatchCreateCall {
5485	c := &ProjectsOccurrencesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
5486	c.parent = parent
5487	c.batchcreateoccurrencesrequest = batchcreateoccurrencesrequest
5488	return c
5489}
5490
5491// Fields allows partial responses to be retrieved. See
5492// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
5493// for more information.
5494func (c *ProjectsOccurrencesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesBatchCreateCall {
5495	c.urlParams_.Set("fields", googleapi.CombineFields(s))
5496	return c
5497}
5498
5499// Context sets the context to be used in this call's Do method. Any
5500// pending HTTP request will be aborted if the provided context is
5501// canceled.
5502func (c *ProjectsOccurrencesBatchCreateCall) Context(ctx context.Context) *ProjectsOccurrencesBatchCreateCall {
5503	c.ctx_ = ctx
5504	return c
5505}
5506
5507// Header returns an http.Header that can be modified by the caller to
5508// add HTTP headers to the request.
5509func (c *ProjectsOccurrencesBatchCreateCall) Header() http.Header {
5510	if c.header_ == nil {
5511		c.header_ = make(http.Header)
5512	}
5513	return c.header_
5514}
5515
5516func (c *ProjectsOccurrencesBatchCreateCall) doRequest(alt string) (*http.Response, error) {
5517	reqHeaders := make(http.Header)
5518	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5519	for k, v := range c.header_ {
5520		reqHeaders[k] = v
5521	}
5522	reqHeaders.Set("User-Agent", c.s.userAgent())
5523	var body io.Reader = nil
5524	body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchcreateoccurrencesrequest)
5525	if err != nil {
5526		return nil, err
5527	}
5528	reqHeaders.Set("Content-Type", "application/json")
5529	c.urlParams_.Set("alt", alt)
5530	c.urlParams_.Set("prettyPrint", "false")
5531	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/occurrences:batchCreate")
5532	urls += "?" + c.urlParams_.Encode()
5533	req, err := http.NewRequest("POST", urls, body)
5534	if err != nil {
5535		return nil, err
5536	}
5537	req.Header = reqHeaders
5538	googleapi.Expand(req.URL, map[string]string{
5539		"parent": c.parent,
5540	})
5541	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5542}
5543
5544// Do executes the "containeranalysis.projects.occurrences.batchCreate" call.
5545// Exactly one of *BatchCreateOccurrencesResponse or error will be
5546// non-nil. Any non-2xx status code is an error. Response headers are in
5547// either *BatchCreateOccurrencesResponse.ServerResponse.Header or (if a
5548// response was returned at all) in error.(*googleapi.Error).Header. Use
5549// googleapi.IsNotModified to check whether the returned error was
5550// because http.StatusNotModified was returned.
5551func (c *ProjectsOccurrencesBatchCreateCall) Do(opts ...googleapi.CallOption) (*BatchCreateOccurrencesResponse, error) {
5552	gensupport.SetOptions(c.urlParams_, opts...)
5553	res, err := c.doRequest("json")
5554	if res != nil && res.StatusCode == http.StatusNotModified {
5555		if res.Body != nil {
5556			res.Body.Close()
5557		}
5558		return nil, &googleapi.Error{
5559			Code:   res.StatusCode,
5560			Header: res.Header,
5561		}
5562	}
5563	if err != nil {
5564		return nil, err
5565	}
5566	defer googleapi.CloseBody(res)
5567	if err := googleapi.CheckResponse(res); err != nil {
5568		return nil, err
5569	}
5570	ret := &BatchCreateOccurrencesResponse{
5571		ServerResponse: googleapi.ServerResponse{
5572			Header:         res.Header,
5573			HTTPStatusCode: res.StatusCode,
5574		},
5575	}
5576	target := &ret
5577	if err := gensupport.DecodeResponse(target, res); err != nil {
5578		return nil, err
5579	}
5580	return ret, nil
5581	// {
5582	//   "description": "Creates new occurrences in batch.",
5583	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences:batchCreate",
5584	//   "httpMethod": "POST",
5585	//   "id": "containeranalysis.projects.occurrences.batchCreate",
5586	//   "parameterOrder": [
5587	//     "parent"
5588	//   ],
5589	//   "parameters": {
5590	//     "parent": {
5591	//       "description": "Required. The name of the project in the form of `projects/[PROJECT_ID]`, under which the occurrences are to be created.",
5592	//       "location": "path",
5593	//       "pattern": "^projects/[^/]+$",
5594	//       "required": true,
5595	//       "type": "string"
5596	//     }
5597	//   },
5598	//   "path": "v1beta1/{+parent}/occurrences:batchCreate",
5599	//   "request": {
5600	//     "$ref": "BatchCreateOccurrencesRequest"
5601	//   },
5602	//   "response": {
5603	//     "$ref": "BatchCreateOccurrencesResponse"
5604	//   },
5605	//   "scopes": [
5606	//     "https://www.googleapis.com/auth/cloud-platform"
5607	//   ]
5608	// }
5609
5610}
5611
5612// method id "containeranalysis.projects.occurrences.create":
5613
5614type ProjectsOccurrencesCreateCall struct {
5615	s          *Service
5616	parent     string
5617	occurrence *Occurrence
5618	urlParams_ gensupport.URLParams
5619	ctx_       context.Context
5620	header_    http.Header
5621}
5622
5623// Create: Creates a new occurrence.
5624//
5625// - parent: The name of the project in the form of
5626//   `projects/[PROJECT_ID]`, under which the occurrence is to be
5627//   created.
5628func (r *ProjectsOccurrencesService) Create(parent string, occurrence *Occurrence) *ProjectsOccurrencesCreateCall {
5629	c := &ProjectsOccurrencesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
5630	c.parent = parent
5631	c.occurrence = occurrence
5632	return c
5633}
5634
5635// Fields allows partial responses to be retrieved. See
5636// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
5637// for more information.
5638func (c *ProjectsOccurrencesCreateCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesCreateCall {
5639	c.urlParams_.Set("fields", googleapi.CombineFields(s))
5640	return c
5641}
5642
5643// Context sets the context to be used in this call's Do method. Any
5644// pending HTTP request will be aborted if the provided context is
5645// canceled.
5646func (c *ProjectsOccurrencesCreateCall) Context(ctx context.Context) *ProjectsOccurrencesCreateCall {
5647	c.ctx_ = ctx
5648	return c
5649}
5650
5651// Header returns an http.Header that can be modified by the caller to
5652// add HTTP headers to the request.
5653func (c *ProjectsOccurrencesCreateCall) Header() http.Header {
5654	if c.header_ == nil {
5655		c.header_ = make(http.Header)
5656	}
5657	return c.header_
5658}
5659
5660func (c *ProjectsOccurrencesCreateCall) doRequest(alt string) (*http.Response, error) {
5661	reqHeaders := make(http.Header)
5662	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5663	for k, v := range c.header_ {
5664		reqHeaders[k] = v
5665	}
5666	reqHeaders.Set("User-Agent", c.s.userAgent())
5667	var body io.Reader = nil
5668	body, err := googleapi.WithoutDataWrapper.JSONReader(c.occurrence)
5669	if err != nil {
5670		return nil, err
5671	}
5672	reqHeaders.Set("Content-Type", "application/json")
5673	c.urlParams_.Set("alt", alt)
5674	c.urlParams_.Set("prettyPrint", "false")
5675	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/occurrences")
5676	urls += "?" + c.urlParams_.Encode()
5677	req, err := http.NewRequest("POST", urls, body)
5678	if err != nil {
5679		return nil, err
5680	}
5681	req.Header = reqHeaders
5682	googleapi.Expand(req.URL, map[string]string{
5683		"parent": c.parent,
5684	})
5685	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5686}
5687
5688// Do executes the "containeranalysis.projects.occurrences.create" call.
5689// Exactly one of *Occurrence or error will be non-nil. Any non-2xx
5690// status code is an error. Response headers are in either
5691// *Occurrence.ServerResponse.Header or (if a response was returned at
5692// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
5693// to check whether the returned error was because
5694// http.StatusNotModified was returned.
5695func (c *ProjectsOccurrencesCreateCall) Do(opts ...googleapi.CallOption) (*Occurrence, error) {
5696	gensupport.SetOptions(c.urlParams_, opts...)
5697	res, err := c.doRequest("json")
5698	if res != nil && res.StatusCode == http.StatusNotModified {
5699		if res.Body != nil {
5700			res.Body.Close()
5701		}
5702		return nil, &googleapi.Error{
5703			Code:   res.StatusCode,
5704			Header: res.Header,
5705		}
5706	}
5707	if err != nil {
5708		return nil, err
5709	}
5710	defer googleapi.CloseBody(res)
5711	if err := googleapi.CheckResponse(res); err != nil {
5712		return nil, err
5713	}
5714	ret := &Occurrence{
5715		ServerResponse: googleapi.ServerResponse{
5716			Header:         res.Header,
5717			HTTPStatusCode: res.StatusCode,
5718		},
5719	}
5720	target := &ret
5721	if err := gensupport.DecodeResponse(target, res); err != nil {
5722		return nil, err
5723	}
5724	return ret, nil
5725	// {
5726	//   "description": "Creates a new occurrence.",
5727	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences",
5728	//   "httpMethod": "POST",
5729	//   "id": "containeranalysis.projects.occurrences.create",
5730	//   "parameterOrder": [
5731	//     "parent"
5732	//   ],
5733	//   "parameters": {
5734	//     "parent": {
5735	//       "description": "Required. The name of the project in the form of `projects/[PROJECT_ID]`, under which the occurrence is to be created.",
5736	//       "location": "path",
5737	//       "pattern": "^projects/[^/]+$",
5738	//       "required": true,
5739	//       "type": "string"
5740	//     }
5741	//   },
5742	//   "path": "v1beta1/{+parent}/occurrences",
5743	//   "request": {
5744	//     "$ref": "Occurrence"
5745	//   },
5746	//   "response": {
5747	//     "$ref": "Occurrence"
5748	//   },
5749	//   "scopes": [
5750	//     "https://www.googleapis.com/auth/cloud-platform"
5751	//   ]
5752	// }
5753
5754}
5755
5756// method id "containeranalysis.projects.occurrences.delete":
5757
5758type ProjectsOccurrencesDeleteCall struct {
5759	s          *Service
5760	name       string
5761	urlParams_ gensupport.URLParams
5762	ctx_       context.Context
5763	header_    http.Header
5764}
5765
5766// Delete: Deletes the specified occurrence. For example, use this
5767// method to delete an occurrence when the occurrence is no longer
5768// applicable for the given resource.
5769//
5770// - name: The name of the occurrence in the form of
5771//   `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
5772func (r *ProjectsOccurrencesService) Delete(name string) *ProjectsOccurrencesDeleteCall {
5773	c := &ProjectsOccurrencesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
5774	c.name = name
5775	return c
5776}
5777
5778// Fields allows partial responses to be retrieved. See
5779// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
5780// for more information.
5781func (c *ProjectsOccurrencesDeleteCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesDeleteCall {
5782	c.urlParams_.Set("fields", googleapi.CombineFields(s))
5783	return c
5784}
5785
5786// Context sets the context to be used in this call's Do method. Any
5787// pending HTTP request will be aborted if the provided context is
5788// canceled.
5789func (c *ProjectsOccurrencesDeleteCall) Context(ctx context.Context) *ProjectsOccurrencesDeleteCall {
5790	c.ctx_ = ctx
5791	return c
5792}
5793
5794// Header returns an http.Header that can be modified by the caller to
5795// add HTTP headers to the request.
5796func (c *ProjectsOccurrencesDeleteCall) Header() http.Header {
5797	if c.header_ == nil {
5798		c.header_ = make(http.Header)
5799	}
5800	return c.header_
5801}
5802
5803func (c *ProjectsOccurrencesDeleteCall) doRequest(alt string) (*http.Response, error) {
5804	reqHeaders := make(http.Header)
5805	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5806	for k, v := range c.header_ {
5807		reqHeaders[k] = v
5808	}
5809	reqHeaders.Set("User-Agent", c.s.userAgent())
5810	var body io.Reader = nil
5811	c.urlParams_.Set("alt", alt)
5812	c.urlParams_.Set("prettyPrint", "false")
5813	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
5814	urls += "?" + c.urlParams_.Encode()
5815	req, err := http.NewRequest("DELETE", urls, body)
5816	if err != nil {
5817		return nil, err
5818	}
5819	req.Header = reqHeaders
5820	googleapi.Expand(req.URL, map[string]string{
5821		"name": c.name,
5822	})
5823	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5824}
5825
5826// Do executes the "containeranalysis.projects.occurrences.delete" call.
5827// Exactly one of *Empty or error will be non-nil. Any non-2xx status
5828// code is an error. Response headers are in either
5829// *Empty.ServerResponse.Header or (if a response was returned at all)
5830// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
5831// check whether the returned error was because http.StatusNotModified
5832// was returned.
5833func (c *ProjectsOccurrencesDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
5834	gensupport.SetOptions(c.urlParams_, opts...)
5835	res, err := c.doRequest("json")
5836	if res != nil && res.StatusCode == http.StatusNotModified {
5837		if res.Body != nil {
5838			res.Body.Close()
5839		}
5840		return nil, &googleapi.Error{
5841			Code:   res.StatusCode,
5842			Header: res.Header,
5843		}
5844	}
5845	if err != nil {
5846		return nil, err
5847	}
5848	defer googleapi.CloseBody(res)
5849	if err := googleapi.CheckResponse(res); err != nil {
5850		return nil, err
5851	}
5852	ret := &Empty{
5853		ServerResponse: googleapi.ServerResponse{
5854			Header:         res.Header,
5855			HTTPStatusCode: res.StatusCode,
5856		},
5857	}
5858	target := &ret
5859	if err := gensupport.DecodeResponse(target, res); err != nil {
5860		return nil, err
5861	}
5862	return ret, nil
5863	// {
5864	//   "description": "Deletes the specified occurrence. For example, use this method to delete an occurrence when the occurrence is no longer applicable for the given resource.",
5865	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}",
5866	//   "httpMethod": "DELETE",
5867	//   "id": "containeranalysis.projects.occurrences.delete",
5868	//   "parameterOrder": [
5869	//     "name"
5870	//   ],
5871	//   "parameters": {
5872	//     "name": {
5873	//       "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.",
5874	//       "location": "path",
5875	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
5876	//       "required": true,
5877	//       "type": "string"
5878	//     }
5879	//   },
5880	//   "path": "v1beta1/{+name}",
5881	//   "response": {
5882	//     "$ref": "Empty"
5883	//   },
5884	//   "scopes": [
5885	//     "https://www.googleapis.com/auth/cloud-platform"
5886	//   ]
5887	// }
5888
5889}
5890
5891// method id "containeranalysis.projects.occurrences.get":
5892
5893type ProjectsOccurrencesGetCall struct {
5894	s            *Service
5895	name         string
5896	urlParams_   gensupport.URLParams
5897	ifNoneMatch_ string
5898	ctx_         context.Context
5899	header_      http.Header
5900}
5901
5902// Get: Gets the specified occurrence.
5903//
5904// - name: The name of the occurrence in the form of
5905//   `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
5906func (r *ProjectsOccurrencesService) Get(name string) *ProjectsOccurrencesGetCall {
5907	c := &ProjectsOccurrencesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
5908	c.name = name
5909	return c
5910}
5911
5912// Fields allows partial responses to be retrieved. See
5913// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
5914// for more information.
5915func (c *ProjectsOccurrencesGetCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesGetCall {
5916	c.urlParams_.Set("fields", googleapi.CombineFields(s))
5917	return c
5918}
5919
5920// IfNoneMatch sets the optional parameter which makes the operation
5921// fail if the object's ETag matches the given value. This is useful for
5922// getting updates only after the object has changed since the last
5923// request. Use googleapi.IsNotModified to check whether the response
5924// error from Do is the result of In-None-Match.
5925func (c *ProjectsOccurrencesGetCall) IfNoneMatch(entityTag string) *ProjectsOccurrencesGetCall {
5926	c.ifNoneMatch_ = entityTag
5927	return c
5928}
5929
5930// Context sets the context to be used in this call's Do method. Any
5931// pending HTTP request will be aborted if the provided context is
5932// canceled.
5933func (c *ProjectsOccurrencesGetCall) Context(ctx context.Context) *ProjectsOccurrencesGetCall {
5934	c.ctx_ = ctx
5935	return c
5936}
5937
5938// Header returns an http.Header that can be modified by the caller to
5939// add HTTP headers to the request.
5940func (c *ProjectsOccurrencesGetCall) Header() http.Header {
5941	if c.header_ == nil {
5942		c.header_ = make(http.Header)
5943	}
5944	return c.header_
5945}
5946
5947func (c *ProjectsOccurrencesGetCall) doRequest(alt string) (*http.Response, error) {
5948	reqHeaders := make(http.Header)
5949	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
5950	for k, v := range c.header_ {
5951		reqHeaders[k] = v
5952	}
5953	reqHeaders.Set("User-Agent", c.s.userAgent())
5954	if c.ifNoneMatch_ != "" {
5955		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
5956	}
5957	var body io.Reader = nil
5958	c.urlParams_.Set("alt", alt)
5959	c.urlParams_.Set("prettyPrint", "false")
5960	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
5961	urls += "?" + c.urlParams_.Encode()
5962	req, err := http.NewRequest("GET", urls, body)
5963	if err != nil {
5964		return nil, err
5965	}
5966	req.Header = reqHeaders
5967	googleapi.Expand(req.URL, map[string]string{
5968		"name": c.name,
5969	})
5970	return gensupport.SendRequest(c.ctx_, c.s.client, req)
5971}
5972
5973// Do executes the "containeranalysis.projects.occurrences.get" call.
5974// Exactly one of *Occurrence or error will be non-nil. Any non-2xx
5975// status code is an error. Response headers are in either
5976// *Occurrence.ServerResponse.Header or (if a response was returned at
5977// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
5978// to check whether the returned error was because
5979// http.StatusNotModified was returned.
5980func (c *ProjectsOccurrencesGetCall) Do(opts ...googleapi.CallOption) (*Occurrence, error) {
5981	gensupport.SetOptions(c.urlParams_, opts...)
5982	res, err := c.doRequest("json")
5983	if res != nil && res.StatusCode == http.StatusNotModified {
5984		if res.Body != nil {
5985			res.Body.Close()
5986		}
5987		return nil, &googleapi.Error{
5988			Code:   res.StatusCode,
5989			Header: res.Header,
5990		}
5991	}
5992	if err != nil {
5993		return nil, err
5994	}
5995	defer googleapi.CloseBody(res)
5996	if err := googleapi.CheckResponse(res); err != nil {
5997		return nil, err
5998	}
5999	ret := &Occurrence{
6000		ServerResponse: googleapi.ServerResponse{
6001			Header:         res.Header,
6002			HTTPStatusCode: res.StatusCode,
6003		},
6004	}
6005	target := &ret
6006	if err := gensupport.DecodeResponse(target, res); err != nil {
6007		return nil, err
6008	}
6009	return ret, nil
6010	// {
6011	//   "description": "Gets the specified occurrence.",
6012	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}",
6013	//   "httpMethod": "GET",
6014	//   "id": "containeranalysis.projects.occurrences.get",
6015	//   "parameterOrder": [
6016	//     "name"
6017	//   ],
6018	//   "parameters": {
6019	//     "name": {
6020	//       "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.",
6021	//       "location": "path",
6022	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
6023	//       "required": true,
6024	//       "type": "string"
6025	//     }
6026	//   },
6027	//   "path": "v1beta1/{+name}",
6028	//   "response": {
6029	//     "$ref": "Occurrence"
6030	//   },
6031	//   "scopes": [
6032	//     "https://www.googleapis.com/auth/cloud-platform"
6033	//   ]
6034	// }
6035
6036}
6037
6038// method id "containeranalysis.projects.occurrences.getIamPolicy":
6039
6040type ProjectsOccurrencesGetIamPolicyCall struct {
6041	s                   *Service
6042	resource            string
6043	getiampolicyrequest *GetIamPolicyRequest
6044	urlParams_          gensupport.URLParams
6045	ctx_                context.Context
6046	header_             http.Header
6047}
6048
6049// GetIamPolicy: Gets the access control policy for a note or an
6050// occurrence resource. Requires `containeranalysis.notes.setIamPolicy`
6051// or `containeranalysis.occurrences.setIamPolicy` permission if the
6052// resource is a note or occurrence, respectively. The resource takes
6053// the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and
6054// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.
6055//
6056// - resource: REQUIRED: The resource for which the policy is being
6057//   requested. See the operation documentation for the appropriate
6058//   value for this field.
6059func (r *ProjectsOccurrencesService) GetIamPolicy(resource string, getiampolicyrequest *GetIamPolicyRequest) *ProjectsOccurrencesGetIamPolicyCall {
6060	c := &ProjectsOccurrencesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
6061	c.resource = resource
6062	c.getiampolicyrequest = getiampolicyrequest
6063	return c
6064}
6065
6066// Fields allows partial responses to be retrieved. See
6067// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
6068// for more information.
6069func (c *ProjectsOccurrencesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesGetIamPolicyCall {
6070	c.urlParams_.Set("fields", googleapi.CombineFields(s))
6071	return c
6072}
6073
6074// Context sets the context to be used in this call's Do method. Any
6075// pending HTTP request will be aborted if the provided context is
6076// canceled.
6077func (c *ProjectsOccurrencesGetIamPolicyCall) Context(ctx context.Context) *ProjectsOccurrencesGetIamPolicyCall {
6078	c.ctx_ = ctx
6079	return c
6080}
6081
6082// Header returns an http.Header that can be modified by the caller to
6083// add HTTP headers to the request.
6084func (c *ProjectsOccurrencesGetIamPolicyCall) Header() http.Header {
6085	if c.header_ == nil {
6086		c.header_ = make(http.Header)
6087	}
6088	return c.header_
6089}
6090
6091func (c *ProjectsOccurrencesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
6092	reqHeaders := make(http.Header)
6093	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
6094	for k, v := range c.header_ {
6095		reqHeaders[k] = v
6096	}
6097	reqHeaders.Set("User-Agent", c.s.userAgent())
6098	var body io.Reader = nil
6099	body, err := googleapi.WithoutDataWrapper.JSONReader(c.getiampolicyrequest)
6100	if err != nil {
6101		return nil, err
6102	}
6103	reqHeaders.Set("Content-Type", "application/json")
6104	c.urlParams_.Set("alt", alt)
6105	c.urlParams_.Set("prettyPrint", "false")
6106	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:getIamPolicy")
6107	urls += "?" + c.urlParams_.Encode()
6108	req, err := http.NewRequest("POST", urls, body)
6109	if err != nil {
6110		return nil, err
6111	}
6112	req.Header = reqHeaders
6113	googleapi.Expand(req.URL, map[string]string{
6114		"resource": c.resource,
6115	})
6116	return gensupport.SendRequest(c.ctx_, c.s.client, req)
6117}
6118
6119// Do executes the "containeranalysis.projects.occurrences.getIamPolicy" call.
6120// Exactly one of *Policy or error will be non-nil. Any non-2xx status
6121// code is an error. Response headers are in either
6122// *Policy.ServerResponse.Header or (if a response was returned at all)
6123// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
6124// check whether the returned error was because http.StatusNotModified
6125// was returned.
6126func (c *ProjectsOccurrencesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
6127	gensupport.SetOptions(c.urlParams_, opts...)
6128	res, err := c.doRequest("json")
6129	if res != nil && res.StatusCode == http.StatusNotModified {
6130		if res.Body != nil {
6131			res.Body.Close()
6132		}
6133		return nil, &googleapi.Error{
6134			Code:   res.StatusCode,
6135			Header: res.Header,
6136		}
6137	}
6138	if err != nil {
6139		return nil, err
6140	}
6141	defer googleapi.CloseBody(res)
6142	if err := googleapi.CheckResponse(res); err != nil {
6143		return nil, err
6144	}
6145	ret := &Policy{
6146		ServerResponse: googleapi.ServerResponse{
6147			Header:         res.Header,
6148			HTTPStatusCode: res.StatusCode,
6149		},
6150	}
6151	target := &ret
6152	if err := gensupport.DecodeResponse(target, res); err != nil {
6153		return nil, err
6154	}
6155	return ret, nil
6156	// {
6157	//   "description": "Gets the access control policy for a note or an occurrence resource. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.",
6158	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}:getIamPolicy",
6159	//   "httpMethod": "POST",
6160	//   "id": "containeranalysis.projects.occurrences.getIamPolicy",
6161	//   "parameterOrder": [
6162	//     "resource"
6163	//   ],
6164	//   "parameters": {
6165	//     "resource": {
6166	//       "description": "REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.",
6167	//       "location": "path",
6168	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
6169	//       "required": true,
6170	//       "type": "string"
6171	//     }
6172	//   },
6173	//   "path": "v1beta1/{+resource}:getIamPolicy",
6174	//   "request": {
6175	//     "$ref": "GetIamPolicyRequest"
6176	//   },
6177	//   "response": {
6178	//     "$ref": "Policy"
6179	//   },
6180	//   "scopes": [
6181	//     "https://www.googleapis.com/auth/cloud-platform"
6182	//   ]
6183	// }
6184
6185}
6186
6187// method id "containeranalysis.projects.occurrences.getNotes":
6188
6189type ProjectsOccurrencesGetNotesCall struct {
6190	s            *Service
6191	name         string
6192	urlParams_   gensupport.URLParams
6193	ifNoneMatch_ string
6194	ctx_         context.Context
6195	header_      http.Header
6196}
6197
6198// GetNotes: Gets the note attached to the specified occurrence.
6199// Consumer projects can use this method to get a note that belongs to a
6200// provider project.
6201//
6202// - name: The name of the occurrence in the form of
6203//   `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
6204func (r *ProjectsOccurrencesService) GetNotes(name string) *ProjectsOccurrencesGetNotesCall {
6205	c := &ProjectsOccurrencesGetNotesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
6206	c.name = name
6207	return c
6208}
6209
6210// Fields allows partial responses to be retrieved. See
6211// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
6212// for more information.
6213func (c *ProjectsOccurrencesGetNotesCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesGetNotesCall {
6214	c.urlParams_.Set("fields", googleapi.CombineFields(s))
6215	return c
6216}
6217
6218// IfNoneMatch sets the optional parameter which makes the operation
6219// fail if the object's ETag matches the given value. This is useful for
6220// getting updates only after the object has changed since the last
6221// request. Use googleapi.IsNotModified to check whether the response
6222// error from Do is the result of In-None-Match.
6223func (c *ProjectsOccurrencesGetNotesCall) IfNoneMatch(entityTag string) *ProjectsOccurrencesGetNotesCall {
6224	c.ifNoneMatch_ = entityTag
6225	return c
6226}
6227
6228// Context sets the context to be used in this call's Do method. Any
6229// pending HTTP request will be aborted if the provided context is
6230// canceled.
6231func (c *ProjectsOccurrencesGetNotesCall) Context(ctx context.Context) *ProjectsOccurrencesGetNotesCall {
6232	c.ctx_ = ctx
6233	return c
6234}
6235
6236// Header returns an http.Header that can be modified by the caller to
6237// add HTTP headers to the request.
6238func (c *ProjectsOccurrencesGetNotesCall) Header() http.Header {
6239	if c.header_ == nil {
6240		c.header_ = make(http.Header)
6241	}
6242	return c.header_
6243}
6244
6245func (c *ProjectsOccurrencesGetNotesCall) doRequest(alt string) (*http.Response, error) {
6246	reqHeaders := make(http.Header)
6247	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
6248	for k, v := range c.header_ {
6249		reqHeaders[k] = v
6250	}
6251	reqHeaders.Set("User-Agent", c.s.userAgent())
6252	if c.ifNoneMatch_ != "" {
6253		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
6254	}
6255	var body io.Reader = nil
6256	c.urlParams_.Set("alt", alt)
6257	c.urlParams_.Set("prettyPrint", "false")
6258	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/notes")
6259	urls += "?" + c.urlParams_.Encode()
6260	req, err := http.NewRequest("GET", urls, body)
6261	if err != nil {
6262		return nil, err
6263	}
6264	req.Header = reqHeaders
6265	googleapi.Expand(req.URL, map[string]string{
6266		"name": c.name,
6267	})
6268	return gensupport.SendRequest(c.ctx_, c.s.client, req)
6269}
6270
6271// Do executes the "containeranalysis.projects.occurrences.getNotes" call.
6272// Exactly one of *Note or error will be non-nil. Any non-2xx status
6273// code is an error. Response headers are in either
6274// *Note.ServerResponse.Header or (if a response was returned at all) in
6275// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
6276// whether the returned error was because http.StatusNotModified was
6277// returned.
6278func (c *ProjectsOccurrencesGetNotesCall) Do(opts ...googleapi.CallOption) (*Note, error) {
6279	gensupport.SetOptions(c.urlParams_, opts...)
6280	res, err := c.doRequest("json")
6281	if res != nil && res.StatusCode == http.StatusNotModified {
6282		if res.Body != nil {
6283			res.Body.Close()
6284		}
6285		return nil, &googleapi.Error{
6286			Code:   res.StatusCode,
6287			Header: res.Header,
6288		}
6289	}
6290	if err != nil {
6291		return nil, err
6292	}
6293	defer googleapi.CloseBody(res)
6294	if err := googleapi.CheckResponse(res); err != nil {
6295		return nil, err
6296	}
6297	ret := &Note{
6298		ServerResponse: googleapi.ServerResponse{
6299			Header:         res.Header,
6300			HTTPStatusCode: res.StatusCode,
6301		},
6302	}
6303	target := &ret
6304	if err := gensupport.DecodeResponse(target, res); err != nil {
6305		return nil, err
6306	}
6307	return ret, nil
6308	// {
6309	//   "description": "Gets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.",
6310	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}/notes",
6311	//   "httpMethod": "GET",
6312	//   "id": "containeranalysis.projects.occurrences.getNotes",
6313	//   "parameterOrder": [
6314	//     "name"
6315	//   ],
6316	//   "parameters": {
6317	//     "name": {
6318	//       "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.",
6319	//       "location": "path",
6320	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
6321	//       "required": true,
6322	//       "type": "string"
6323	//     }
6324	//   },
6325	//   "path": "v1beta1/{+name}/notes",
6326	//   "response": {
6327	//     "$ref": "Note"
6328	//   },
6329	//   "scopes": [
6330	//     "https://www.googleapis.com/auth/cloud-platform"
6331	//   ]
6332	// }
6333
6334}
6335
6336// method id "containeranalysis.projects.occurrences.getVulnerabilitySummary":
6337
6338type ProjectsOccurrencesGetVulnerabilitySummaryCall struct {
6339	s            *Service
6340	parent       string
6341	urlParams_   gensupport.URLParams
6342	ifNoneMatch_ string
6343	ctx_         context.Context
6344	header_      http.Header
6345}
6346
6347// GetVulnerabilitySummary: Gets a summary of the number and severity of
6348// occurrences.
6349//
6350// - parent: The name of the project to get a vulnerability summary for
6351//   in the form of `projects/[PROJECT_ID]`.
6352func (r *ProjectsOccurrencesService) GetVulnerabilitySummary(parent string) *ProjectsOccurrencesGetVulnerabilitySummaryCall {
6353	c := &ProjectsOccurrencesGetVulnerabilitySummaryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
6354	c.parent = parent
6355	return c
6356}
6357
6358// Filter sets the optional parameter "filter": The filter expression.
6359func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) Filter(filter string) *ProjectsOccurrencesGetVulnerabilitySummaryCall {
6360	c.urlParams_.Set("filter", filter)
6361	return c
6362}
6363
6364// Fields allows partial responses to be retrieved. See
6365// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
6366// for more information.
6367func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesGetVulnerabilitySummaryCall {
6368	c.urlParams_.Set("fields", googleapi.CombineFields(s))
6369	return c
6370}
6371
6372// IfNoneMatch sets the optional parameter which makes the operation
6373// fail if the object's ETag matches the given value. This is useful for
6374// getting updates only after the object has changed since the last
6375// request. Use googleapi.IsNotModified to check whether the response
6376// error from Do is the result of In-None-Match.
6377func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) IfNoneMatch(entityTag string) *ProjectsOccurrencesGetVulnerabilitySummaryCall {
6378	c.ifNoneMatch_ = entityTag
6379	return c
6380}
6381
6382// Context sets the context to be used in this call's Do method. Any
6383// pending HTTP request will be aborted if the provided context is
6384// canceled.
6385func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) Context(ctx context.Context) *ProjectsOccurrencesGetVulnerabilitySummaryCall {
6386	c.ctx_ = ctx
6387	return c
6388}
6389
6390// Header returns an http.Header that can be modified by the caller to
6391// add HTTP headers to the request.
6392func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) Header() http.Header {
6393	if c.header_ == nil {
6394		c.header_ = make(http.Header)
6395	}
6396	return c.header_
6397}
6398
6399func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) doRequest(alt string) (*http.Response, error) {
6400	reqHeaders := make(http.Header)
6401	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
6402	for k, v := range c.header_ {
6403		reqHeaders[k] = v
6404	}
6405	reqHeaders.Set("User-Agent", c.s.userAgent())
6406	if c.ifNoneMatch_ != "" {
6407		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
6408	}
6409	var body io.Reader = nil
6410	c.urlParams_.Set("alt", alt)
6411	c.urlParams_.Set("prettyPrint", "false")
6412	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/occurrences:vulnerabilitySummary")
6413	urls += "?" + c.urlParams_.Encode()
6414	req, err := http.NewRequest("GET", urls, body)
6415	if err != nil {
6416		return nil, err
6417	}
6418	req.Header = reqHeaders
6419	googleapi.Expand(req.URL, map[string]string{
6420		"parent": c.parent,
6421	})
6422	return gensupport.SendRequest(c.ctx_, c.s.client, req)
6423}
6424
6425// Do executes the "containeranalysis.projects.occurrences.getVulnerabilitySummary" call.
6426// Exactly one of *VulnerabilityOccurrencesSummary or error will be
6427// non-nil. Any non-2xx status code is an error. Response headers are in
6428// either *VulnerabilityOccurrencesSummary.ServerResponse.Header or (if
6429// a response was returned at all) in error.(*googleapi.Error).Header.
6430// Use googleapi.IsNotModified to check whether the returned error was
6431// because http.StatusNotModified was returned.
6432func (c *ProjectsOccurrencesGetVulnerabilitySummaryCall) Do(opts ...googleapi.CallOption) (*VulnerabilityOccurrencesSummary, error) {
6433	gensupport.SetOptions(c.urlParams_, opts...)
6434	res, err := c.doRequest("json")
6435	if res != nil && res.StatusCode == http.StatusNotModified {
6436		if res.Body != nil {
6437			res.Body.Close()
6438		}
6439		return nil, &googleapi.Error{
6440			Code:   res.StatusCode,
6441			Header: res.Header,
6442		}
6443	}
6444	if err != nil {
6445		return nil, err
6446	}
6447	defer googleapi.CloseBody(res)
6448	if err := googleapi.CheckResponse(res); err != nil {
6449		return nil, err
6450	}
6451	ret := &VulnerabilityOccurrencesSummary{
6452		ServerResponse: googleapi.ServerResponse{
6453			Header:         res.Header,
6454			HTTPStatusCode: res.StatusCode,
6455		},
6456	}
6457	target := &ret
6458	if err := gensupport.DecodeResponse(target, res); err != nil {
6459		return nil, err
6460	}
6461	return ret, nil
6462	// {
6463	//   "description": "Gets a summary of the number and severity of occurrences.",
6464	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences:vulnerabilitySummary",
6465	//   "httpMethod": "GET",
6466	//   "id": "containeranalysis.projects.occurrences.getVulnerabilitySummary",
6467	//   "parameterOrder": [
6468	//     "parent"
6469	//   ],
6470	//   "parameters": {
6471	//     "filter": {
6472	//       "description": "The filter expression.",
6473	//       "location": "query",
6474	//       "type": "string"
6475	//     },
6476	//     "parent": {
6477	//       "description": "Required. The name of the project to get a vulnerability summary for in the form of `projects/[PROJECT_ID]`.",
6478	//       "location": "path",
6479	//       "pattern": "^projects/[^/]+$",
6480	//       "required": true,
6481	//       "type": "string"
6482	//     }
6483	//   },
6484	//   "path": "v1beta1/{+parent}/occurrences:vulnerabilitySummary",
6485	//   "response": {
6486	//     "$ref": "VulnerabilityOccurrencesSummary"
6487	//   },
6488	//   "scopes": [
6489	//     "https://www.googleapis.com/auth/cloud-platform"
6490	//   ]
6491	// }
6492
6493}
6494
6495// method id "containeranalysis.projects.occurrences.list":
6496
6497type ProjectsOccurrencesListCall struct {
6498	s            *Service
6499	parent       string
6500	urlParams_   gensupport.URLParams
6501	ifNoneMatch_ string
6502	ctx_         context.Context
6503	header_      http.Header
6504}
6505
6506// List: Lists occurrences for the specified project.
6507//
6508// - parent: The name of the project to list occurrences for in the form
6509//   of `projects/[PROJECT_ID]`.
6510func (r *ProjectsOccurrencesService) List(parent string) *ProjectsOccurrencesListCall {
6511	c := &ProjectsOccurrencesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
6512	c.parent = parent
6513	return c
6514}
6515
6516// Filter sets the optional parameter "filter": The filter expression.
6517func (c *ProjectsOccurrencesListCall) Filter(filter string) *ProjectsOccurrencesListCall {
6518	c.urlParams_.Set("filter", filter)
6519	return c
6520}
6521
6522// PageSize sets the optional parameter "pageSize": Number of
6523// occurrences to return in the list. Must be positive. Max allowed page
6524// size is 1000. If not specified, page size defaults to 20.
6525func (c *ProjectsOccurrencesListCall) PageSize(pageSize int64) *ProjectsOccurrencesListCall {
6526	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
6527	return c
6528}
6529
6530// PageToken sets the optional parameter "pageToken": Token to provide
6531// to skip to a particular spot in the list.
6532func (c *ProjectsOccurrencesListCall) PageToken(pageToken string) *ProjectsOccurrencesListCall {
6533	c.urlParams_.Set("pageToken", pageToken)
6534	return c
6535}
6536
6537// Fields allows partial responses to be retrieved. See
6538// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
6539// for more information.
6540func (c *ProjectsOccurrencesListCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesListCall {
6541	c.urlParams_.Set("fields", googleapi.CombineFields(s))
6542	return c
6543}
6544
6545// IfNoneMatch sets the optional parameter which makes the operation
6546// fail if the object's ETag matches the given value. This is useful for
6547// getting updates only after the object has changed since the last
6548// request. Use googleapi.IsNotModified to check whether the response
6549// error from Do is the result of In-None-Match.
6550func (c *ProjectsOccurrencesListCall) IfNoneMatch(entityTag string) *ProjectsOccurrencesListCall {
6551	c.ifNoneMatch_ = entityTag
6552	return c
6553}
6554
6555// Context sets the context to be used in this call's Do method. Any
6556// pending HTTP request will be aborted if the provided context is
6557// canceled.
6558func (c *ProjectsOccurrencesListCall) Context(ctx context.Context) *ProjectsOccurrencesListCall {
6559	c.ctx_ = ctx
6560	return c
6561}
6562
6563// Header returns an http.Header that can be modified by the caller to
6564// add HTTP headers to the request.
6565func (c *ProjectsOccurrencesListCall) Header() http.Header {
6566	if c.header_ == nil {
6567		c.header_ = make(http.Header)
6568	}
6569	return c.header_
6570}
6571
6572func (c *ProjectsOccurrencesListCall) doRequest(alt string) (*http.Response, error) {
6573	reqHeaders := make(http.Header)
6574	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
6575	for k, v := range c.header_ {
6576		reqHeaders[k] = v
6577	}
6578	reqHeaders.Set("User-Agent", c.s.userAgent())
6579	if c.ifNoneMatch_ != "" {
6580		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
6581	}
6582	var body io.Reader = nil
6583	c.urlParams_.Set("alt", alt)
6584	c.urlParams_.Set("prettyPrint", "false")
6585	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/occurrences")
6586	urls += "?" + c.urlParams_.Encode()
6587	req, err := http.NewRequest("GET", urls, body)
6588	if err != nil {
6589		return nil, err
6590	}
6591	req.Header = reqHeaders
6592	googleapi.Expand(req.URL, map[string]string{
6593		"parent": c.parent,
6594	})
6595	return gensupport.SendRequest(c.ctx_, c.s.client, req)
6596}
6597
6598// Do executes the "containeranalysis.projects.occurrences.list" call.
6599// Exactly one of *ListOccurrencesResponse or error will be non-nil. Any
6600// non-2xx status code is an error. Response headers are in either
6601// *ListOccurrencesResponse.ServerResponse.Header or (if a response was
6602// returned at all) in error.(*googleapi.Error).Header. Use
6603// googleapi.IsNotModified to check whether the returned error was
6604// because http.StatusNotModified was returned.
6605func (c *ProjectsOccurrencesListCall) Do(opts ...googleapi.CallOption) (*ListOccurrencesResponse, error) {
6606	gensupport.SetOptions(c.urlParams_, opts...)
6607	res, err := c.doRequest("json")
6608	if res != nil && res.StatusCode == http.StatusNotModified {
6609		if res.Body != nil {
6610			res.Body.Close()
6611		}
6612		return nil, &googleapi.Error{
6613			Code:   res.StatusCode,
6614			Header: res.Header,
6615		}
6616	}
6617	if err != nil {
6618		return nil, err
6619	}
6620	defer googleapi.CloseBody(res)
6621	if err := googleapi.CheckResponse(res); err != nil {
6622		return nil, err
6623	}
6624	ret := &ListOccurrencesResponse{
6625		ServerResponse: googleapi.ServerResponse{
6626			Header:         res.Header,
6627			HTTPStatusCode: res.StatusCode,
6628		},
6629	}
6630	target := &ret
6631	if err := gensupport.DecodeResponse(target, res); err != nil {
6632		return nil, err
6633	}
6634	return ret, nil
6635	// {
6636	//   "description": "Lists occurrences for the specified project.",
6637	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences",
6638	//   "httpMethod": "GET",
6639	//   "id": "containeranalysis.projects.occurrences.list",
6640	//   "parameterOrder": [
6641	//     "parent"
6642	//   ],
6643	//   "parameters": {
6644	//     "filter": {
6645	//       "description": "The filter expression.",
6646	//       "location": "query",
6647	//       "type": "string"
6648	//     },
6649	//     "pageSize": {
6650	//       "description": "Number of occurrences to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.",
6651	//       "format": "int32",
6652	//       "location": "query",
6653	//       "type": "integer"
6654	//     },
6655	//     "pageToken": {
6656	//       "description": "Token to provide to skip to a particular spot in the list.",
6657	//       "location": "query",
6658	//       "type": "string"
6659	//     },
6660	//     "parent": {
6661	//       "description": "Required. The name of the project to list occurrences for in the form of `projects/[PROJECT_ID]`.",
6662	//       "location": "path",
6663	//       "pattern": "^projects/[^/]+$",
6664	//       "required": true,
6665	//       "type": "string"
6666	//     }
6667	//   },
6668	//   "path": "v1beta1/{+parent}/occurrences",
6669	//   "response": {
6670	//     "$ref": "ListOccurrencesResponse"
6671	//   },
6672	//   "scopes": [
6673	//     "https://www.googleapis.com/auth/cloud-platform"
6674	//   ]
6675	// }
6676
6677}
6678
6679// Pages invokes f for each page of results.
6680// A non-nil error returned from f will halt the iteration.
6681// The provided context supersedes any context provided to the Context method.
6682func (c *ProjectsOccurrencesListCall) Pages(ctx context.Context, f func(*ListOccurrencesResponse) error) error {
6683	c.ctx_ = ctx
6684	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
6685	for {
6686		x, err := c.Do()
6687		if err != nil {
6688			return err
6689		}
6690		if err := f(x); err != nil {
6691			return err
6692		}
6693		if x.NextPageToken == "" {
6694			return nil
6695		}
6696		c.PageToken(x.NextPageToken)
6697	}
6698}
6699
6700// method id "containeranalysis.projects.occurrences.patch":
6701
6702type ProjectsOccurrencesPatchCall struct {
6703	s          *Service
6704	name       string
6705	occurrence *Occurrence
6706	urlParams_ gensupport.URLParams
6707	ctx_       context.Context
6708	header_    http.Header
6709}
6710
6711// Patch: Updates the specified occurrence.
6712//
6713// - name: The name of the occurrence in the form of
6714//   `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
6715func (r *ProjectsOccurrencesService) Patch(name string, occurrence *Occurrence) *ProjectsOccurrencesPatchCall {
6716	c := &ProjectsOccurrencesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
6717	c.name = name
6718	c.occurrence = occurrence
6719	return c
6720}
6721
6722// UpdateMask sets the optional parameter "updateMask": The fields to
6723// update.
6724func (c *ProjectsOccurrencesPatchCall) UpdateMask(updateMask string) *ProjectsOccurrencesPatchCall {
6725	c.urlParams_.Set("updateMask", updateMask)
6726	return c
6727}
6728
6729// Fields allows partial responses to be retrieved. See
6730// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
6731// for more information.
6732func (c *ProjectsOccurrencesPatchCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesPatchCall {
6733	c.urlParams_.Set("fields", googleapi.CombineFields(s))
6734	return c
6735}
6736
6737// Context sets the context to be used in this call's Do method. Any
6738// pending HTTP request will be aborted if the provided context is
6739// canceled.
6740func (c *ProjectsOccurrencesPatchCall) Context(ctx context.Context) *ProjectsOccurrencesPatchCall {
6741	c.ctx_ = ctx
6742	return c
6743}
6744
6745// Header returns an http.Header that can be modified by the caller to
6746// add HTTP headers to the request.
6747func (c *ProjectsOccurrencesPatchCall) Header() http.Header {
6748	if c.header_ == nil {
6749		c.header_ = make(http.Header)
6750	}
6751	return c.header_
6752}
6753
6754func (c *ProjectsOccurrencesPatchCall) doRequest(alt string) (*http.Response, error) {
6755	reqHeaders := make(http.Header)
6756	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
6757	for k, v := range c.header_ {
6758		reqHeaders[k] = v
6759	}
6760	reqHeaders.Set("User-Agent", c.s.userAgent())
6761	var body io.Reader = nil
6762	body, err := googleapi.WithoutDataWrapper.JSONReader(c.occurrence)
6763	if err != nil {
6764		return nil, err
6765	}
6766	reqHeaders.Set("Content-Type", "application/json")
6767	c.urlParams_.Set("alt", alt)
6768	c.urlParams_.Set("prettyPrint", "false")
6769	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
6770	urls += "?" + c.urlParams_.Encode()
6771	req, err := http.NewRequest("PATCH", urls, body)
6772	if err != nil {
6773		return nil, err
6774	}
6775	req.Header = reqHeaders
6776	googleapi.Expand(req.URL, map[string]string{
6777		"name": c.name,
6778	})
6779	return gensupport.SendRequest(c.ctx_, c.s.client, req)
6780}
6781
6782// Do executes the "containeranalysis.projects.occurrences.patch" call.
6783// Exactly one of *Occurrence or error will be non-nil. Any non-2xx
6784// status code is an error. Response headers are in either
6785// *Occurrence.ServerResponse.Header or (if a response was returned at
6786// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
6787// to check whether the returned error was because
6788// http.StatusNotModified was returned.
6789func (c *ProjectsOccurrencesPatchCall) Do(opts ...googleapi.CallOption) (*Occurrence, error) {
6790	gensupport.SetOptions(c.urlParams_, opts...)
6791	res, err := c.doRequest("json")
6792	if res != nil && res.StatusCode == http.StatusNotModified {
6793		if res.Body != nil {
6794			res.Body.Close()
6795		}
6796		return nil, &googleapi.Error{
6797			Code:   res.StatusCode,
6798			Header: res.Header,
6799		}
6800	}
6801	if err != nil {
6802		return nil, err
6803	}
6804	defer googleapi.CloseBody(res)
6805	if err := googleapi.CheckResponse(res); err != nil {
6806		return nil, err
6807	}
6808	ret := &Occurrence{
6809		ServerResponse: googleapi.ServerResponse{
6810			Header:         res.Header,
6811			HTTPStatusCode: res.StatusCode,
6812		},
6813	}
6814	target := &ret
6815	if err := gensupport.DecodeResponse(target, res); err != nil {
6816		return nil, err
6817	}
6818	return ret, nil
6819	// {
6820	//   "description": "Updates the specified occurrence.",
6821	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}",
6822	//   "httpMethod": "PATCH",
6823	//   "id": "containeranalysis.projects.occurrences.patch",
6824	//   "parameterOrder": [
6825	//     "name"
6826	//   ],
6827	//   "parameters": {
6828	//     "name": {
6829	//       "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.",
6830	//       "location": "path",
6831	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
6832	//       "required": true,
6833	//       "type": "string"
6834	//     },
6835	//     "updateMask": {
6836	//       "description": "The fields to update.",
6837	//       "format": "google-fieldmask",
6838	//       "location": "query",
6839	//       "type": "string"
6840	//     }
6841	//   },
6842	//   "path": "v1beta1/{+name}",
6843	//   "request": {
6844	//     "$ref": "Occurrence"
6845	//   },
6846	//   "response": {
6847	//     "$ref": "Occurrence"
6848	//   },
6849	//   "scopes": [
6850	//     "https://www.googleapis.com/auth/cloud-platform"
6851	//   ]
6852	// }
6853
6854}
6855
6856// method id "containeranalysis.projects.occurrences.setIamPolicy":
6857
6858type ProjectsOccurrencesSetIamPolicyCall struct {
6859	s                   *Service
6860	resource            string
6861	setiampolicyrequest *SetIamPolicyRequest
6862	urlParams_          gensupport.URLParams
6863	ctx_                context.Context
6864	header_             http.Header
6865}
6866
6867// SetIamPolicy: Sets the access control policy on the specified note or
6868// occurrence. Requires `containeranalysis.notes.setIamPolicy` or
6869// `containeranalysis.occurrences.setIamPolicy` permission if the
6870// resource is a note or an occurrence, respectively. The resource takes
6871// the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and
6872// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.
6873//
6874// - resource: REQUIRED: The resource for which the policy is being
6875//   specified. See the operation documentation for the appropriate
6876//   value for this field.
6877func (r *ProjectsOccurrencesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsOccurrencesSetIamPolicyCall {
6878	c := &ProjectsOccurrencesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
6879	c.resource = resource
6880	c.setiampolicyrequest = setiampolicyrequest
6881	return c
6882}
6883
6884// Fields allows partial responses to be retrieved. See
6885// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
6886// for more information.
6887func (c *ProjectsOccurrencesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesSetIamPolicyCall {
6888	c.urlParams_.Set("fields", googleapi.CombineFields(s))
6889	return c
6890}
6891
6892// Context sets the context to be used in this call's Do method. Any
6893// pending HTTP request will be aborted if the provided context is
6894// canceled.
6895func (c *ProjectsOccurrencesSetIamPolicyCall) Context(ctx context.Context) *ProjectsOccurrencesSetIamPolicyCall {
6896	c.ctx_ = ctx
6897	return c
6898}
6899
6900// Header returns an http.Header that can be modified by the caller to
6901// add HTTP headers to the request.
6902func (c *ProjectsOccurrencesSetIamPolicyCall) Header() http.Header {
6903	if c.header_ == nil {
6904		c.header_ = make(http.Header)
6905	}
6906	return c.header_
6907}
6908
6909func (c *ProjectsOccurrencesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
6910	reqHeaders := make(http.Header)
6911	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
6912	for k, v := range c.header_ {
6913		reqHeaders[k] = v
6914	}
6915	reqHeaders.Set("User-Agent", c.s.userAgent())
6916	var body io.Reader = nil
6917	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
6918	if err != nil {
6919		return nil, err
6920	}
6921	reqHeaders.Set("Content-Type", "application/json")
6922	c.urlParams_.Set("alt", alt)
6923	c.urlParams_.Set("prettyPrint", "false")
6924	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:setIamPolicy")
6925	urls += "?" + c.urlParams_.Encode()
6926	req, err := http.NewRequest("POST", urls, body)
6927	if err != nil {
6928		return nil, err
6929	}
6930	req.Header = reqHeaders
6931	googleapi.Expand(req.URL, map[string]string{
6932		"resource": c.resource,
6933	})
6934	return gensupport.SendRequest(c.ctx_, c.s.client, req)
6935}
6936
6937// Do executes the "containeranalysis.projects.occurrences.setIamPolicy" call.
6938// Exactly one of *Policy or error will be non-nil. Any non-2xx status
6939// code is an error. Response headers are in either
6940// *Policy.ServerResponse.Header or (if a response was returned at all)
6941// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
6942// check whether the returned error was because http.StatusNotModified
6943// was returned.
6944func (c *ProjectsOccurrencesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
6945	gensupport.SetOptions(c.urlParams_, opts...)
6946	res, err := c.doRequest("json")
6947	if res != nil && res.StatusCode == http.StatusNotModified {
6948		if res.Body != nil {
6949			res.Body.Close()
6950		}
6951		return nil, &googleapi.Error{
6952			Code:   res.StatusCode,
6953			Header: res.Header,
6954		}
6955	}
6956	if err != nil {
6957		return nil, err
6958	}
6959	defer googleapi.CloseBody(res)
6960	if err := googleapi.CheckResponse(res); err != nil {
6961		return nil, err
6962	}
6963	ret := &Policy{
6964		ServerResponse: googleapi.ServerResponse{
6965			Header:         res.Header,
6966			HTTPStatusCode: res.StatusCode,
6967		},
6968	}
6969	target := &ret
6970	if err := gensupport.DecodeResponse(target, res); err != nil {
6971		return nil, err
6972	}
6973	return ret, nil
6974	// {
6975	//   "description": "Sets the access control policy on the specified note or occurrence. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or an occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.",
6976	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}:setIamPolicy",
6977	//   "httpMethod": "POST",
6978	//   "id": "containeranalysis.projects.occurrences.setIamPolicy",
6979	//   "parameterOrder": [
6980	//     "resource"
6981	//   ],
6982	//   "parameters": {
6983	//     "resource": {
6984	//       "description": "REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.",
6985	//       "location": "path",
6986	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
6987	//       "required": true,
6988	//       "type": "string"
6989	//     }
6990	//   },
6991	//   "path": "v1beta1/{+resource}:setIamPolicy",
6992	//   "request": {
6993	//     "$ref": "SetIamPolicyRequest"
6994	//   },
6995	//   "response": {
6996	//     "$ref": "Policy"
6997	//   },
6998	//   "scopes": [
6999	//     "https://www.googleapis.com/auth/cloud-platform"
7000	//   ]
7001	// }
7002
7003}
7004
7005// method id "containeranalysis.projects.occurrences.testIamPermissions":
7006
7007type ProjectsOccurrencesTestIamPermissionsCall struct {
7008	s                         *Service
7009	resource                  string
7010	testiampermissionsrequest *TestIamPermissionsRequest
7011	urlParams_                gensupport.URLParams
7012	ctx_                      context.Context
7013	header_                   http.Header
7014}
7015
7016// TestIamPermissions: Returns the permissions that a caller has on the
7017// specified note or occurrence. Requires list permission on the project
7018// (for example, `containeranalysis.notes.list`). The resource takes the
7019// format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and
7020// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.
7021//
7022// - resource: REQUIRED: The resource for which the policy detail is
7023//   being requested. See the operation documentation for the
7024//   appropriate value for this field.
7025func (r *ProjectsOccurrencesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsOccurrencesTestIamPermissionsCall {
7026	c := &ProjectsOccurrencesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7027	c.resource = resource
7028	c.testiampermissionsrequest = testiampermissionsrequest
7029	return c
7030}
7031
7032// Fields allows partial responses to be retrieved. See
7033// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
7034// for more information.
7035func (c *ProjectsOccurrencesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsOccurrencesTestIamPermissionsCall {
7036	c.urlParams_.Set("fields", googleapi.CombineFields(s))
7037	return c
7038}
7039
7040// Context sets the context to be used in this call's Do method. Any
7041// pending HTTP request will be aborted if the provided context is
7042// canceled.
7043func (c *ProjectsOccurrencesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsOccurrencesTestIamPermissionsCall {
7044	c.ctx_ = ctx
7045	return c
7046}
7047
7048// Header returns an http.Header that can be modified by the caller to
7049// add HTTP headers to the request.
7050func (c *ProjectsOccurrencesTestIamPermissionsCall) Header() http.Header {
7051	if c.header_ == nil {
7052		c.header_ = make(http.Header)
7053	}
7054	return c.header_
7055}
7056
7057func (c *ProjectsOccurrencesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
7058	reqHeaders := make(http.Header)
7059	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
7060	for k, v := range c.header_ {
7061		reqHeaders[k] = v
7062	}
7063	reqHeaders.Set("User-Agent", c.s.userAgent())
7064	var body io.Reader = nil
7065	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
7066	if err != nil {
7067		return nil, err
7068	}
7069	reqHeaders.Set("Content-Type", "application/json")
7070	c.urlParams_.Set("alt", alt)
7071	c.urlParams_.Set("prettyPrint", "false")
7072	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:testIamPermissions")
7073	urls += "?" + c.urlParams_.Encode()
7074	req, err := http.NewRequest("POST", urls, body)
7075	if err != nil {
7076		return nil, err
7077	}
7078	req.Header = reqHeaders
7079	googleapi.Expand(req.URL, map[string]string{
7080		"resource": c.resource,
7081	})
7082	return gensupport.SendRequest(c.ctx_, c.s.client, req)
7083}
7084
7085// Do executes the "containeranalysis.projects.occurrences.testIamPermissions" call.
7086// Exactly one of *TestIamPermissionsResponse or error will be non-nil.
7087// Any non-2xx status code is an error. Response headers are in either
7088// *TestIamPermissionsResponse.ServerResponse.Header or (if a response
7089// was returned at all) in error.(*googleapi.Error).Header. Use
7090// googleapi.IsNotModified to check whether the returned error was
7091// because http.StatusNotModified was returned.
7092func (c *ProjectsOccurrencesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
7093	gensupport.SetOptions(c.urlParams_, opts...)
7094	res, err := c.doRequest("json")
7095	if res != nil && res.StatusCode == http.StatusNotModified {
7096		if res.Body != nil {
7097			res.Body.Close()
7098		}
7099		return nil, &googleapi.Error{
7100			Code:   res.StatusCode,
7101			Header: res.Header,
7102		}
7103	}
7104	if err != nil {
7105		return nil, err
7106	}
7107	defer googleapi.CloseBody(res)
7108	if err := googleapi.CheckResponse(res); err != nil {
7109		return nil, err
7110	}
7111	ret := &TestIamPermissionsResponse{
7112		ServerResponse: googleapi.ServerResponse{
7113			Header:         res.Header,
7114			HTTPStatusCode: res.StatusCode,
7115		},
7116	}
7117	target := &ret
7118	if err := gensupport.DecodeResponse(target, res); err != nil {
7119		return nil, err
7120	}
7121	return ret, nil
7122	// {
7123	//   "description": "Returns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example, `containeranalysis.notes.list`). The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.",
7124	//   "flatPath": "v1beta1/projects/{projectsId}/occurrences/{occurrencesId}:testIamPermissions",
7125	//   "httpMethod": "POST",
7126	//   "id": "containeranalysis.projects.occurrences.testIamPermissions",
7127	//   "parameterOrder": [
7128	//     "resource"
7129	//   ],
7130	//   "parameters": {
7131	//     "resource": {
7132	//       "description": "REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.",
7133	//       "location": "path",
7134	//       "pattern": "^projects/[^/]+/occurrences/[^/]+$",
7135	//       "required": true,
7136	//       "type": "string"
7137	//     }
7138	//   },
7139	//   "path": "v1beta1/{+resource}:testIamPermissions",
7140	//   "request": {
7141	//     "$ref": "TestIamPermissionsRequest"
7142	//   },
7143	//   "response": {
7144	//     "$ref": "TestIamPermissionsResponse"
7145	//   },
7146	//   "scopes": [
7147	//     "https://www.googleapis.com/auth/cloud-platform"
7148	//   ]
7149	// }
7150
7151}
7152
7153// method id "containeranalysis.projects.scanConfigs.get":
7154
7155type ProjectsScanConfigsGetCall struct {
7156	s            *Service
7157	name         string
7158	urlParams_   gensupport.URLParams
7159	ifNoneMatch_ string
7160	ctx_         context.Context
7161	header_      http.Header
7162}
7163
7164// Get: Gets the specified scan configuration.
7165//
7166// - name: The name of the scan configuration in the form of
7167//   `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
7168func (r *ProjectsScanConfigsService) Get(name string) *ProjectsScanConfigsGetCall {
7169	c := &ProjectsScanConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7170	c.name = name
7171	return c
7172}
7173
7174// Fields allows partial responses to be retrieved. See
7175// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
7176// for more information.
7177func (c *ProjectsScanConfigsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsGetCall {
7178	c.urlParams_.Set("fields", googleapi.CombineFields(s))
7179	return c
7180}
7181
7182// IfNoneMatch sets the optional parameter which makes the operation
7183// fail if the object's ETag matches the given value. This is useful for
7184// getting updates only after the object has changed since the last
7185// request. Use googleapi.IsNotModified to check whether the response
7186// error from Do is the result of In-None-Match.
7187func (c *ProjectsScanConfigsGetCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsGetCall {
7188	c.ifNoneMatch_ = entityTag
7189	return c
7190}
7191
7192// Context sets the context to be used in this call's Do method. Any
7193// pending HTTP request will be aborted if the provided context is
7194// canceled.
7195func (c *ProjectsScanConfigsGetCall) Context(ctx context.Context) *ProjectsScanConfigsGetCall {
7196	c.ctx_ = ctx
7197	return c
7198}
7199
7200// Header returns an http.Header that can be modified by the caller to
7201// add HTTP headers to the request.
7202func (c *ProjectsScanConfigsGetCall) Header() http.Header {
7203	if c.header_ == nil {
7204		c.header_ = make(http.Header)
7205	}
7206	return c.header_
7207}
7208
7209func (c *ProjectsScanConfigsGetCall) doRequest(alt string) (*http.Response, error) {
7210	reqHeaders := make(http.Header)
7211	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
7212	for k, v := range c.header_ {
7213		reqHeaders[k] = v
7214	}
7215	reqHeaders.Set("User-Agent", c.s.userAgent())
7216	if c.ifNoneMatch_ != "" {
7217		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
7218	}
7219	var body io.Reader = nil
7220	c.urlParams_.Set("alt", alt)
7221	c.urlParams_.Set("prettyPrint", "false")
7222	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
7223	urls += "?" + c.urlParams_.Encode()
7224	req, err := http.NewRequest("GET", urls, body)
7225	if err != nil {
7226		return nil, err
7227	}
7228	req.Header = reqHeaders
7229	googleapi.Expand(req.URL, map[string]string{
7230		"name": c.name,
7231	})
7232	return gensupport.SendRequest(c.ctx_, c.s.client, req)
7233}
7234
7235// Do executes the "containeranalysis.projects.scanConfigs.get" call.
7236// Exactly one of *ScanConfig or error will be non-nil. Any non-2xx
7237// status code is an error. Response headers are in either
7238// *ScanConfig.ServerResponse.Header or (if a response was returned at
7239// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
7240// to check whether the returned error was because
7241// http.StatusNotModified was returned.
7242func (c *ProjectsScanConfigsGetCall) Do(opts ...googleapi.CallOption) (*ScanConfig, error) {
7243	gensupport.SetOptions(c.urlParams_, opts...)
7244	res, err := c.doRequest("json")
7245	if res != nil && res.StatusCode == http.StatusNotModified {
7246		if res.Body != nil {
7247			res.Body.Close()
7248		}
7249		return nil, &googleapi.Error{
7250			Code:   res.StatusCode,
7251			Header: res.Header,
7252		}
7253	}
7254	if err != nil {
7255		return nil, err
7256	}
7257	defer googleapi.CloseBody(res)
7258	if err := googleapi.CheckResponse(res); err != nil {
7259		return nil, err
7260	}
7261	ret := &ScanConfig{
7262		ServerResponse: googleapi.ServerResponse{
7263			Header:         res.Header,
7264			HTTPStatusCode: res.StatusCode,
7265		},
7266	}
7267	target := &ret
7268	if err := gensupport.DecodeResponse(target, res); err != nil {
7269		return nil, err
7270	}
7271	return ret, nil
7272	// {
7273	//   "description": "Gets the specified scan configuration.",
7274	//   "flatPath": "v1beta1/projects/{projectsId}/scanConfigs/{scanConfigsId}",
7275	//   "httpMethod": "GET",
7276	//   "id": "containeranalysis.projects.scanConfigs.get",
7277	//   "parameterOrder": [
7278	//     "name"
7279	//   ],
7280	//   "parameters": {
7281	//     "name": {
7282	//       "description": "Required. The name of the scan configuration in the form of `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.",
7283	//       "location": "path",
7284	//       "pattern": "^projects/[^/]+/scanConfigs/[^/]+$",
7285	//       "required": true,
7286	//       "type": "string"
7287	//     }
7288	//   },
7289	//   "path": "v1beta1/{+name}",
7290	//   "response": {
7291	//     "$ref": "ScanConfig"
7292	//   },
7293	//   "scopes": [
7294	//     "https://www.googleapis.com/auth/cloud-platform"
7295	//   ]
7296	// }
7297
7298}
7299
7300// method id "containeranalysis.projects.scanConfigs.list":
7301
7302type ProjectsScanConfigsListCall struct {
7303	s            *Service
7304	parent       string
7305	urlParams_   gensupport.URLParams
7306	ifNoneMatch_ string
7307	ctx_         context.Context
7308	header_      http.Header
7309}
7310
7311// List: Lists scan configurations for the specified project.
7312//
7313// - parent: The name of the project to list scan configurations for in
7314//   the form of `projects/[PROJECT_ID]`.
7315func (r *ProjectsScanConfigsService) List(parent string) *ProjectsScanConfigsListCall {
7316	c := &ProjectsScanConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7317	c.parent = parent
7318	return c
7319}
7320
7321// Filter sets the optional parameter "filter": Required. The filter
7322// expression.
7323func (c *ProjectsScanConfigsListCall) Filter(filter string) *ProjectsScanConfigsListCall {
7324	c.urlParams_.Set("filter", filter)
7325	return c
7326}
7327
7328// PageSize sets the optional parameter "pageSize": The number of scan
7329// configs to return in the list.
7330func (c *ProjectsScanConfigsListCall) PageSize(pageSize int64) *ProjectsScanConfigsListCall {
7331	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
7332	return c
7333}
7334
7335// PageToken sets the optional parameter "pageToken": Token to provide
7336// to skip to a particular spot in the list.
7337func (c *ProjectsScanConfigsListCall) PageToken(pageToken string) *ProjectsScanConfigsListCall {
7338	c.urlParams_.Set("pageToken", pageToken)
7339	return c
7340}
7341
7342// Fields allows partial responses to be retrieved. See
7343// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
7344// for more information.
7345func (c *ProjectsScanConfigsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsListCall {
7346	c.urlParams_.Set("fields", googleapi.CombineFields(s))
7347	return c
7348}
7349
7350// IfNoneMatch sets the optional parameter which makes the operation
7351// fail if the object's ETag matches the given value. This is useful for
7352// getting updates only after the object has changed since the last
7353// request. Use googleapi.IsNotModified to check whether the response
7354// error from Do is the result of In-None-Match.
7355func (c *ProjectsScanConfigsListCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsListCall {
7356	c.ifNoneMatch_ = entityTag
7357	return c
7358}
7359
7360// Context sets the context to be used in this call's Do method. Any
7361// pending HTTP request will be aborted if the provided context is
7362// canceled.
7363func (c *ProjectsScanConfigsListCall) Context(ctx context.Context) *ProjectsScanConfigsListCall {
7364	c.ctx_ = ctx
7365	return c
7366}
7367
7368// Header returns an http.Header that can be modified by the caller to
7369// add HTTP headers to the request.
7370func (c *ProjectsScanConfigsListCall) Header() http.Header {
7371	if c.header_ == nil {
7372		c.header_ = make(http.Header)
7373	}
7374	return c.header_
7375}
7376
7377func (c *ProjectsScanConfigsListCall) doRequest(alt string) (*http.Response, error) {
7378	reqHeaders := make(http.Header)
7379	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
7380	for k, v := range c.header_ {
7381		reqHeaders[k] = v
7382	}
7383	reqHeaders.Set("User-Agent", c.s.userAgent())
7384	if c.ifNoneMatch_ != "" {
7385		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
7386	}
7387	var body io.Reader = nil
7388	c.urlParams_.Set("alt", alt)
7389	c.urlParams_.Set("prettyPrint", "false")
7390	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/scanConfigs")
7391	urls += "?" + c.urlParams_.Encode()
7392	req, err := http.NewRequest("GET", urls, body)
7393	if err != nil {
7394		return nil, err
7395	}
7396	req.Header = reqHeaders
7397	googleapi.Expand(req.URL, map[string]string{
7398		"parent": c.parent,
7399	})
7400	return gensupport.SendRequest(c.ctx_, c.s.client, req)
7401}
7402
7403// Do executes the "containeranalysis.projects.scanConfigs.list" call.
7404// Exactly one of *ListScanConfigsResponse or error will be non-nil. Any
7405// non-2xx status code is an error. Response headers are in either
7406// *ListScanConfigsResponse.ServerResponse.Header or (if a response was
7407// returned at all) in error.(*googleapi.Error).Header. Use
7408// googleapi.IsNotModified to check whether the returned error was
7409// because http.StatusNotModified was returned.
7410func (c *ProjectsScanConfigsListCall) Do(opts ...googleapi.CallOption) (*ListScanConfigsResponse, error) {
7411	gensupport.SetOptions(c.urlParams_, opts...)
7412	res, err := c.doRequest("json")
7413	if res != nil && res.StatusCode == http.StatusNotModified {
7414		if res.Body != nil {
7415			res.Body.Close()
7416		}
7417		return nil, &googleapi.Error{
7418			Code:   res.StatusCode,
7419			Header: res.Header,
7420		}
7421	}
7422	if err != nil {
7423		return nil, err
7424	}
7425	defer googleapi.CloseBody(res)
7426	if err := googleapi.CheckResponse(res); err != nil {
7427		return nil, err
7428	}
7429	ret := &ListScanConfigsResponse{
7430		ServerResponse: googleapi.ServerResponse{
7431			Header:         res.Header,
7432			HTTPStatusCode: res.StatusCode,
7433		},
7434	}
7435	target := &ret
7436	if err := gensupport.DecodeResponse(target, res); err != nil {
7437		return nil, err
7438	}
7439	return ret, nil
7440	// {
7441	//   "description": "Lists scan configurations for the specified project.",
7442	//   "flatPath": "v1beta1/projects/{projectsId}/scanConfigs",
7443	//   "httpMethod": "GET",
7444	//   "id": "containeranalysis.projects.scanConfigs.list",
7445	//   "parameterOrder": [
7446	//     "parent"
7447	//   ],
7448	//   "parameters": {
7449	//     "filter": {
7450	//       "description": "Required. The filter expression.",
7451	//       "location": "query",
7452	//       "type": "string"
7453	//     },
7454	//     "pageSize": {
7455	//       "description": "The number of scan configs to return in the list.",
7456	//       "format": "int32",
7457	//       "location": "query",
7458	//       "type": "integer"
7459	//     },
7460	//     "pageToken": {
7461	//       "description": "Token to provide to skip to a particular spot in the list.",
7462	//       "location": "query",
7463	//       "type": "string"
7464	//     },
7465	//     "parent": {
7466	//       "description": "Required. The name of the project to list scan configurations for in the form of `projects/[PROJECT_ID]`.",
7467	//       "location": "path",
7468	//       "pattern": "^projects/[^/]+$",
7469	//       "required": true,
7470	//       "type": "string"
7471	//     }
7472	//   },
7473	//   "path": "v1beta1/{+parent}/scanConfigs",
7474	//   "response": {
7475	//     "$ref": "ListScanConfigsResponse"
7476	//   },
7477	//   "scopes": [
7478	//     "https://www.googleapis.com/auth/cloud-platform"
7479	//   ]
7480	// }
7481
7482}
7483
7484// Pages invokes f for each page of results.
7485// A non-nil error returned from f will halt the iteration.
7486// The provided context supersedes any context provided to the Context method.
7487func (c *ProjectsScanConfigsListCall) Pages(ctx context.Context, f func(*ListScanConfigsResponse) error) error {
7488	c.ctx_ = ctx
7489	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
7490	for {
7491		x, err := c.Do()
7492		if err != nil {
7493			return err
7494		}
7495		if err := f(x); err != nil {
7496			return err
7497		}
7498		if x.NextPageToken == "" {
7499			return nil
7500		}
7501		c.PageToken(x.NextPageToken)
7502	}
7503}
7504
7505// method id "containeranalysis.projects.scanConfigs.update":
7506
7507type ProjectsScanConfigsUpdateCall struct {
7508	s          *Service
7509	name       string
7510	scanconfig *ScanConfig
7511	urlParams_ gensupport.URLParams
7512	ctx_       context.Context
7513	header_    http.Header
7514}
7515
7516// Update: Updates the specified scan configuration.
7517//
7518// - name: The name of the scan configuration in the form of
7519//   `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
7520func (r *ProjectsScanConfigsService) Update(name string, scanconfig *ScanConfig) *ProjectsScanConfigsUpdateCall {
7521	c := &ProjectsScanConfigsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7522	c.name = name
7523	c.scanconfig = scanconfig
7524	return c
7525}
7526
7527// Fields allows partial responses to be retrieved. See
7528// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
7529// for more information.
7530func (c *ProjectsScanConfigsUpdateCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsUpdateCall {
7531	c.urlParams_.Set("fields", googleapi.CombineFields(s))
7532	return c
7533}
7534
7535// Context sets the context to be used in this call's Do method. Any
7536// pending HTTP request will be aborted if the provided context is
7537// canceled.
7538func (c *ProjectsScanConfigsUpdateCall) Context(ctx context.Context) *ProjectsScanConfigsUpdateCall {
7539	c.ctx_ = ctx
7540	return c
7541}
7542
7543// Header returns an http.Header that can be modified by the caller to
7544// add HTTP headers to the request.
7545func (c *ProjectsScanConfigsUpdateCall) Header() http.Header {
7546	if c.header_ == nil {
7547		c.header_ = make(http.Header)
7548	}
7549	return c.header_
7550}
7551
7552func (c *ProjectsScanConfigsUpdateCall) doRequest(alt string) (*http.Response, error) {
7553	reqHeaders := make(http.Header)
7554	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
7555	for k, v := range c.header_ {
7556		reqHeaders[k] = v
7557	}
7558	reqHeaders.Set("User-Agent", c.s.userAgent())
7559	var body io.Reader = nil
7560	body, err := googleapi.WithoutDataWrapper.JSONReader(c.scanconfig)
7561	if err != nil {
7562		return nil, err
7563	}
7564	reqHeaders.Set("Content-Type", "application/json")
7565	c.urlParams_.Set("alt", alt)
7566	c.urlParams_.Set("prettyPrint", "false")
7567	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}")
7568	urls += "?" + c.urlParams_.Encode()
7569	req, err := http.NewRequest("PUT", urls, body)
7570	if err != nil {
7571		return nil, err
7572	}
7573	req.Header = reqHeaders
7574	googleapi.Expand(req.URL, map[string]string{
7575		"name": c.name,
7576	})
7577	return gensupport.SendRequest(c.ctx_, c.s.client, req)
7578}
7579
7580// Do executes the "containeranalysis.projects.scanConfigs.update" call.
7581// Exactly one of *ScanConfig or error will be non-nil. Any non-2xx
7582// status code is an error. Response headers are in either
7583// *ScanConfig.ServerResponse.Header or (if a response was returned at
7584// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
7585// to check whether the returned error was because
7586// http.StatusNotModified was returned.
7587func (c *ProjectsScanConfigsUpdateCall) Do(opts ...googleapi.CallOption) (*ScanConfig, error) {
7588	gensupport.SetOptions(c.urlParams_, opts...)
7589	res, err := c.doRequest("json")
7590	if res != nil && res.StatusCode == http.StatusNotModified {
7591		if res.Body != nil {
7592			res.Body.Close()
7593		}
7594		return nil, &googleapi.Error{
7595			Code:   res.StatusCode,
7596			Header: res.Header,
7597		}
7598	}
7599	if err != nil {
7600		return nil, err
7601	}
7602	defer googleapi.CloseBody(res)
7603	if err := googleapi.CheckResponse(res); err != nil {
7604		return nil, err
7605	}
7606	ret := &ScanConfig{
7607		ServerResponse: googleapi.ServerResponse{
7608			Header:         res.Header,
7609			HTTPStatusCode: res.StatusCode,
7610		},
7611	}
7612	target := &ret
7613	if err := gensupport.DecodeResponse(target, res); err != nil {
7614		return nil, err
7615	}
7616	return ret, nil
7617	// {
7618	//   "description": "Updates the specified scan configuration.",
7619	//   "flatPath": "v1beta1/projects/{projectsId}/scanConfigs/{scanConfigsId}",
7620	//   "httpMethod": "PUT",
7621	//   "id": "containeranalysis.projects.scanConfigs.update",
7622	//   "parameterOrder": [
7623	//     "name"
7624	//   ],
7625	//   "parameters": {
7626	//     "name": {
7627	//       "description": "Required. The name of the scan configuration in the form of `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.",
7628	//       "location": "path",
7629	//       "pattern": "^projects/[^/]+/scanConfigs/[^/]+$",
7630	//       "required": true,
7631	//       "type": "string"
7632	//     }
7633	//   },
7634	//   "path": "v1beta1/{+name}",
7635	//   "request": {
7636	//     "$ref": "ScanConfig"
7637	//   },
7638	//   "response": {
7639	//     "$ref": "ScanConfig"
7640	//   },
7641	//   "scopes": [
7642	//     "https://www.googleapis.com/auth/cloud-platform"
7643	//   ]
7644	// }
7645
7646}
7647