diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/README.md b/clients/google-api-services-auditmanager/v1/2.0.0/README.md new file mode 100644 index 00000000000..e0ac2231cb1 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/README.md @@ -0,0 +1,44 @@ +# Audit Manager API Client Library for Java + +The Audit Manager API allows customers to manage compliance audits. + +This page contains information about getting started with the Audit Manager API +using the Google API Client Library for Java. In addition, you may be interested +in the following documentation: + +* Browse the [Javadoc reference for the Audit Manager API][javadoc] +* Read the [Developer's Guide for the Google API Client Library for Java][google-api-client]. +* Interact with this API in your browser using the [APIs Explorer for the Audit Manager API][api-explorer] + +## Installation + +### Maven + +Add the following lines to your `pom.xml` file: + +```xml + + + + com.google.apis + google-api-services-auditmanager + v1-rev20260826-2.0.0 + + + +``` + +### Gradle + +```gradle +repositories { + mavenCentral() +} +dependencies { + implementation 'com.google.apis:google-api-services-auditmanager:v1-rev20260826-2.0.0' +} +``` + +[javadoc]: https://googleapis.dev/java/google-api-services-auditmanager/latest/index.html +[google-api-client]: https://github.com/googleapis/google-api-java-client/ +[api-explorer]: https://developers.google.com/apis-explorer/#p/auditmanager/v1/ diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManager.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManager.java new file mode 100644 index 00000000000..5bf412dfd4f --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManager.java @@ -0,0 +1,7351 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1; + +/** + * Service definition for CloudAuditManager (v1). + * + *

+ * The Audit Manager API allows customers to manage compliance audits. + *

+ * + *

+ * For more information about this service, see the + * API Documentation + *

+ * + *

+ * This service uses {@link CloudAuditManagerRequestInitializer} to initialize global parameters via its + * {@link Builder}. + *

+ * + * @since 1.3 + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public class CloudAuditManager extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient { + + // Note: Leave this static initializer at the top of the file. + static { + com.google.api.client.util.Preconditions.checkState( + (com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION == 1 && + (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION >= 32 || + (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION == 31 && + com.google.api.client.googleapis.GoogleUtils.BUGFIX_VERSION >= 1))) || + com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION >= 2, + "You are currently running with version %s of google-api-client. " + + "You need at least version 1.31.1 of google-api-client to run version " + + "2.0.0 of the Audit Manager API library.", com.google.api.client.googleapis.GoogleUtils.VERSION); + } + + /** + * The default encoded root URL of the service. This is determined when the library is generated + * and normally should not be changed. + * + * @since 1.7 + */ + public static final String DEFAULT_ROOT_URL = "https://auditmanager.googleapis.com/"; + + /** + * The default encoded mTLS root URL of the service. This is determined when the library is generated + * and normally should not be changed. + * + * @since 1.31 + */ + public static final String DEFAULT_MTLS_ROOT_URL = "https://auditmanager.mtls.googleapis.com/"; + + /** + * The default encoded service path of the service. This is determined when the library is + * generated and normally should not be changed. + * + * @since 1.7 + */ + public static final String DEFAULT_SERVICE_PATH = ""; + + /** + * The default encoded batch path of the service. This is determined when the library is + * generated and normally should not be changed. + * + * @since 1.23 + */ + public static final String DEFAULT_BATCH_PATH = "batch"; + + /** + * The default encoded base URL of the service. This is determined when the library is generated + * and normally should not be changed. + */ + public static final String DEFAULT_BASE_URL = DEFAULT_ROOT_URL + DEFAULT_SERVICE_PATH; + + /** + * Constructor. + * + *

+ * Use {@link Builder} if you need to specify any of the optional parameters. + *

+ * + * @param transport HTTP transport, which should normally be: + * + * @param jsonFactory JSON factory, which may be: + * + * @param httpRequestInitializer HTTP request initializer or {@code null} for none + * @since 1.7 + */ + public CloudAuditManager(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, + com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + this(new Builder(transport, jsonFactory, httpRequestInitializer)); + } + + /** + * @param builder builder + */ + CloudAuditManager(Builder builder) { + super(builder); + } + + @Override + protected void initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest httpClientRequest) throws java.io.IOException { + super.initialize(httpClientRequest); + } + + /** + * An accessor for creating requests from the Folders collection. + * + *

The typical use is:

+ *
+   *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+   *   {@code CloudAuditManager.Folders.List request = auditmanager.folders().list(parameters ...)}
+   * 
+ * + * @return the resource collection + */ + public Folders folders() { + return new Folders(); + } + + /** + * The "folders" collection of methods. + */ + public class Folders { + + /** + * An accessor for creating requests from the Locations collection. + * + *

The typical use is:

+ *
+     *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+     *   {@code CloudAuditManager.Locations.List request = auditmanager.locations().list(parameters ...)}
+     * 
+ * + * @return the resource collection + */ + public Locations locations() { + return new Locations(); + } + + /** + * The "locations" collection of methods. + */ + public class Locations { + + /** + * Adds your project, folder, or organization to Audit Manager. This method creates the Audit + * Manager service agent in your workload and grants required permissions to the service agent. If + * you make this request on a workload that's already enrolled, then this method overrides the + * existing set of destinations. + * + * Create a request for the method "locations.enrollResource". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link EnrollResource#execute()} method to invoke the remote operation. + * + * @param scope Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.EnrollResourceRequest} + * @return the request + */ + public EnrollResource enrollResource(java.lang.String scope, com.google.api.services.auditmanager.v1.model.EnrollResourceRequest content) throws java.io.IOException { + EnrollResource result = new EnrollResource(scope, content); + initialize(result); + return result; + } + + public class EnrollResource extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}:enrollResource"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+$"); + + /** + * Adds your project, folder, or organization to Audit Manager. This method creates the Audit + * Manager service agent in your workload and grants required permissions to the service agent. If + * you make this request on a workload that's already enrolled, then this method overrides the + * existing set of destinations. + * + * Create a request for the method "locations.enrollResource". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link EnrollResource#execute()} method to invoke the remote + * operation.

{@link EnrollResource#initialize(com.google.api.client.googleapis.services.Abstr + * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking + * the constructor.

+ * + * @param scope Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.EnrollResourceRequest} + * @since 1.13 + */ + protected EnrollResource(java.lang.String scope, com.google.api.services.auditmanager.v1.model.EnrollResourceRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Enrollment.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + } + + @Override + public EnrollResource set$Xgafv(java.lang.String $Xgafv) { + return (EnrollResource) super.set$Xgafv($Xgafv); + } + + @Override + public EnrollResource setAccessToken(java.lang.String accessToken) { + return (EnrollResource) super.setAccessToken(accessToken); + } + + @Override + public EnrollResource setAlt(java.lang.String alt) { + return (EnrollResource) super.setAlt(alt); + } + + @Override + public EnrollResource setCallback(java.lang.String callback) { + return (EnrollResource) super.setCallback(callback); + } + + @Override + public EnrollResource setFields(java.lang.String fields) { + return (EnrollResource) super.setFields(fields); + } + + @Override + public EnrollResource setKey(java.lang.String key) { + return (EnrollResource) super.setKey(key); + } + + @Override + public EnrollResource setOauthToken(java.lang.String oauthToken) { + return (EnrollResource) super.setOauthToken(oauthToken); + } + + @Override + public EnrollResource setPrettyPrint(java.lang.Boolean prettyPrint) { + return (EnrollResource) super.setPrettyPrint(prettyPrint); + } + + @Override + public EnrollResource setQuotaUser(java.lang.String quotaUser) { + return (EnrollResource) super.setQuotaUser(quotaUser); + } + + @Override + public EnrollResource setUploadType(java.lang.String uploadType) { + return (EnrollResource) super.setUploadType(uploadType); + } + + @Override + public EnrollResource setUploadProtocol(java.lang.String uploadProtocol) { + return (EnrollResource) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Organization, folder, or project to enroll in Audit Manager, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Organization, folder, or project to enroll in Audit Manager, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public EnrollResource setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public EnrollResource set(String parameterName, Object value) { + return (EnrollResource) super.set(parameterName, value); + } + } + + /** + * An accessor for creating requests from the AuditReports collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.AuditReports.List request = auditmanager.auditReports().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuditReports auditReports() { + return new AuditReports(); + } + + /** + * The "auditReports" collection of methods. + */ + public class AuditReports { + + /** + * Registers audit report generation requests. This method returns the operation identifier that you + * can use to track the report generation progress. + * + * Create a request for the method "auditReports.generate". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Generate#execute()} method to invoke the remote operation. + * + * @param scope Required. Organization, folder, or project that the audit applies to, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest} + * @return the request + */ + public Generate generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest content) throws java.io.IOException { + Generate result = new Generate(scope, content); + initialize(result); + return result; + } + + public class Generate extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}/auditReports:generate"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+$"); + + /** + * Registers audit report generation requests. This method returns the operation identifier that + * you can use to track the report generation progress. + * + * Create a request for the method "auditReports.generate". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Generate#execute()} method to invoke the remote operation. + *

{@link + * Generate#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param scope Required. Organization, folder, or project that the audit applies to, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest} + * @since 1.13 + */ + protected Generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Operation.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + } + + @Override + public Generate set$Xgafv(java.lang.String $Xgafv) { + return (Generate) super.set$Xgafv($Xgafv); + } + + @Override + public Generate setAccessToken(java.lang.String accessToken) { + return (Generate) super.setAccessToken(accessToken); + } + + @Override + public Generate setAlt(java.lang.String alt) { + return (Generate) super.setAlt(alt); + } + + @Override + public Generate setCallback(java.lang.String callback) { + return (Generate) super.setCallback(callback); + } + + @Override + public Generate setFields(java.lang.String fields) { + return (Generate) super.setFields(fields); + } + + @Override + public Generate setKey(java.lang.String key) { + return (Generate) super.setKey(key); + } + + @Override + public Generate setOauthToken(java.lang.String oauthToken) { + return (Generate) super.setOauthToken(oauthToken); + } + + @Override + public Generate setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Generate) super.setPrettyPrint(prettyPrint); + } + + @Override + public Generate setQuotaUser(java.lang.String quotaUser) { + return (Generate) super.setQuotaUser(quotaUser); + } + + @Override + public Generate setUploadType(java.lang.String uploadType) { + return (Generate) super.setUploadType(uploadType); + } + + @Override + public Generate setUploadProtocol(java.lang.String uploadProtocol) { + return (Generate) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Organization, folder, or project that the audit applies to, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Organization, folder, or project that the audit applies to, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Organization, folder, or project that the audit applies to, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public Generate setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public Generate set(String parameterName, Object value) { + return (Generate) super.set(parameterName, value); + } + } + /** + * Gets the full metadata and findings for an audit report. + * + * Create a request for the method "auditReports.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + + /** + * Gets the full metadata and findings for an audit report. + * + * Create a request for the method "auditReports.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.AuditReport.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. Name of the audit report, in one of the following formats: * + `projects/{project}/locations/{location}/auditReports/{audit_report}` * + `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + public java.lang.String getName() { + return name; + } + + /** + * Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists the audit reports for the organization, folder, or project that you specify as the parent + * scope. + * + * Create a request for the method "auditReports.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Parent organization, folder, or project to list reports for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/auditReports"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+$"); + + /** + * Lists the audit reports for the organization, folder, or project that you specify as the parent + * scope. + * + * Create a request for the method "auditReports.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Parent organization, folder, or project to list reports for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListAuditReportsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Parent organization, folder, or project to list reports for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Parent organization, folder, or project to list reports for, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Parent organization, folder, or project to list reports for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the AuditScopeReports collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.AuditScopeReports.List request = auditmanager.auditScopeReports().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuditScopeReports auditScopeReports() { + return new AuditScopeReports(); + } + + /** + * The "auditScopeReports" collection of methods. + */ + public class AuditScopeReports { + + /** + * Generates an audit scope report for the given standard. The report includes the following: * The + * technical attributes and constraints that Audit Manager uses to verify your compliance with a + * framework. * A list of Google Cloud services and resources that are within the scope of the + * framework. + * + * Create a request for the method "auditScopeReports.generate". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Generate#execute()} method to invoke the remote operation. + * + * @param scope Required. Project or folder that the audit scope report is generated for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest} + * @return the request + */ + public Generate generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest content) throws java.io.IOException { + Generate result = new Generate(scope, content); + initialize(result); + return result; + } + + public class Generate extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}/auditScopeReports:generate"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+$"); + + /** + * Generates an audit scope report for the given standard. The report includes the following: * + * The technical attributes and constraints that Audit Manager uses to verify your compliance with + * a framework. * A list of Google Cloud services and resources that are within the scope of the + * framework. + * + * Create a request for the method "auditScopeReports.generate". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Generate#execute()} method to invoke the remote operation. + *

{@link + * Generate#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param scope Required. Project or folder that the audit scope report is generated for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest} + * @since 1.13 + */ + protected Generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.AuditScopeReport.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + } + + @Override + public Generate set$Xgafv(java.lang.String $Xgafv) { + return (Generate) super.set$Xgafv($Xgafv); + } + + @Override + public Generate setAccessToken(java.lang.String accessToken) { + return (Generate) super.setAccessToken(accessToken); + } + + @Override + public Generate setAlt(java.lang.String alt) { + return (Generate) super.setAlt(alt); + } + + @Override + public Generate setCallback(java.lang.String callback) { + return (Generate) super.setCallback(callback); + } + + @Override + public Generate setFields(java.lang.String fields) { + return (Generate) super.setFields(fields); + } + + @Override + public Generate setKey(java.lang.String key) { + return (Generate) super.setKey(key); + } + + @Override + public Generate setOauthToken(java.lang.String oauthToken) { + return (Generate) super.setOauthToken(oauthToken); + } + + @Override + public Generate setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Generate) super.setPrettyPrint(prettyPrint); + } + + @Override + public Generate setQuotaUser(java.lang.String quotaUser) { + return (Generate) super.setQuotaUser(quotaUser); + } + + @Override + public Generate setUploadType(java.lang.String uploadType) { + return (Generate) super.setUploadType(uploadType); + } + + @Override + public Generate setUploadProtocol(java.lang.String uploadProtocol) { + return (Generate) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Project or folder that the audit scope report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Project or folder that the audit scope report is generated for, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Project or folder that the audit scope report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public Generate setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public Generate set(String parameterName, Object value) { + return (Generate) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the OperationDetails collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.OperationDetails.List request = auditmanager.operationDetails().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public OperationDetails operationDetails() { + return new OperationDetails(); + } + + /** + * The "operationDetails" collection of methods. + */ + public class OperationDetails { + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationDetails.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationDetails.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the OperationIds collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.OperationIds.List request = auditmanager.operationIds().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public OperationIds operationIds() { + return new OperationIds(); + } + + /** + * The "operationIds" collection of methods. + */ + public class OperationIds { + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationIds.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationIds.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the ResourceEnrollmentStatuses collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.ResourceEnrollmentStatuses.List request = auditmanager.resourceEnrollmentStatuses().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public ResourceEnrollmentStatuses resourceEnrollmentStatuses() { + return new ResourceEnrollmentStatuses(); + } + + /** + * The "resourceEnrollmentStatuses" collection of methods. + */ + public class ResourceEnrollmentStatuses { + + /** + * Gets a resource and its enrollment status. + * + * Create a request for the method "resourceEnrollmentStatuses.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_sta + * tus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enro + * llment_status}` * `organizations/{organization}/locations/{location}/resourceEnrollmentSta + * tuses/{resource_enrollment_status}` + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + + /** + * Gets a resource and its enrollment status. + * + * Create a request for the method "resourceEnrollmentStatuses.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_sta + * tus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enro + * llment_status}` * `organizations/{organization}/locations/{location}/resourceEnrollmentSta + * tuses/{resource_enrollment_status}` + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ResourceEnrollmentStatus.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Name of the resource enrollment status, in one of the following formats: * `f + * olders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_st + * atus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` * `organizations/{organization}/locations/{location}/resourceEnroll + * mentStatuses/{resource_enrollment_status}` + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. Name of the resource enrollment status, in one of the following formats: * + `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` * + `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` * + `organizations/{organization}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_ + status}` + */ + public java.lang.String getName() { + return name; + } + + /** + * Required. Name of the resource enrollment status, in one of the following formats: * `f + * olders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_st + * atus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` * `organizations/{organization}/locations/{location}/resourceEnroll + * mentStatuses/{resource_enrollment_status}` + */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists all the folders and projects in an organization or folder, along with their enrollments. + * + * Create a request for the method "resourceEnrollmentStatuses.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Parent organization or folder to list enrollment statuses for, in one of the following + * formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/resourceEnrollmentStatuses"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+$"); + + /** + * Lists all the folders and projects in an organization or folder, along with their enrollments. + * + * Create a request for the method "resourceEnrollmentStatuses.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Parent organization or folder to list enrollment statuses for, in one of the following + * formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListResourceEnrollmentStatusesResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Parent organization or folder to list enrollment statuses for, in one of the + * following formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Parent organization or folder to list enrollment statuses for, in one of the following + formats: * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Parent organization or folder to list enrollment statuses for, in one of the + * following formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the Standards collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.Standards.List request = auditmanager.standards().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public Standards standards() { + return new Standards(); + } + + /** + * The "standards" collection of methods. + */ + public class Standards { + + /** + * An accessor for creating requests from the Controls collection. + * + *

The typical use is:

+ *
+         *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+         *   {@code CloudAuditManager.Controls.List request = auditmanager.controls().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Controls controls() { + return new Controls(); + } + + /** + * The "controls" collection of methods. + */ + public class Controls { + + /** + * Lists the controls that you must implement to become compliant to a regulatory standard. + * + * Create a request for the method "controls.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/controls"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/standards/[^/]+$"); + + /** + * Lists the controls that you must implement to become compliant to a regulatory standard. + * + * Create a request for the method "controls.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListControlsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/standards/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Standard to list controls for, in one of the following formats: * + `projects/{project}/locations/{location}/standards/{standard}` * + `folders/{folder}/locations/{location}/standards/{standard}` * + `organizations/{organization}/locations/{location}/standards/{standard}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^folders/[^/]+/locations/[^/]+/standards/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might + * return fewer items than this value. If unspecified, the service picks an appropriate + * default. The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might + * return fewer items than this value. If unspecified, the service picks an appropriate + * default. The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + } + } + } + + /** + * An accessor for creating requests from the Organizations collection. + * + *

The typical use is:

+ *
+   *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+   *   {@code CloudAuditManager.Organizations.List request = auditmanager.organizations().list(parameters ...)}
+   * 
+ * + * @return the resource collection + */ + public Organizations organizations() { + return new Organizations(); + } + + /** + * The "organizations" collection of methods. + */ + public class Organizations { + + /** + * An accessor for creating requests from the Locations collection. + * + *

The typical use is:

+ *
+     *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+     *   {@code CloudAuditManager.Locations.List request = auditmanager.locations().list(parameters ...)}
+     * 
+ * + * @return the resource collection + */ + public Locations locations() { + return new Locations(); + } + + /** + * The "locations" collection of methods. + */ + public class Locations { + + /** + * Adds your project, folder, or organization to Audit Manager. This method creates the Audit + * Manager service agent in your workload and grants required permissions to the service agent. If + * you make this request on a workload that's already enrolled, then this method overrides the + * existing set of destinations. + * + * Create a request for the method "locations.enrollResource". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link EnrollResource#execute()} method to invoke the remote operation. + * + * @param scope Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.EnrollResourceRequest} + * @return the request + */ + public EnrollResource enrollResource(java.lang.String scope, com.google.api.services.auditmanager.v1.model.EnrollResourceRequest content) throws java.io.IOException { + EnrollResource result = new EnrollResource(scope, content); + initialize(result); + return result; + } + + public class EnrollResource extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}:enrollResource"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+$"); + + /** + * Adds your project, folder, or organization to Audit Manager. This method creates the Audit + * Manager service agent in your workload and grants required permissions to the service agent. If + * you make this request on a workload that's already enrolled, then this method overrides the + * existing set of destinations. + * + * Create a request for the method "locations.enrollResource". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link EnrollResource#execute()} method to invoke the remote + * operation.

{@link EnrollResource#initialize(com.google.api.client.googleapis.services.Abstr + * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking + * the constructor.

+ * + * @param scope Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.EnrollResourceRequest} + * @since 1.13 + */ + protected EnrollResource(java.lang.String scope, com.google.api.services.auditmanager.v1.model.EnrollResourceRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Enrollment.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + } + + @Override + public EnrollResource set$Xgafv(java.lang.String $Xgafv) { + return (EnrollResource) super.set$Xgafv($Xgafv); + } + + @Override + public EnrollResource setAccessToken(java.lang.String accessToken) { + return (EnrollResource) super.setAccessToken(accessToken); + } + + @Override + public EnrollResource setAlt(java.lang.String alt) { + return (EnrollResource) super.setAlt(alt); + } + + @Override + public EnrollResource setCallback(java.lang.String callback) { + return (EnrollResource) super.setCallback(callback); + } + + @Override + public EnrollResource setFields(java.lang.String fields) { + return (EnrollResource) super.setFields(fields); + } + + @Override + public EnrollResource setKey(java.lang.String key) { + return (EnrollResource) super.setKey(key); + } + + @Override + public EnrollResource setOauthToken(java.lang.String oauthToken) { + return (EnrollResource) super.setOauthToken(oauthToken); + } + + @Override + public EnrollResource setPrettyPrint(java.lang.Boolean prettyPrint) { + return (EnrollResource) super.setPrettyPrint(prettyPrint); + } + + @Override + public EnrollResource setQuotaUser(java.lang.String quotaUser) { + return (EnrollResource) super.setQuotaUser(quotaUser); + } + + @Override + public EnrollResource setUploadType(java.lang.String uploadType) { + return (EnrollResource) super.setUploadType(uploadType); + } + + @Override + public EnrollResource setUploadProtocol(java.lang.String uploadProtocol) { + return (EnrollResource) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Organization, folder, or project to enroll in Audit Manager, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Organization, folder, or project to enroll in Audit Manager, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public EnrollResource setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public EnrollResource set(String parameterName, Object value) { + return (EnrollResource) super.set(parameterName, value); + } + } + + /** + * An accessor for creating requests from the AuditReports collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.AuditReports.List request = auditmanager.auditReports().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuditReports auditReports() { + return new AuditReports(); + } + + /** + * The "auditReports" collection of methods. + */ + public class AuditReports { + + /** + * Registers audit report generation requests. This method returns the operation identifier that you + * can use to track the report generation progress. + * + * Create a request for the method "auditReports.generate". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Generate#execute()} method to invoke the remote operation. + * + * @param scope Required. Organization, folder, or project that the audit applies to, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest} + * @return the request + */ + public Generate generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest content) throws java.io.IOException { + Generate result = new Generate(scope, content); + initialize(result); + return result; + } + + public class Generate extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}/auditReports:generate"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+$"); + + /** + * Registers audit report generation requests. This method returns the operation identifier that + * you can use to track the report generation progress. + * + * Create a request for the method "auditReports.generate". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Generate#execute()} method to invoke the remote operation. + *

{@link + * Generate#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param scope Required. Organization, folder, or project that the audit applies to, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest} + * @since 1.13 + */ + protected Generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Operation.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + } + + @Override + public Generate set$Xgafv(java.lang.String $Xgafv) { + return (Generate) super.set$Xgafv($Xgafv); + } + + @Override + public Generate setAccessToken(java.lang.String accessToken) { + return (Generate) super.setAccessToken(accessToken); + } + + @Override + public Generate setAlt(java.lang.String alt) { + return (Generate) super.setAlt(alt); + } + + @Override + public Generate setCallback(java.lang.String callback) { + return (Generate) super.setCallback(callback); + } + + @Override + public Generate setFields(java.lang.String fields) { + return (Generate) super.setFields(fields); + } + + @Override + public Generate setKey(java.lang.String key) { + return (Generate) super.setKey(key); + } + + @Override + public Generate setOauthToken(java.lang.String oauthToken) { + return (Generate) super.setOauthToken(oauthToken); + } + + @Override + public Generate setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Generate) super.setPrettyPrint(prettyPrint); + } + + @Override + public Generate setQuotaUser(java.lang.String quotaUser) { + return (Generate) super.setQuotaUser(quotaUser); + } + + @Override + public Generate setUploadType(java.lang.String uploadType) { + return (Generate) super.setUploadType(uploadType); + } + + @Override + public Generate setUploadProtocol(java.lang.String uploadProtocol) { + return (Generate) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Organization, folder, or project that the audit applies to, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Organization, folder, or project that the audit applies to, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Organization, folder, or project that the audit applies to, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public Generate setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public Generate set(String parameterName, Object value) { + return (Generate) super.set(parameterName, value); + } + } + /** + * Gets the full metadata and findings for an audit report. + * + * Create a request for the method "auditReports.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + + /** + * Gets the full metadata and findings for an audit report. + * + * Create a request for the method "auditReports.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.AuditReport.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. Name of the audit report, in one of the following formats: * + `projects/{project}/locations/{location}/auditReports/{audit_report}` * + `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + public java.lang.String getName() { + return name; + } + + /** + * Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists the audit reports for the organization, folder, or project that you specify as the parent + * scope. + * + * Create a request for the method "auditReports.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Parent organization, folder, or project to list reports for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/auditReports"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+$"); + + /** + * Lists the audit reports for the organization, folder, or project that you specify as the parent + * scope. + * + * Create a request for the method "auditReports.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Parent organization, folder, or project to list reports for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListAuditReportsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Parent organization, folder, or project to list reports for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Parent organization, folder, or project to list reports for, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Parent organization, folder, or project to list reports for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the AuditScopeReports collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.AuditScopeReports.List request = auditmanager.auditScopeReports().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuditScopeReports auditScopeReports() { + return new AuditScopeReports(); + } + + /** + * The "auditScopeReports" collection of methods. + */ + public class AuditScopeReports { + + /** + * Generates an audit scope report for the given standard. The report includes the following: * The + * technical attributes and constraints that Audit Manager uses to verify your compliance with a + * framework. * A list of Google Cloud services and resources that are within the scope of the + * framework. + * + * Create a request for the method "auditScopeReports.generate". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Generate#execute()} method to invoke the remote operation. + * + * @param scope Required. Project or folder that the audit scope report is generated for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest} + * @return the request + */ + public Generate generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest content) throws java.io.IOException { + Generate result = new Generate(scope, content); + initialize(result); + return result; + } + + public class Generate extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}/auditScopeReports:generate"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+$"); + + /** + * Generates an audit scope report for the given standard. The report includes the following: * + * The technical attributes and constraints that Audit Manager uses to verify your compliance with + * a framework. * A list of Google Cloud services and resources that are within the scope of the + * framework. + * + * Create a request for the method "auditScopeReports.generate". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Generate#execute()} method to invoke the remote operation. + *

{@link + * Generate#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param scope Required. Project or folder that the audit scope report is generated for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest} + * @since 1.13 + */ + protected Generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.AuditScopeReport.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + } + + @Override + public Generate set$Xgafv(java.lang.String $Xgafv) { + return (Generate) super.set$Xgafv($Xgafv); + } + + @Override + public Generate setAccessToken(java.lang.String accessToken) { + return (Generate) super.setAccessToken(accessToken); + } + + @Override + public Generate setAlt(java.lang.String alt) { + return (Generate) super.setAlt(alt); + } + + @Override + public Generate setCallback(java.lang.String callback) { + return (Generate) super.setCallback(callback); + } + + @Override + public Generate setFields(java.lang.String fields) { + return (Generate) super.setFields(fields); + } + + @Override + public Generate setKey(java.lang.String key) { + return (Generate) super.setKey(key); + } + + @Override + public Generate setOauthToken(java.lang.String oauthToken) { + return (Generate) super.setOauthToken(oauthToken); + } + + @Override + public Generate setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Generate) super.setPrettyPrint(prettyPrint); + } + + @Override + public Generate setQuotaUser(java.lang.String quotaUser) { + return (Generate) super.setQuotaUser(quotaUser); + } + + @Override + public Generate setUploadType(java.lang.String uploadType) { + return (Generate) super.setUploadType(uploadType); + } + + @Override + public Generate setUploadProtocol(java.lang.String uploadProtocol) { + return (Generate) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Project or folder that the audit scope report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Project or folder that the audit scope report is generated for, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Project or folder that the audit scope report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public Generate setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public Generate set(String parameterName, Object value) { + return (Generate) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the OperationDetails collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.OperationDetails.List request = auditmanager.operationDetails().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public OperationDetails operationDetails() { + return new OperationDetails(); + } + + /** + * The "operationDetails" collection of methods. + */ + public class OperationDetails { + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationDetails.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationDetails.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the OperationIds collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.OperationIds.List request = auditmanager.operationIds().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public OperationIds operationIds() { + return new OperationIds(); + } + + /** + * The "operationIds" collection of methods. + */ + public class OperationIds { + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationIds.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationIds.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the Operations collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.Operations.List request = auditmanager.operations().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public Operations operations() { + return new Operations(); + } + + /** + * The "operations" collection of methods. + */ + public class Operations { + + /** + * Starts asynchronous cancellation on a long-running operation. The server makes a best effort to + * cancel the operation, but success is not guaranteed. If the server doesn't support this method, + * it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other + * methods to check whether the cancellation succeeded or whether the operation completed despite + * cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an + * operation with an Operation.error value with a google.rpc.Status.code of `1`, corresponding to + * `Code.CANCELLED`. + * + * Create a request for the method "operations.cancel". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Cancel#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource to be cancelled. + * @param content the {@link com.google.api.services.auditmanager.v1.model.CancelOperationRequest} + * @return the request + */ + public Cancel cancel(java.lang.String name, com.google.api.services.auditmanager.v1.model.CancelOperationRequest content) throws java.io.IOException { + Cancel result = new Cancel(name, content); + initialize(result); + return result; + } + + public class Cancel extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}:cancel"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + + /** + * Starts asynchronous cancellation on a long-running operation. The server makes a best effort to + * cancel the operation, but success is not guaranteed. If the server doesn't support this method, + * it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other + * methods to check whether the cancellation succeeded or whether the operation completed despite + * cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an + * operation with an Operation.error value with a google.rpc.Status.code of `1`, corresponding to + * `Code.CANCELLED`. + * + * Create a request for the method "operations.cancel". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Cancel#execute()} method to invoke the remote operation. + *

{@link + * Cancel#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource to be cancelled. + * @param content the {@link com.google.api.services.auditmanager.v1.model.CancelOperationRequest} + * @since 1.13 + */ + protected Cancel(java.lang.String name, com.google.api.services.auditmanager.v1.model.CancelOperationRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Empty.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + } + + @Override + public Cancel set$Xgafv(java.lang.String $Xgafv) { + return (Cancel) super.set$Xgafv($Xgafv); + } + + @Override + public Cancel setAccessToken(java.lang.String accessToken) { + return (Cancel) super.setAccessToken(accessToken); + } + + @Override + public Cancel setAlt(java.lang.String alt) { + return (Cancel) super.setAlt(alt); + } + + @Override + public Cancel setCallback(java.lang.String callback) { + return (Cancel) super.setCallback(callback); + } + + @Override + public Cancel setFields(java.lang.String fields) { + return (Cancel) super.setFields(fields); + } + + @Override + public Cancel setKey(java.lang.String key) { + return (Cancel) super.setKey(key); + } + + @Override + public Cancel setOauthToken(java.lang.String oauthToken) { + return (Cancel) super.setOauthToken(oauthToken); + } + + @Override + public Cancel setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Cancel) super.setPrettyPrint(prettyPrint); + } + + @Override + public Cancel setQuotaUser(java.lang.String quotaUser) { + return (Cancel) super.setQuotaUser(quotaUser); + } + + @Override + public Cancel setUploadType(java.lang.String uploadType) { + return (Cancel) super.setUploadType(uploadType); + } + + @Override + public Cancel setUploadProtocol(java.lang.String uploadProtocol) { + return (Cancel) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource to be cancelled. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource to be cancelled. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource to be cancelled. */ + public Cancel setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Cancel set(String parameterName, Object value) { + return (Cancel) super.set(parameterName, value); + } + } + /** + * Deletes a long-running operation. This method indicates that the client is no longer interested + * in the operation result. It does not cancel the operation. If the server doesn't support this + * method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * + * Create a request for the method "operations.delete". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource to be deleted. + * @return the request + */ + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); + initialize(result); + return result; + } + + public class Delete extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + + /** + * Deletes a long-running operation. This method indicates that the client is no longer interested + * in the operation result. It does not cancel the operation. If the server doesn't support this + * method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * + * Create a request for the method "operations.delete". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource to be deleted. + * @since 1.13 + */ + protected Delete(java.lang.String name) { + super(CloudAuditManager.this, "DELETE", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Empty.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + } + + @Override + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); + } + + @Override + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); + } + + @Override + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); + } + + @Override + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); + } + + @Override + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); + } + + @Override + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); + } + + @Override + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); + } + + @Override + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); + } + + @Override + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); + } + + @Override + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); + } + + @Override + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource to be deleted. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource to be deleted. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource to be deleted. */ + public Delete setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); + } + } + /** + * Gets the latest state of a long-running operation. Clients can use this method to poll the + * operation result at intervals as recommended by the API service. + * + * Create a request for the method "operations.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + + /** + * Gets the latest state of a long-running operation. Clients can use this method to poll the + * operation result at intervals as recommended by the API service. + * + * Create a request for the method "operations.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists operations that match the specified filter in the request. If the server doesn't support + * this method, it returns `UNIMPLEMENTED`. + * + * Create a request for the method "operations.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param name The name of the operation's parent resource. + * @return the request + */ + public List list(java.lang.String name) throws java.io.IOException { + List result = new List(name); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}/operations"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+$"); + + /** + * Lists operations that match the specified filter in the request. If the server doesn't support + * this method, it returns `UNIMPLEMENTED`. + * + * Create a request for the method "operations.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation's parent resource. + * @since 1.13 + */ + protected List(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListOperationsResponse.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation's parent resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation's parent resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation's parent resource. */ + public List setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + this.name = name; + return this; + } + + /** The standard list filter. */ + @com.google.api.client.util.Key + private java.lang.String filter; + + /** The standard list filter. + */ + public java.lang.String getFilter() { + return filter; + } + + /** The standard list filter. */ + public List setFilter(java.lang.String filter) { + this.filter = filter; + return this; + } + + /** The standard list page size. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The standard list page size. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The standard list page size. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The standard list page token. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The standard list page token. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** The standard list page token. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + /** + * When set to `true`, operations that are reachable are returned as normal, and those + * that are unreachable are returned in the ListOperationsResponse.unreachable field. This + * can only be `true` when reading across collections. For example, when `parent` is set + * to `"projects/example/locations/-"`. This field is not supported by default and will + * result in an `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + * service or product specific documentation. + */ + @com.google.api.client.util.Key + private java.lang.Boolean returnPartialSuccess; + + /** When set to `true`, operations that are reachable are returned as normal, and those that are + unreachable are returned in the ListOperationsResponse.unreachable field. This can only be `true` + when reading across collections. For example, when `parent` is set to + `"projects/example/locations/-"`. This field is not supported by default and will result in an + `UNIMPLEMENTED` error if set unless explicitly documented otherwise in service or product specific + documentation. + */ + public java.lang.Boolean getReturnPartialSuccess() { + return returnPartialSuccess; + } + + /** + * When set to `true`, operations that are reachable are returned as normal, and those + * that are unreachable are returned in the ListOperationsResponse.unreachable field. This + * can only be `true` when reading across collections. For example, when `parent` is set + * to `"projects/example/locations/-"`. This field is not supported by default and will + * result in an `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + * service or product specific documentation. + */ + public List setReturnPartialSuccess(java.lang.Boolean returnPartialSuccess) { + this.returnPartialSuccess = returnPartialSuccess; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the ResourceEnrollmentStatuses collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.ResourceEnrollmentStatuses.List request = auditmanager.resourceEnrollmentStatuses().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public ResourceEnrollmentStatuses resourceEnrollmentStatuses() { + return new ResourceEnrollmentStatuses(); + } + + /** + * The "resourceEnrollmentStatuses" collection of methods. + */ + public class ResourceEnrollmentStatuses { + + /** + * Gets a resource and its enrollment status. + * + * Create a request for the method "resourceEnrollmentStatuses.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_sta + * tus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enro + * llment_status}` * `organizations/{organization}/locations/{location}/resourceEnrollmentSta + * tuses/{resource_enrollment_status}` + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + + /** + * Gets a resource and its enrollment status. + * + * Create a request for the method "resourceEnrollmentStatuses.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_sta + * tus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enro + * llment_status}` * `organizations/{organization}/locations/{location}/resourceEnrollmentSta + * tuses/{resource_enrollment_status}` + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ResourceEnrollmentStatus.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Name of the resource enrollment status, in one of the following formats: * `f + * olders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_st + * atus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` * `organizations/{organization}/locations/{location}/resourceEnroll + * mentStatuses/{resource_enrollment_status}` + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. Name of the resource enrollment status, in one of the following formats: * + `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` * + `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` * + `organizations/{organization}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_ + status}` + */ + public java.lang.String getName() { + return name; + } + + /** + * Required. Name of the resource enrollment status, in one of the following formats: * `f + * olders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_st + * atus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` * `organizations/{organization}/locations/{location}/resourceEnroll + * mentStatuses/{resource_enrollment_status}` + */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists all the folders and projects in an organization or folder, along with their enrollments. + * + * Create a request for the method "resourceEnrollmentStatuses.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Parent organization or folder to list enrollment statuses for, in one of the following + * formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/resourceEnrollmentStatuses"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+$"); + + /** + * Lists all the folders and projects in an organization or folder, along with their enrollments. + * + * Create a request for the method "resourceEnrollmentStatuses.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Parent organization or folder to list enrollment statuses for, in one of the following + * formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListResourceEnrollmentStatusesResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Parent organization or folder to list enrollment statuses for, in one of the + * following formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Parent organization or folder to list enrollment statuses for, in one of the following + formats: * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Parent organization or folder to list enrollment statuses for, in one of the + * following formats: * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the Standards collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.Standards.List request = auditmanager.standards().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public Standards standards() { + return new Standards(); + } + + /** + * The "standards" collection of methods. + */ + public class Standards { + + /** + * An accessor for creating requests from the Controls collection. + * + *

The typical use is:

+ *
+         *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+         *   {@code CloudAuditManager.Controls.List request = auditmanager.controls().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Controls controls() { + return new Controls(); + } + + /** + * The "controls" collection of methods. + */ + public class Controls { + + /** + * Lists the controls that you must implement to become compliant to a regulatory standard. + * + * Create a request for the method "controls.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/controls"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/standards/[^/]+$"); + + /** + * Lists the controls that you must implement to become compliant to a regulatory standard. + * + * Create a request for the method "controls.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListControlsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/standards/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Standard to list controls for, in one of the following formats: * + `projects/{project}/locations/{location}/standards/{standard}` * + `folders/{folder}/locations/{location}/standards/{standard}` * + `organizations/{organization}/locations/{location}/standards/{standard}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^organizations/[^/]+/locations/[^/]+/standards/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might + * return fewer items than this value. If unspecified, the service picks an appropriate + * default. The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might + * return fewer items than this value. If unspecified, the service picks an appropriate + * default. The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + } + } + } + + /** + * An accessor for creating requests from the Projects collection. + * + *

The typical use is:

+ *
+   *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+   *   {@code CloudAuditManager.Projects.List request = auditmanager.projects().list(parameters ...)}
+   * 
+ * + * @return the resource collection + */ + public Projects projects() { + return new Projects(); + } + + /** + * The "projects" collection of methods. + */ + public class Projects { + + /** + * An accessor for creating requests from the Locations collection. + * + *

The typical use is:

+ *
+     *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+     *   {@code CloudAuditManager.Locations.List request = auditmanager.locations().list(parameters ...)}
+     * 
+ * + * @return the resource collection + */ + public Locations locations() { + return new Locations(); + } + + /** + * The "locations" collection of methods. + */ + public class Locations { + + /** + * Adds your project, folder, or organization to Audit Manager. This method creates the Audit + * Manager service agent in your workload and grants required permissions to the service agent. If + * you make this request on a workload that's already enrolled, then this method overrides the + * existing set of destinations. + * + * Create a request for the method "locations.enrollResource". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link EnrollResource#execute()} method to invoke the remote operation. + * + * @param scope Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.EnrollResourceRequest} + * @return the request + */ + public EnrollResource enrollResource(java.lang.String scope, com.google.api.services.auditmanager.v1.model.EnrollResourceRequest content) throws java.io.IOException { + EnrollResource result = new EnrollResource(scope, content); + initialize(result); + return result; + } + + public class EnrollResource extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}:enrollResource"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); + + /** + * Adds your project, folder, or organization to Audit Manager. This method creates the Audit + * Manager service agent in your workload and grants required permissions to the service agent. If + * you make this request on a workload that's already enrolled, then this method overrides the + * existing set of destinations. + * + * Create a request for the method "locations.enrollResource". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link EnrollResource#execute()} method to invoke the remote + * operation.

{@link EnrollResource#initialize(com.google.api.client.googleapis.services.Abstr + * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking + * the constructor.

+ * + * @param scope Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.EnrollResourceRequest} + * @since 1.13 + */ + protected EnrollResource(java.lang.String scope, com.google.api.services.auditmanager.v1.model.EnrollResourceRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Enrollment.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + } + + @Override + public EnrollResource set$Xgafv(java.lang.String $Xgafv) { + return (EnrollResource) super.set$Xgafv($Xgafv); + } + + @Override + public EnrollResource setAccessToken(java.lang.String accessToken) { + return (EnrollResource) super.setAccessToken(accessToken); + } + + @Override + public EnrollResource setAlt(java.lang.String alt) { + return (EnrollResource) super.setAlt(alt); + } + + @Override + public EnrollResource setCallback(java.lang.String callback) { + return (EnrollResource) super.setCallback(callback); + } + + @Override + public EnrollResource setFields(java.lang.String fields) { + return (EnrollResource) super.setFields(fields); + } + + @Override + public EnrollResource setKey(java.lang.String key) { + return (EnrollResource) super.setKey(key); + } + + @Override + public EnrollResource setOauthToken(java.lang.String oauthToken) { + return (EnrollResource) super.setOauthToken(oauthToken); + } + + @Override + public EnrollResource setPrettyPrint(java.lang.Boolean prettyPrint) { + return (EnrollResource) super.setPrettyPrint(prettyPrint); + } + + @Override + public EnrollResource setQuotaUser(java.lang.String quotaUser) { + return (EnrollResource) super.setQuotaUser(quotaUser); + } + + @Override + public EnrollResource setUploadType(java.lang.String uploadType) { + return (EnrollResource) super.setUploadType(uploadType); + } + + @Override + public EnrollResource setUploadProtocol(java.lang.String uploadProtocol) { + return (EnrollResource) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Organization, folder, or project to enroll in Audit Manager, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Organization, folder, or project to enroll in Audit Manager, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Organization, folder, or project to enroll in Audit Manager, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public EnrollResource setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public EnrollResource set(String parameterName, Object value) { + return (EnrollResource) super.set(parameterName, value); + } + } + /** + * Gets information about a location. + * + * Create a request for the method "locations.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Resource name for the location. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); + + /** + * Gets information about a location. + * + * Create a request for the method "locations.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Resource name for the location. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Location.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** Resource name for the location. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Resource name for the location. + */ + public java.lang.String getName() { + return name; + } + + /** Resource name for the location. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists information about the supported locations for this service. This method lists locations + * based on the resource scope provided in the ListLocationsRequest.name field: * **Global + * locations**: If `name` is empty, the method lists the public locations available to all projects. + * * **Project-specific locations**: If `name` follows the format `projects/{project}`, the method + * lists locations visible to that specific project. This includes public, private, or other + * project-specific locations enabled for the project. For gRPC and client library implementations, + * the resource name is passed as the `name` field. For direct service calls, the resource name is + * incorporated into the request path based on the specific service implementation and version. + * + * Create a request for the method "locations.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param name The resource that owns the locations collection, if applicable. + * @return the request + */ + public List list(java.lang.String name) throws java.io.IOException { + List result = new List(name); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}/locations"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+$"); + + /** + * Lists information about the supported locations for this service. This method lists locations + * based on the resource scope provided in the ListLocationsRequest.name field: * **Global + * locations**: If `name` is empty, the method lists the public locations available to all + * projects. * **Project-specific locations**: If `name` follows the format `projects/{project}`, + * the method lists locations visible to that specific project. This includes public, private, or + * other project-specific locations enabled for the project. For gRPC and client library + * implementations, the resource name is passed as the `name` field. For direct service calls, the + * resource name is incorporated into the request path based on the specific service + * implementation and version. + * + * Create a request for the method "locations.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The resource that owns the locations collection, if applicable. + * @since 1.13 + */ + protected List(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListLocationsResponse.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** The resource that owns the locations collection, if applicable. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The resource that owns the locations collection, if applicable. + */ + public java.lang.String getName() { + return name; + } + + /** The resource that owns the locations collection, if applicable. */ + public List setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+$"); + } + this.name = name; + return this; + } + + /** + * Optional. Do not use this field unless explicitly documented otherwise. This is primarily + * for internal usage. + */ + @com.google.api.client.util.Key + private java.util.List extraLocationTypes; + + /** Optional. Do not use this field unless explicitly documented otherwise. This is primarily for + internal usage. + */ + public java.util.List getExtraLocationTypes() { + return extraLocationTypes; + } + + /** + * Optional. Do not use this field unless explicitly documented otherwise. This is primarily + * for internal usage. + */ + public List setExtraLocationTypes(java.util.List extraLocationTypes) { + this.extraLocationTypes = extraLocationTypes; + return this; + } + + /** + * A filter to narrow down results to a preferred subset. The filtering language accepts + * strings like `"displayName=tokyo"`, and is documented in more detail in + * [AIP-160](https://google.aip.dev/160). + */ + @com.google.api.client.util.Key + private java.lang.String filter; + + /** A filter to narrow down results to a preferred subset. The filtering language accepts strings like + `"displayName=tokyo"`, and is documented in more detail in [AIP-160](https://google.aip.dev/160). + */ + public java.lang.String getFilter() { + return filter; + } + + /** + * A filter to narrow down results to a preferred subset. The filtering language accepts + * strings like `"displayName=tokyo"`, and is documented in more detail in + * [AIP-160](https://google.aip.dev/160). + */ + public List setFilter(java.lang.String filter) { + this.filter = filter; + return this; + } + + /** The maximum number of results to return. If not set, the service selects a default. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of results to return. If not set, the service selects a default. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of results to return. If not set, the service selects a default. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * A page token received from the `next_page_token` field in the response. Send that page + * token to receive the subsequent page. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** A page token received from the `next_page_token` field in the response. Send that page token to + receive the subsequent page. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * A page token received from the `next_page_token` field in the response. Send that page + * token to receive the subsequent page. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + /** + * An accessor for creating requests from the AuditReports collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.AuditReports.List request = auditmanager.auditReports().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuditReports auditReports() { + return new AuditReports(); + } + + /** + * The "auditReports" collection of methods. + */ + public class AuditReports { + + /** + * Registers audit report generation requests. This method returns the operation identifier that you + * can use to track the report generation progress. + * + * Create a request for the method "auditReports.generate". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Generate#execute()} method to invoke the remote operation. + * + * @param scope Required. Organization, folder, or project that the audit applies to, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest} + * @return the request + */ + public Generate generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest content) throws java.io.IOException { + Generate result = new Generate(scope, content); + initialize(result); + return result; + } + + public class Generate extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}/auditReports:generate"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); + + /** + * Registers audit report generation requests. This method returns the operation identifier that + * you can use to track the report generation progress. + * + * Create a request for the method "auditReports.generate". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Generate#execute()} method to invoke the remote operation. + *

{@link + * Generate#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param scope Required. Organization, folder, or project that the audit applies to, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest} + * @since 1.13 + */ + protected Generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditReportRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Operation.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + } + + @Override + public Generate set$Xgafv(java.lang.String $Xgafv) { + return (Generate) super.set$Xgafv($Xgafv); + } + + @Override + public Generate setAccessToken(java.lang.String accessToken) { + return (Generate) super.setAccessToken(accessToken); + } + + @Override + public Generate setAlt(java.lang.String alt) { + return (Generate) super.setAlt(alt); + } + + @Override + public Generate setCallback(java.lang.String callback) { + return (Generate) super.setCallback(callback); + } + + @Override + public Generate setFields(java.lang.String fields) { + return (Generate) super.setFields(fields); + } + + @Override + public Generate setKey(java.lang.String key) { + return (Generate) super.setKey(key); + } + + @Override + public Generate setOauthToken(java.lang.String oauthToken) { + return (Generate) super.setOauthToken(oauthToken); + } + + @Override + public Generate setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Generate) super.setPrettyPrint(prettyPrint); + } + + @Override + public Generate setQuotaUser(java.lang.String quotaUser) { + return (Generate) super.setQuotaUser(quotaUser); + } + + @Override + public Generate setUploadType(java.lang.String uploadType) { + return (Generate) super.setUploadType(uploadType); + } + + @Override + public Generate setUploadProtocol(java.lang.String uploadProtocol) { + return (Generate) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Organization, folder, or project that the audit applies to, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Organization, folder, or project that the audit applies to, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Organization, folder, or project that the audit applies to, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public Generate setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public Generate set(String parameterName, Object value) { + return (Generate) super.set(parameterName, value); + } + } + /** + * Gets the full metadata and findings for an audit report. + * + * Create a request for the method "auditReports.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + + /** + * Gets the full metadata and findings for an audit report. + * + * Create a request for the method "auditReports.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.AuditReport.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. Name of the audit report, in one of the following formats: * + `projects/{project}/locations/{location}/auditReports/{audit_report}` * + `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + public java.lang.String getName() { + return name; + } + + /** + * Required. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/auditReports/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists the audit reports for the organization, folder, or project that you specify as the parent + * scope. + * + * Create a request for the method "auditReports.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Parent organization, folder, or project to list reports for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/auditReports"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); + + /** + * Lists the audit reports for the organization, folder, or project that you specify as the parent + * scope. + * + * Create a request for the method "auditReports.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Parent organization, folder, or project to list reports for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListAuditReportsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Parent organization, folder, or project to list reports for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Parent organization, folder, or project to list reports for, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Parent organization, folder, or project to list reports for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might return + * fewer items than this value. If unspecified, the service picks an appropriate default. + * The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the AuditScopeReports collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.AuditScopeReports.List request = auditmanager.auditScopeReports().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public AuditScopeReports auditScopeReports() { + return new AuditScopeReports(); + } + + /** + * The "auditScopeReports" collection of methods. + */ + public class AuditScopeReports { + + /** + * Generates an audit scope report for the given standard. The report includes the following: * The + * technical attributes and constraints that Audit Manager uses to verify your compliance with a + * framework. * A list of Google Cloud services and resources that are within the scope of the + * framework. + * + * Create a request for the method "auditScopeReports.generate". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Generate#execute()} method to invoke the remote operation. + * + * @param scope Required. Project or folder that the audit scope report is generated for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest} + * @return the request + */ + public Generate generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest content) throws java.io.IOException { + Generate result = new Generate(scope, content); + initialize(result); + return result; + } + + public class Generate extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+scope}/auditScopeReports:generate"; + + private final java.util.regex.Pattern SCOPE_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); + + /** + * Generates an audit scope report for the given standard. The report includes the following: * + * The technical attributes and constraints that Audit Manager uses to verify your compliance with + * a framework. * A list of Google Cloud services and resources that are within the scope of the + * framework. + * + * Create a request for the method "auditScopeReports.generate". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Generate#execute()} method to invoke the remote operation. + *

{@link + * Generate#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param scope Required. Project or folder that the audit scope report is generated for, in one of the following + * formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + * @param content the {@link com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest} + * @since 1.13 + */ + protected Generate(java.lang.String scope, com.google.api.services.auditmanager.v1.model.GenerateAuditScopeReportRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.AuditScopeReport.class); + this.scope = com.google.api.client.util.Preconditions.checkNotNull(scope, "Required parameter scope must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + } + + @Override + public Generate set$Xgafv(java.lang.String $Xgafv) { + return (Generate) super.set$Xgafv($Xgafv); + } + + @Override + public Generate setAccessToken(java.lang.String accessToken) { + return (Generate) super.setAccessToken(accessToken); + } + + @Override + public Generate setAlt(java.lang.String alt) { + return (Generate) super.setAlt(alt); + } + + @Override + public Generate setCallback(java.lang.String callback) { + return (Generate) super.setCallback(callback); + } + + @Override + public Generate setFields(java.lang.String fields) { + return (Generate) super.setFields(fields); + } + + @Override + public Generate setKey(java.lang.String key) { + return (Generate) super.setKey(key); + } + + @Override + public Generate setOauthToken(java.lang.String oauthToken) { + return (Generate) super.setOauthToken(oauthToken); + } + + @Override + public Generate setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Generate) super.setPrettyPrint(prettyPrint); + } + + @Override + public Generate setQuotaUser(java.lang.String quotaUser) { + return (Generate) super.setQuotaUser(quotaUser); + } + + @Override + public Generate setUploadType(java.lang.String uploadType) { + return (Generate) super.setUploadType(uploadType); + } + + @Override + public Generate setUploadProtocol(java.lang.String uploadProtocol) { + return (Generate) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Project or folder that the audit scope report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** Required. Project or folder that the audit scope report is generated for, in one of the following + formats: * `projects/{project}/locations/{location}` * `folders/{folder}/locations/{location}` * + `organizations/{organization}/locations/{location}` + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Required. Project or folder that the audit scope report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * + * `organizations/{organization}/locations/{location}` + */ + public Generate setScope(java.lang.String scope) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(SCOPE_PATTERN.matcher(scope).matches(), + "Parameter scope must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + this.scope = scope; + return this; + } + + @Override + public Generate set(String parameterName, Object value) { + return (Generate) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the OperationDetails collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.OperationDetails.List request = auditmanager.operationDetails().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public OperationDetails operationDetails() { + return new OperationDetails(); + } + + /** + * The "operationDetails" collection of methods. + */ + public class OperationDetails { + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationDetails.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationDetails.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operationDetails/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the OperationIds collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.OperationIds.List request = auditmanager.operationIds().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public OperationIds operationIds() { + return new OperationIds(); + } + + /** + * The "operationIds" collection of methods. + */ + public class OperationIds { + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationIds.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + + /** + * Gets details about the long-running operation to generate audit reports. + * + * Create a request for the method "operationIds.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operationIds/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the Operations collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.Operations.List request = auditmanager.operations().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public Operations operations() { + return new Operations(); + } + + /** + * The "operations" collection of methods. + */ + public class Operations { + + /** + * Starts asynchronous cancellation on a long-running operation. The server makes a best effort to + * cancel the operation, but success is not guaranteed. If the server doesn't support this method, + * it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other + * methods to check whether the cancellation succeeded or whether the operation completed despite + * cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an + * operation with an Operation.error value with a google.rpc.Status.code of `1`, corresponding to + * `Code.CANCELLED`. + * + * Create a request for the method "operations.cancel". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Cancel#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource to be cancelled. + * @param content the {@link com.google.api.services.auditmanager.v1.model.CancelOperationRequest} + * @return the request + */ + public Cancel cancel(java.lang.String name, com.google.api.services.auditmanager.v1.model.CancelOperationRequest content) throws java.io.IOException { + Cancel result = new Cancel(name, content); + initialize(result); + return result; + } + + public class Cancel extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}:cancel"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + + /** + * Starts asynchronous cancellation on a long-running operation. The server makes a best effort to + * cancel the operation, but success is not guaranteed. If the server doesn't support this method, + * it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other + * methods to check whether the cancellation succeeded or whether the operation completed despite + * cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an + * operation with an Operation.error value with a google.rpc.Status.code of `1`, corresponding to + * `Code.CANCELLED`. + * + * Create a request for the method "operations.cancel". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Cancel#execute()} method to invoke the remote operation. + *

{@link + * Cancel#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource to be cancelled. + * @param content the {@link com.google.api.services.auditmanager.v1.model.CancelOperationRequest} + * @since 1.13 + */ + protected Cancel(java.lang.String name, com.google.api.services.auditmanager.v1.model.CancelOperationRequest content) { + super(CloudAuditManager.this, "POST", REST_PATH, content, com.google.api.services.auditmanager.v1.model.Empty.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + } + + @Override + public Cancel set$Xgafv(java.lang.String $Xgafv) { + return (Cancel) super.set$Xgafv($Xgafv); + } + + @Override + public Cancel setAccessToken(java.lang.String accessToken) { + return (Cancel) super.setAccessToken(accessToken); + } + + @Override + public Cancel setAlt(java.lang.String alt) { + return (Cancel) super.setAlt(alt); + } + + @Override + public Cancel setCallback(java.lang.String callback) { + return (Cancel) super.setCallback(callback); + } + + @Override + public Cancel setFields(java.lang.String fields) { + return (Cancel) super.setFields(fields); + } + + @Override + public Cancel setKey(java.lang.String key) { + return (Cancel) super.setKey(key); + } + + @Override + public Cancel setOauthToken(java.lang.String oauthToken) { + return (Cancel) super.setOauthToken(oauthToken); + } + + @Override + public Cancel setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Cancel) super.setPrettyPrint(prettyPrint); + } + + @Override + public Cancel setQuotaUser(java.lang.String quotaUser) { + return (Cancel) super.setQuotaUser(quotaUser); + } + + @Override + public Cancel setUploadType(java.lang.String uploadType) { + return (Cancel) super.setUploadType(uploadType); + } + + @Override + public Cancel setUploadProtocol(java.lang.String uploadProtocol) { + return (Cancel) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource to be cancelled. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource to be cancelled. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource to be cancelled. */ + public Cancel setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Cancel set(String parameterName, Object value) { + return (Cancel) super.set(parameterName, value); + } + } + /** + * Deletes a long-running operation. This method indicates that the client is no longer interested + * in the operation result. It does not cancel the operation. If the server doesn't support this + * method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * + * Create a request for the method "operations.delete". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource to be deleted. + * @return the request + */ + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); + initialize(result); + return result; + } + + public class Delete extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + + /** + * Deletes a long-running operation. This method indicates that the client is no longer interested + * in the operation result. It does not cancel the operation. If the server doesn't support this + * method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * + * Create a request for the method "operations.delete". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource to be deleted. + * @since 1.13 + */ + protected Delete(java.lang.String name) { + super(CloudAuditManager.this, "DELETE", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Empty.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + } + + @Override + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); + } + + @Override + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); + } + + @Override + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); + } + + @Override + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); + } + + @Override + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); + } + + @Override + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); + } + + @Override + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); + } + + @Override + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); + } + + @Override + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); + } + + @Override + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); + } + + @Override + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource to be deleted. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource to be deleted. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource to be deleted. */ + public Delete setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); + } + } + /** + * Gets the latest state of a long-running operation. Clients can use this method to poll the + * operation result at intervals as recommended by the API service. + * + * Create a request for the method "operations.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the operation resource. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + + /** + * Gets the latest state of a long-running operation. Clients can use this method to poll the + * operation result at intervals as recommended by the API service. + * + * Create a request for the method "operations.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation resource. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation resource. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/operations/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists operations that match the specified filter in the request. If the server doesn't support + * this method, it returns `UNIMPLEMENTED`. + * + * Create a request for the method "operations.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param name The name of the operation's parent resource. + * @return the request + */ + public List list(java.lang.String name) throws java.io.IOException { + List result = new List(name); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}/operations"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); + + /** + * Lists operations that match the specified filter in the request. If the server doesn't support + * this method, it returns `UNIMPLEMENTED`. + * + * Create a request for the method "operations.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the operation's parent resource. + * @since 1.13 + */ + protected List(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListOperationsResponse.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the operation's parent resource. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the operation's parent resource. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the operation's parent resource. */ + public List setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+$"); + } + this.name = name; + return this; + } + + /** The standard list filter. */ + @com.google.api.client.util.Key + private java.lang.String filter; + + /** The standard list filter. + */ + public java.lang.String getFilter() { + return filter; + } + + /** The standard list filter. */ + public List setFilter(java.lang.String filter) { + this.filter = filter; + return this; + } + + /** The standard list page size. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The standard list page size. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The standard list page size. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The standard list page token. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The standard list page token. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** The standard list page token. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + /** + * When set to `true`, operations that are reachable are returned as normal, and those + * that are unreachable are returned in the ListOperationsResponse.unreachable field. This + * can only be `true` when reading across collections. For example, when `parent` is set + * to `"projects/example/locations/-"`. This field is not supported by default and will + * result in an `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + * service or product specific documentation. + */ + @com.google.api.client.util.Key + private java.lang.Boolean returnPartialSuccess; + + /** When set to `true`, operations that are reachable are returned as normal, and those that are + unreachable are returned in the ListOperationsResponse.unreachable field. This can only be `true` + when reading across collections. For example, when `parent` is set to + `"projects/example/locations/-"`. This field is not supported by default and will result in an + `UNIMPLEMENTED` error if set unless explicitly documented otherwise in service or product specific + documentation. + */ + public java.lang.Boolean getReturnPartialSuccess() { + return returnPartialSuccess; + } + + /** + * When set to `true`, operations that are reachable are returned as normal, and those + * that are unreachable are returned in the ListOperationsResponse.unreachable field. This + * can only be `true` when reading across collections. For example, when `parent` is set + * to `"projects/example/locations/-"`. This field is not supported by default and will + * result in an `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + * service or product specific documentation. + */ + public List setReturnPartialSuccess(java.lang.Boolean returnPartialSuccess) { + this.returnPartialSuccess = returnPartialSuccess; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the ResourceEnrollmentStatuses collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.ResourceEnrollmentStatuses.List request = auditmanager.resourceEnrollmentStatuses().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public ResourceEnrollmentStatuses resourceEnrollmentStatuses() { + return new ResourceEnrollmentStatuses(); + } + + /** + * The "resourceEnrollmentStatuses" collection of methods. + */ + public class ResourceEnrollmentStatuses { + + /** + * Gets a resource and its enrollment status. + * + * Create a request for the method "resourceEnrollmentStatuses.get". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_sta + * tus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enro + * llment_status}` * `organizations/{organization}/locations/{location}/resourceEnrollmentSta + * tuses/{resource_enrollment_status}` + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + + /** + * Gets a resource and its enrollment status. + * + * Create a request for the method "resourceEnrollmentStatuses.get". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_sta + * tus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enro + * llment_status}` * `organizations/{organization}/locations/{location}/resourceEnrollmentSta + * tuses/{resource_enrollment_status}` + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ResourceEnrollmentStatus.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Name of the resource enrollment status, in one of the following formats: * `f + * olders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_st + * atus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` * `organizations/{organization}/locations/{location}/resourceEnroll + * mentStatuses/{resource_enrollment_status}` + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. Name of the resource enrollment status, in one of the following formats: * + `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` * + `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` * + `organizations/{organization}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_ + status}` + */ + public java.lang.String getName() { + return name; + } + + /** + * Required. Name of the resource enrollment status, in one of the following formats: * `f + * olders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_st + * atus}` * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` * `organizations/{organization}/locations/{location}/resourceEnroll + * mentStatuses/{resource_enrollment_status}` + */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/resourceEnrollmentStatuses/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the Standards collection. + * + *

The typical use is:

+ *
+       *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+       *   {@code CloudAuditManager.Standards.List request = auditmanager.standards().list(parameters ...)}
+       * 
+ * + * @return the resource collection + */ + public Standards standards() { + return new Standards(); + } + + /** + * The "standards" collection of methods. + */ + public class Standards { + + /** + * An accessor for creating requests from the Controls collection. + * + *

The typical use is:

+ *
+         *   {@code CloudAuditManager auditmanager = new CloudAuditManager(...);}
+         *   {@code CloudAuditManager.Controls.List request = auditmanager.controls().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Controls controls() { + return new Controls(); + } + + /** + * The "controls" collection of methods. + */ + public class Controls { + + /** + * Lists the controls that you must implement to become compliant to a regulatory standard. + * + * Create a request for the method "controls.list". + * + * This request holds the parameters needed by the auditmanager server. After setting any optional + * parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends CloudAuditManagerRequest { + + private static final String REST_PATH = "v1/{+parent}/controls"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/standards/[^/]+$"); + + /** + * Lists the controls that you must implement to become compliant to a regulatory standard. + * + * Create a request for the method "controls.list". + * + * This request holds the parameters needed by the the auditmanager server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(CloudAuditManager.this, "GET", REST_PATH, null, com.google.api.services.auditmanager.v1.model.ListControlsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/standards/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. Standard to list controls for, in one of the following formats: * + `projects/{project}/locations/{location}/standards/{standard}` * + `folders/{folder}/locations/{location}/standards/{standard}` * + `organizations/{organization}/locations/{location}/standards/{standard}` + */ + public java.lang.String getParent() { + return parent; + } + + /** + * Required. Standard to list controls for, in one of the following formats: * + * `projects/{project}/locations/{location}/standards/{standard}` * + * `folders/{folder}/locations/{location}/standards/{standard}` * + * `organizations/{organization}/locations/{location}/standards/{standard}` + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/standards/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might + * return fewer items than this value. If unspecified, the service picks an appropriate + * default. The maximum value is 100; values above 100 are reduced to 100. + */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** Optional. Maximum number of items to return in a single page. The service might return fewer items + than this value. If unspecified, the service picks an appropriate default. The maximum value is + 100; values above 100 are reduced to 100. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** + * Optional. Maximum number of items to return in a single page. The service might + * return fewer items than this value. If unspecified, the service picks an appropriate + * default. The maximum value is 100; values above 100 are reduced to 100. + */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** Optional. A page token, received from a previous call, to retrieve the next page of results. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** + * Optional. A page token, received from a previous call, to retrieve the next page of + * results. + */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + + } + } + } + } + + /** + * Builder for {@link CloudAuditManager}. + * + *

+ * Implementation is not thread-safe. + *

+ * + * @since 1.3.0 + */ + public static final class Builder extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient.Builder { + + private static String chooseEndpoint(com.google.api.client.http.HttpTransport transport) { + // If the GOOGLE_API_USE_MTLS_ENDPOINT environment variable value is "always", use mTLS endpoint. + // If the env variable is "auto", use mTLS endpoint if and only if the transport is mTLS. + // Use the regular endpoint for all other cases. + String useMtlsEndpoint = System.getenv("GOOGLE_API_USE_MTLS_ENDPOINT"); + useMtlsEndpoint = useMtlsEndpoint == null ? "auto" : useMtlsEndpoint; + if ("always".equals(useMtlsEndpoint) || ("auto".equals(useMtlsEndpoint) && transport != null && transport.isMtls())) { + return DEFAULT_MTLS_ROOT_URL; + } + return DEFAULT_ROOT_URL; + } + + /** + * Returns an instance of a new builder. + * + * @param transport HTTP transport, which should normally be: + *
    + *
  • Google App Engine: + * {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}
  • + *
  • Android: {@code newCompatibleTransport} from + * {@code com.google.api.client.extensions.android.http.AndroidHttp}
  • + *
  • Java: {@code com.google.api.client.http.javanet.NetHttpTransport}
  • + *
+ * @param jsonFactory JSON factory, which may be: + *
    + *
  • Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}
  • + *
  • Google GSON: {@code com.google.api.client.json.gson.GsonFactory}
  • + *
  • Android Honeycomb or higher: + * {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}
  • + *
+ * @param httpRequestInitializer HTTP request initializer or {@code null} for none + * @since 1.7 + */ + public Builder(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, + com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + super( + transport, + jsonFactory, + Builder.chooseEndpoint(transport), + DEFAULT_SERVICE_PATH, + httpRequestInitializer, + false); + setBatchPath(DEFAULT_BATCH_PATH); + } + + /** Builds a new instance of {@link CloudAuditManager}. */ + @Override + public CloudAuditManager build() { + return new CloudAuditManager(this); + } + + @Override + public Builder setRootUrl(String rootUrl) { + return (Builder) super.setRootUrl(rootUrl); + } + + @Override + public Builder setServicePath(String servicePath) { + return (Builder) super.setServicePath(servicePath); + } + + @Override + public Builder setBatchPath(String batchPath) { + return (Builder) super.setBatchPath(batchPath); + } + + @Override + public Builder setHttpRequestInitializer(com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { + return (Builder) super.setHttpRequestInitializer(httpRequestInitializer); + } + + @Override + public Builder setApplicationName(String applicationName) { + return (Builder) super.setApplicationName(applicationName); + } + + @Override + public Builder setSuppressPatternChecks(boolean suppressPatternChecks) { + return (Builder) super.setSuppressPatternChecks(suppressPatternChecks); + } + + @Override + public Builder setSuppressRequiredParameterChecks(boolean suppressRequiredParameterChecks) { + return (Builder) super.setSuppressRequiredParameterChecks(suppressRequiredParameterChecks); + } + + @Override + public Builder setSuppressAllChecks(boolean suppressAllChecks) { + return (Builder) super.setSuppressAllChecks(suppressAllChecks); + } + + /** + * Set the {@link CloudAuditManagerRequestInitializer}. + * + * @since 1.12 + */ + public Builder setCloudAuditManagerRequestInitializer( + CloudAuditManagerRequestInitializer cloudauditmanagerRequestInitializer) { + return (Builder) super.setGoogleClientRequestInitializer(cloudauditmanagerRequestInitializer); + } + + @Override + public Builder setGoogleClientRequestInitializer( + com.google.api.client.googleapis.services.GoogleClientRequestInitializer googleClientRequestInitializer) { + return (Builder) super.setGoogleClientRequestInitializer(googleClientRequestInitializer); + } + + @Override + public Builder setUniverseDomain(String universeDomain) { + return (Builder) super.setUniverseDomain(universeDomain); + } + } +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerRequest.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerRequest.java new file mode 100644 index 00000000000..afa281ab559 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerRequest.java @@ -0,0 +1,267 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1; + +/** + * CloudAuditManager request. + * + * @since 1.3 + */ +@SuppressWarnings("javadoc") +public abstract class CloudAuditManagerRequest extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest { + + /** + * @param client Google client + * @param method HTTP Method + * @param uriTemplate URI template for the path relative to the base URL. If it starts with a "/" + * the base path from the base URL will be stripped out. The URI template can also be a + * full URL. URI template expansion is done using + * {@link com.google.api.client.http.UriTemplate#expand(String, String, Object, boolean)} + * @param content A POJO that can be serialized into JSON or {@code null} for none + * @param responseClass response class to parse into + */ + public CloudAuditManagerRequest( + CloudAuditManager client, String method, String uriTemplate, Object content, Class responseClass) { + super( + client, + method, + uriTemplate, + content, + responseClass); + } + + /** V1 error format. */ + @com.google.api.client.util.Key("$.xgafv") + private java.lang.String $Xgafv; + + /** + * V1 error format. + */ + public java.lang.String get$Xgafv() { + return $Xgafv; + } + + /** V1 error format. */ + public CloudAuditManagerRequest set$Xgafv(java.lang.String $Xgafv) { + this.$Xgafv = $Xgafv; + return this; + } + + /** OAuth access token. */ + @com.google.api.client.util.Key("access_token") + private java.lang.String accessToken; + + /** + * OAuth access token. + */ + public java.lang.String getAccessToken() { + return accessToken; + } + + /** OAuth access token. */ + public CloudAuditManagerRequest setAccessToken(java.lang.String accessToken) { + this.accessToken = accessToken; + return this; + } + + /** Data format for response. */ + @com.google.api.client.util.Key + private java.lang.String alt; + + /** + * Data format for response. [default: json] + */ + public java.lang.String getAlt() { + return alt; + } + + /** Data format for response. */ + public CloudAuditManagerRequest setAlt(java.lang.String alt) { + this.alt = alt; + return this; + } + + /** JSONP */ + @com.google.api.client.util.Key + private java.lang.String callback; + + /** + * JSONP + */ + public java.lang.String getCallback() { + return callback; + } + + /** JSONP */ + public CloudAuditManagerRequest setCallback(java.lang.String callback) { + this.callback = callback; + return this; + } + + /** Selector specifying which fields to include in a partial response. */ + @com.google.api.client.util.Key + private java.lang.String fields; + + /** + * Selector specifying which fields to include in a partial response. + */ + public java.lang.String getFields() { + return fields; + } + + /** Selector specifying which fields to include in a partial response. */ + public CloudAuditManagerRequest setFields(java.lang.String fields) { + this.fields = fields; + return this; + } + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + @com.google.api.client.util.Key + private java.lang.String key; + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + public java.lang.String getKey() { + return key; + } + + /** + * API key. Your API key identifies your project and provides you with API access, quota, and + * reports. Required unless you provide an OAuth 2.0 token. + */ + public CloudAuditManagerRequest setKey(java.lang.String key) { + this.key = key; + return this; + } + + /** OAuth 2.0 token for the current user. */ + @com.google.api.client.util.Key("oauth_token") + private java.lang.String oauthToken; + + /** + * OAuth 2.0 token for the current user. + */ + public java.lang.String getOauthToken() { + return oauthToken; + } + + /** OAuth 2.0 token for the current user. */ + public CloudAuditManagerRequest setOauthToken(java.lang.String oauthToken) { + this.oauthToken = oauthToken; + return this; + } + + /** Returns response with indentations and line breaks. */ + @com.google.api.client.util.Key + private java.lang.Boolean prettyPrint; + + /** + * Returns response with indentations and line breaks. [default: true] + */ + public java.lang.Boolean getPrettyPrint() { + return prettyPrint; + } + + /** Returns response with indentations and line breaks. */ + public CloudAuditManagerRequest setPrettyPrint(java.lang.Boolean prettyPrint) { + this.prettyPrint = prettyPrint; + return this; + } + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + @com.google.api.client.util.Key + private java.lang.String quotaUser; + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + public java.lang.String getQuotaUser() { + return quotaUser; + } + + /** + * Available to use for quota purposes for server-side applications. Can be any arbitrary string + * assigned to a user, but should not exceed 40 characters. + */ + public CloudAuditManagerRequest setQuotaUser(java.lang.String quotaUser) { + this.quotaUser = quotaUser; + return this; + } + + /** Legacy upload protocol for media (e.g. "media", "multipart"). */ + @com.google.api.client.util.Key + private java.lang.String uploadType; + + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + public java.lang.String getUploadType() { + return uploadType; + } + + /** Legacy upload protocol for media (e.g. "media", "multipart"). */ + public CloudAuditManagerRequest setUploadType(java.lang.String uploadType) { + this.uploadType = uploadType; + return this; + } + + /** Upload protocol for media (e.g. "raw", "multipart"). */ + @com.google.api.client.util.Key("upload_protocol") + private java.lang.String uploadProtocol; + + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + public java.lang.String getUploadProtocol() { + return uploadProtocol; + } + + /** Upload protocol for media (e.g. "raw", "multipart"). */ + public CloudAuditManagerRequest setUploadProtocol(java.lang.String uploadProtocol) { + this.uploadProtocol = uploadProtocol; + return this; + } + + @Override + public final CloudAuditManager getAbstractGoogleClient() { + return (CloudAuditManager) super.getAbstractGoogleClient(); + } + + @Override + public CloudAuditManagerRequest setDisableGZipContent(boolean disableGZipContent) { + return (CloudAuditManagerRequest) super.setDisableGZipContent(disableGZipContent); + } + + @Override + public CloudAuditManagerRequest setRequestHeaders(com.google.api.client.http.HttpHeaders headers) { + return (CloudAuditManagerRequest) super.setRequestHeaders(headers); + } + + @Override + public CloudAuditManagerRequest set(String parameterName, Object value) { + return (CloudAuditManagerRequest) super.set(parameterName, value); + } +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerRequestInitializer.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerRequestInitializer.java new file mode 100644 index 00000000000..55725abf907 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerRequestInitializer.java @@ -0,0 +1,119 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1; + +/** + * CloudAuditManager request initializer for setting properties like key and userIp. + * + *

+ * The simplest usage is to use it to set the key parameter: + *

+ * + *
+  public static final GoogleClientRequestInitializer KEY_INITIALIZER =
+      new CloudAuditManagerRequestInitializer(KEY);
+ * 
+ * + *

+ * There is also a constructor to set both the key and userIp parameters: + *

+ * + *
+  public static final GoogleClientRequestInitializer INITIALIZER =
+      new CloudAuditManagerRequestInitializer(KEY, USER_IP);
+ * 
+ * + *

+ * If you want to implement custom logic, extend it like this: + *

+ * + *
+  public static class MyRequestInitializer extends CloudAuditManagerRequestInitializer {
+
+    {@literal @}Override
+    public void initializeCloudAuditManagerRequest(CloudAuditManagerRequest{@literal <}?{@literal >} request)
+        throws IOException {
+      // custom logic
+    }
+  }
+ * 
+ * + *

+ * Finally, to set the key and userIp parameters and insert custom logic, extend it like this: + *

+ * + *
+  public static class MyRequestInitializer2 extends CloudAuditManagerRequestInitializer {
+
+    public MyKeyRequestInitializer() {
+      super(KEY, USER_IP);
+    }
+
+    {@literal @}Override
+    public void initializeCloudAuditManagerRequest(CloudAuditManagerRequest{@literal <}?{@literal >} request)
+        throws IOException {
+      // custom logic
+    }
+  }
+ * 
+ * + *

+ * Subclasses should be thread-safe. + *

+ * + * @since 1.12 + */ +public class CloudAuditManagerRequestInitializer extends com.google.api.client.googleapis.services.json.CommonGoogleJsonClientRequestInitializer { + + public CloudAuditManagerRequestInitializer() { + super(); + } + + /** + * @param key API key or {@code null} to leave it unchanged + */ + public CloudAuditManagerRequestInitializer(String key) { + super(key); + } + + /** + * @param key API key or {@code null} to leave it unchanged + * @param userIp user IP or {@code null} to leave it unchanged + */ + public CloudAuditManagerRequestInitializer(String key, String userIp) { + super(key, userIp); + } + + @Override + public final void initializeJsonRequest(com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest request) throws java.io.IOException { + super.initializeJsonRequest(request); + initializeCloudAuditManagerRequest((CloudAuditManagerRequest) request); + } + + /** + * Initializes CloudAuditManager request. + * + *

+ * Default implementation does nothing. Called from + * {@link #initializeJsonRequest(com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest)}. + *

+ * + * @throws java.io.IOException I/O exception + */ + protected void initializeCloudAuditManagerRequest(CloudAuditManagerRequest request) throws java.io.IOException { + } +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerScopes.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerScopes.java new file mode 100644 index 00000000000..051a6861f52 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/CloudAuditManagerScopes.java @@ -0,0 +1,46 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1; + +/** + * Available OAuth 2.0 scopes for use with the Audit Manager API. + * + * @since 1.4 + */ +public class CloudAuditManagerScopes { + + /** See, edit, configure, and delete your Google Cloud Auditmanager data and see the email address for your Google Account. */ + public static final String CLOUD_AUDITMANAGER = "https://www.googleapis.com/auth/cloud-auditmanager"; + + /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */ + public static final String CLOUD_PLATFORM = "https://www.googleapis.com/auth/cloud-platform"; + + /** + * Returns an unmodifiable set that contains all scopes declared by this class. + * + * @since 1.16 + */ + public static java.util.Set all() { + java.util.Set set = new java.util.HashSet(); + set.add(CLOUD_AUDITMANAGER); + set.add(CLOUD_PLATFORM); + return java.util.Collections.unmodifiableSet(set); + } + + private CloudAuditManagerScopes() { + } +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/AuditReport.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/AuditReport.java new file mode 100644 index 00000000000..04889d4e7eb --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/AuditReport.java @@ -0,0 +1,330 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * An audit report. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class AuditReport extends com.google.api.client.json.GenericJson { + + /** + * Output only. Compliance framework to use for the audit report. For example, + * `CIS_GCP_FOUNDATIONS_V1_2_0`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceFramework; + + /** + * Output only. Deprecated. Compliance standard to be audited against. Use the + * `compliance_framework` field instead. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceStandard; + + /** + * Output only. Overall status of the controls. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List controlDetails; + + /** + * Output only. Creation time of the audit report. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String createTime; + + /** + * Output only. Cloud Storage bucket where the audit report is uploaded to. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private DestinationDetails destinationDetails; + + /** + * Identifier. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * Output only. Client operation ID for the audit report. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String operationId; + + /** + * Output only. State of audit report generation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String reportGenerationState; + + /** + * Output only. Report summary that includes information about compliance and violation counts. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private ReportSummary reportSummary; + + /** + * Output only. Organization, folder, or project that the report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * `organizations/{organization}/locations/{location}` + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String scope; + + /** + * Output only. Project number, folder ID, or organization ID that the audit report was generated + * for. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String scopeId; + + /** + * Output only. Compliance framework to use for the audit report. For example, + * `CIS_GCP_FOUNDATIONS_V1_2_0`. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceFramework() { + return complianceFramework; + } + + /** + * Output only. Compliance framework to use for the audit report. For example, + * `CIS_GCP_FOUNDATIONS_V1_2_0`. + * @param complianceFramework complianceFramework or {@code null} for none + */ + public AuditReport setComplianceFramework(java.lang.String complianceFramework) { + this.complianceFramework = complianceFramework; + return this; + } + + /** + * Output only. Deprecated. Compliance standard to be audited against. Use the + * `compliance_framework` field instead. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceStandard() { + return complianceStandard; + } + + /** + * Output only. Deprecated. Compliance standard to be audited against. Use the + * `compliance_framework` field instead. + * @param complianceStandard complianceStandard or {@code null} for none + */ + public AuditReport setComplianceStandard(java.lang.String complianceStandard) { + this.complianceStandard = complianceStandard; + return this; + } + + /** + * Output only. Overall status of the controls. + * @return value or {@code null} for none + */ + public java.util.List getControlDetails() { + return controlDetails; + } + + /** + * Output only. Overall status of the controls. + * @param controlDetails controlDetails or {@code null} for none + */ + public AuditReport setControlDetails(java.util.List controlDetails) { + this.controlDetails = controlDetails; + return this; + } + + /** + * Output only. Creation time of the audit report. + * @return value or {@code null} for none + */ + public String getCreateTime() { + return createTime; + } + + /** + * Output only. Creation time of the audit report. + * @param createTime createTime or {@code null} for none + */ + public AuditReport setCreateTime(String createTime) { + this.createTime = createTime; + return this; + } + + /** + * Output only. Cloud Storage bucket where the audit report is uploaded to. + * @return value or {@code null} for none + */ + public DestinationDetails getDestinationDetails() { + return destinationDetails; + } + + /** + * Output only. Cloud Storage bucket where the audit report is uploaded to. + * @param destinationDetails destinationDetails or {@code null} for none + */ + public AuditReport setDestinationDetails(DestinationDetails destinationDetails) { + this.destinationDetails = destinationDetails; + return this; + } + + /** + * Identifier. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * Identifier. Name of the audit report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditReports/{audit_report}` * + * `folders/{folder}/locations/{location}/auditReports/{audit_report}` * + * `organizations/{organization}/locations/{location}/auditReports/{audit_report}` + * @param name name or {@code null} for none + */ + public AuditReport setName(java.lang.String name) { + this.name = name; + return this; + } + + /** + * Output only. Client operation ID for the audit report. + * @return value or {@code null} for none + */ + public java.lang.String getOperationId() { + return operationId; + } + + /** + * Output only. Client operation ID for the audit report. + * @param operationId operationId or {@code null} for none + */ + public AuditReport setOperationId(java.lang.String operationId) { + this.operationId = operationId; + return this; + } + + /** + * Output only. State of audit report generation. + * @return value or {@code null} for none + */ + public java.lang.String getReportGenerationState() { + return reportGenerationState; + } + + /** + * Output only. State of audit report generation. + * @param reportGenerationState reportGenerationState or {@code null} for none + */ + public AuditReport setReportGenerationState(java.lang.String reportGenerationState) { + this.reportGenerationState = reportGenerationState; + return this; + } + + /** + * Output only. Report summary that includes information about compliance and violation counts. + * @return value or {@code null} for none + */ + public ReportSummary getReportSummary() { + return reportSummary; + } + + /** + * Output only. Report summary that includes information about compliance and violation counts. + * @param reportSummary reportSummary or {@code null} for none + */ + public AuditReport setReportSummary(ReportSummary reportSummary) { + this.reportSummary = reportSummary; + return this; + } + + /** + * Output only. Organization, folder, or project that the report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * `organizations/{organization}/locations/{location}` + * @return value or {@code null} for none + */ + public java.lang.String getScope() { + return scope; + } + + /** + * Output only. Organization, folder, or project that the report is generated for, in one of the + * following formats: * `projects/{project}/locations/{location}` * + * `folders/{folder}/locations/{location}` * `organizations/{organization}/locations/{location}` + * @param scope scope or {@code null} for none + */ + public AuditReport setScope(java.lang.String scope) { + this.scope = scope; + return this; + } + + /** + * Output only. Project number, folder ID, or organization ID that the audit report was generated + * for. + * @return value or {@code null} for none + */ + public java.lang.String getScopeId() { + return scopeId; + } + + /** + * Output only. Project number, folder ID, or organization ID that the audit report was generated + * for. + * @param scopeId scopeId or {@code null} for none + */ + public AuditReport setScopeId(java.lang.String scopeId) { + this.scopeId = scopeId; + return this; + } + + @Override + public AuditReport set(String fieldName, Object value) { + return (AuditReport) super.set(fieldName, value); + } + + @Override + public AuditReport clone() { + return (AuditReport) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/AuditScopeReport.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/AuditScopeReport.java new file mode 100644 index 00000000000..e4927bcdade --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/AuditScopeReport.java @@ -0,0 +1,127 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Audit scope report. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class AuditScopeReport extends com.google.api.client.json.GenericJson { + + /** + * Identifier. Name for the audit scope report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditScopeReports/{audit_scope_report}` * + * `folders/{folder}/locations/{location}/auditScopeReports/{audit_scope_report}` * + * `organizations/{organization}/locations/{location}/auditScopeReports/{audit_scope_report}` + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * Audit scope report content in byte format. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String scopeReportContents; + + /** + * Identifier. Name for the audit scope report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditScopeReports/{audit_scope_report}` * + * `folders/{folder}/locations/{location}/auditScopeReports/{audit_scope_report}` * + * `organizations/{organization}/locations/{location}/auditScopeReports/{audit_scope_report}` + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * Identifier. Name for the audit scope report, in one of the following formats: * + * `projects/{project}/locations/{location}/auditScopeReports/{audit_scope_report}` * + * `folders/{folder}/locations/{location}/auditScopeReports/{audit_scope_report}` * + * `organizations/{organization}/locations/{location}/auditScopeReports/{audit_scope_report}` + * @param name name or {@code null} for none + */ + public AuditScopeReport setName(java.lang.String name) { + this.name = name; + return this; + } + + /** + * Audit scope report content in byte format. + * @see #decodeScopeReportContents() + * @return value or {@code null} for none + */ + public java.lang.String getScopeReportContents() { + return scopeReportContents; + } + + /** + * Audit scope report content in byte format. + * @see #getScopeReportContents() + * @return Base64 decoded value or {@code null} for none + * + * @since 1.14 + */ + public byte[] decodeScopeReportContents() { + return com.google.api.client.util.Base64.decodeBase64(scopeReportContents); + } + + /** + * Audit scope report content in byte format. + * @see #encodeScopeReportContents() + * @param scopeReportContents scopeReportContents or {@code null} for none + */ + public AuditScopeReport setScopeReportContents(java.lang.String scopeReportContents) { + this.scopeReportContents = scopeReportContents; + return this; + } + + /** + * Audit scope report content in byte format. + * @see #setScopeReportContents() + * + *

+ * The value is encoded Base64 or {@code null} for none. + *

+ * + * @since 1.14 + */ + public AuditScopeReport encodeScopeReportContents(byte[] scopeReportContents) { + this.scopeReportContents = com.google.api.client.util.Base64.encodeBase64URLSafeString(scopeReportContents); + return this; + } + + @Override + public AuditScopeReport set(String fieldName, Object value) { + return (AuditScopeReport) super.set(fieldName, value); + } + + @Override + public AuditScopeReport clone() { + return (AuditScopeReport) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/CancelOperationRequest.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/CancelOperationRequest.java new file mode 100644 index 00000000000..bfeae13b62e --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/CancelOperationRequest.java @@ -0,0 +1,42 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * The request message for Operations.CancelOperation. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class CancelOperationRequest extends com.google.api.client.json.GenericJson { + + @Override + public CancelOperationRequest set(String fieldName, Object value) { + return (CancelOperationRequest) super.set(fieldName, value); + } + + @Override + public CancelOperationRequest clone() { + return (CancelOperationRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Control.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Control.java new file mode 100644 index 00000000000..df75c87f2dd --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Control.java @@ -0,0 +1,288 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * A control. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Control extends com.google.api.client.json.GenericJson { + + /** + * Output only. Regulatory family of the control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private ControlFamily controlFamily; + + /** + * Output only. A description of your responsibility for this control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String customerResponsibilityDescription; + + /** + * Output only. A description of how you can implement your responsibility for this control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String customerResponsibilityImplementation; + + /** + * Output only. Description of the control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String description; + + /** + * Output only. Display name of the control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String displayName; + + /** + * Output only. Category that the control belongs to. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String family; + + /** + * Output only. A description of Google's responsibility for this control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String googleResponsibilityDescription; + + /** + * Output only. A description of how Google implements its responsibility for this control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String googleResponsibilityImplementation; + + /** + * Output only. Control identifier that's used to fetch the findings. The identifier is the same + * as the control report name. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String id; + + /** + * Output only. Who is responsible for implementing this control. Set to one of the following + * values: `GOOGLE`, `CUSTOMER`, or `SHARED`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String responsibilityType; + + /** + * Output only. Regulatory family of the control. + * @return value or {@code null} for none + */ + public ControlFamily getControlFamily() { + return controlFamily; + } + + /** + * Output only. Regulatory family of the control. + * @param controlFamily controlFamily or {@code null} for none + */ + public Control setControlFamily(ControlFamily controlFamily) { + this.controlFamily = controlFamily; + return this; + } + + /** + * Output only. A description of your responsibility for this control. + * @return value or {@code null} for none + */ + public java.lang.String getCustomerResponsibilityDescription() { + return customerResponsibilityDescription; + } + + /** + * Output only. A description of your responsibility for this control. + * @param customerResponsibilityDescription customerResponsibilityDescription or {@code null} for none + */ + public Control setCustomerResponsibilityDescription(java.lang.String customerResponsibilityDescription) { + this.customerResponsibilityDescription = customerResponsibilityDescription; + return this; + } + + /** + * Output only. A description of how you can implement your responsibility for this control. + * @return value or {@code null} for none + */ + public java.lang.String getCustomerResponsibilityImplementation() { + return customerResponsibilityImplementation; + } + + /** + * Output only. A description of how you can implement your responsibility for this control. + * @param customerResponsibilityImplementation customerResponsibilityImplementation or {@code null} for none + */ + public Control setCustomerResponsibilityImplementation(java.lang.String customerResponsibilityImplementation) { + this.customerResponsibilityImplementation = customerResponsibilityImplementation; + return this; + } + + /** + * Output only. Description of the control. + * @return value or {@code null} for none + */ + public java.lang.String getDescription() { + return description; + } + + /** + * Output only. Description of the control. + * @param description description or {@code null} for none + */ + public Control setDescription(java.lang.String description) { + this.description = description; + return this; + } + + /** + * Output only. Display name of the control. + * @return value or {@code null} for none + */ + public java.lang.String getDisplayName() { + return displayName; + } + + /** + * Output only. Display name of the control. + * @param displayName displayName or {@code null} for none + */ + public Control setDisplayName(java.lang.String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Output only. Category that the control belongs to. + * @return value or {@code null} for none + */ + public java.lang.String getFamily() { + return family; + } + + /** + * Output only. Category that the control belongs to. + * @param family family or {@code null} for none + */ + public Control setFamily(java.lang.String family) { + this.family = family; + return this; + } + + /** + * Output only. A description of Google's responsibility for this control. + * @return value or {@code null} for none + */ + public java.lang.String getGoogleResponsibilityDescription() { + return googleResponsibilityDescription; + } + + /** + * Output only. A description of Google's responsibility for this control. + * @param googleResponsibilityDescription googleResponsibilityDescription or {@code null} for none + */ + public Control setGoogleResponsibilityDescription(java.lang.String googleResponsibilityDescription) { + this.googleResponsibilityDescription = googleResponsibilityDescription; + return this; + } + + /** + * Output only. A description of how Google implements its responsibility for this control. + * @return value or {@code null} for none + */ + public java.lang.String getGoogleResponsibilityImplementation() { + return googleResponsibilityImplementation; + } + + /** + * Output only. A description of how Google implements its responsibility for this control. + * @param googleResponsibilityImplementation googleResponsibilityImplementation or {@code null} for none + */ + public Control setGoogleResponsibilityImplementation(java.lang.String googleResponsibilityImplementation) { + this.googleResponsibilityImplementation = googleResponsibilityImplementation; + return this; + } + + /** + * Output only. Control identifier that's used to fetch the findings. The identifier is the same + * as the control report name. + * @return value or {@code null} for none + */ + public java.lang.String getId() { + return id; + } + + /** + * Output only. Control identifier that's used to fetch the findings. The identifier is the same + * as the control report name. + * @param id id or {@code null} for none + */ + public Control setId(java.lang.String id) { + this.id = id; + return this; + } + + /** + * Output only. Who is responsible for implementing this control. Set to one of the following + * values: `GOOGLE`, `CUSTOMER`, or `SHARED`. + * @return value or {@code null} for none + */ + public java.lang.String getResponsibilityType() { + return responsibilityType; + } + + /** + * Output only. Who is responsible for implementing this control. Set to one of the following + * values: `GOOGLE`, `CUSTOMER`, or `SHARED`. + * @param responsibilityType responsibilityType or {@code null} for none + */ + public Control setResponsibilityType(java.lang.String responsibilityType) { + this.responsibilityType = responsibilityType; + return this; + } + + @Override + public Control set(String fieldName, Object value) { + return (Control) super.set(fieldName, value); + } + + @Override + public Control clone() { + return (Control) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ControlDetails.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ControlDetails.java new file mode 100644 index 00000000000..0bb584ffdb7 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ControlDetails.java @@ -0,0 +1,117 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Evaluation details for a control. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ControlDetails extends com.google.api.client.json.GenericJson { + + /** + * Output only. Overall status of the findings for the control. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceState; + + /** + * Control that the findings are being reported for. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private Control control; + + /** + * A control report summary that provides a high-level overview of the compliance controls and the + * assessment status. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private ReportSummary controlReportSummary; + + /** + * Output only. Overall status of the findings for the control. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceState() { + return complianceState; + } + + /** + * Output only. Overall status of the findings for the control. + * @param complianceState complianceState or {@code null} for none + */ + public ControlDetails setComplianceState(java.lang.String complianceState) { + this.complianceState = complianceState; + return this; + } + + /** + * Control that the findings are being reported for. + * @return value or {@code null} for none + */ + public Control getControl() { + return control; + } + + /** + * Control that the findings are being reported for. + * @param control control or {@code null} for none + */ + public ControlDetails setControl(Control control) { + this.control = control; + return this; + } + + /** + * A control report summary that provides a high-level overview of the compliance controls and the + * assessment status. + * @return value or {@code null} for none + */ + public ReportSummary getControlReportSummary() { + return controlReportSummary; + } + + /** + * A control report summary that provides a high-level overview of the compliance controls and the + * assessment status. + * @param controlReportSummary controlReportSummary or {@code null} for none + */ + public ControlDetails setControlReportSummary(ReportSummary controlReportSummary) { + this.controlReportSummary = controlReportSummary; + return this; + } + + @Override + public ControlDetails set(String fieldName, Object value) { + return (ControlDetails) super.set(fieldName, value); + } + + @Override + public ControlDetails clone() { + return (ControlDetails) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ControlFamily.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ControlFamily.java new file mode 100644 index 00000000000..9f0ae5f17bf --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ControlFamily.java @@ -0,0 +1,93 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Regulatory family of the control. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ControlFamily extends com.google.api.client.json.GenericJson { + + /** + * Display name of the regulatory control family. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String displayName; + + /** + * ID of the regulatory control family. To find the list of supported control families, use the + * ListControls method and review the `control_family` field in the response. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String familyId; + + /** + * Display name of the regulatory control family. + * @return value or {@code null} for none + */ + public java.lang.String getDisplayName() { + return displayName; + } + + /** + * Display name of the regulatory control family. + * @param displayName displayName or {@code null} for none + */ + public ControlFamily setDisplayName(java.lang.String displayName) { + this.displayName = displayName; + return this; + } + + /** + * ID of the regulatory control family. To find the list of supported control families, use the + * ListControls method and review the `control_family` field in the response. + * @return value or {@code null} for none + */ + public java.lang.String getFamilyId() { + return familyId; + } + + /** + * ID of the regulatory control family. To find the list of supported control families, use the + * ListControls method and review the `control_family` field in the response. + * @param familyId familyId or {@code null} for none + */ + public ControlFamily setFamilyId(java.lang.String familyId) { + this.familyId = familyId; + return this; + } + + @Override + public ControlFamily set(String fieldName, Object value) { + return (ControlFamily) super.set(fieldName, value); + } + + @Override + public ControlFamily clone() { + return (ControlFamily) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/DestinationDetails.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/DestinationDetails.java new file mode 100644 index 00000000000..c2bb8607cda --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/DestinationDetails.java @@ -0,0 +1,66 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Cloud Storage bucket where the audit report is uploaded to. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class DestinationDetails extends com.google.api.client.json.GenericJson { + + /** + * URI for the Cloud Storage bucket, in the format `gs://{bucket_name}`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String gcsBucketUri; + + /** + * URI for the Cloud Storage bucket, in the format `gs://{bucket_name}`. + * @return value or {@code null} for none + */ + public java.lang.String getGcsBucketUri() { + return gcsBucketUri; + } + + /** + * URI for the Cloud Storage bucket, in the format `gs://{bucket_name}`. + * @param gcsBucketUri gcsBucketUri or {@code null} for none + */ + public DestinationDetails setGcsBucketUri(java.lang.String gcsBucketUri) { + this.gcsBucketUri = gcsBucketUri; + return this; + } + + @Override + public DestinationDetails set(String fieldName, Object value) { + return (DestinationDetails) super.set(fieldName, value); + } + + @Override + public DestinationDetails clone() { + return (DestinationDetails) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/EligibleDestination.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/EligibleDestination.java new file mode 100644 index 00000000000..bf94f73e844 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/EligibleDestination.java @@ -0,0 +1,69 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Details about the bucket where you want to upload the audit report. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class EligibleDestination extends com.google.api.client.json.GenericJson { + + /** + * The location of the Cloud Storage bucket where you want to upload the audit report and evidence + * during the GenerateAuditReport API call. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String eligibleGcsBucket; + + /** + * The location of the Cloud Storage bucket where you want to upload the audit report and evidence + * during the GenerateAuditReport API call. + * @return value or {@code null} for none + */ + public java.lang.String getEligibleGcsBucket() { + return eligibleGcsBucket; + } + + /** + * The location of the Cloud Storage bucket where you want to upload the audit report and evidence + * during the GenerateAuditReport API call. + * @param eligibleGcsBucket eligibleGcsBucket or {@code null} for none + */ + public EligibleDestination setEligibleGcsBucket(java.lang.String eligibleGcsBucket) { + this.eligibleGcsBucket = eligibleGcsBucket; + return this; + } + + @Override + public EligibleDestination set(String fieldName, Object value) { + return (EligibleDestination) super.set(fieldName, value); + } + + @Override + public EligibleDestination clone() { + return (EligibleDestination) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Empty.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Empty.java new file mode 100644 index 00000000000..e2e24b1e1cd --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Empty.java @@ -0,0 +1,44 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your + * APIs. A typical example is to use it as the request or the response type of an API method. For + * instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Empty extends com.google.api.client.json.GenericJson { + + @Override + public Empty set(String fieldName, Object value) { + return (Empty) super.set(fieldName, value); + } + + @Override + public Empty clone() { + return (Empty) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/EnrollResourceRequest.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/EnrollResourceRequest.java new file mode 100644 index 00000000000..386082abd7f --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/EnrollResourceRequest.java @@ -0,0 +1,84 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Request message for EnrollResource. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class EnrollResourceRequest extends com.google.api.client.json.GenericJson { + + /** + * Required. Cloud Storage buckets that you can upload your audit reports to during the audit + * process. When you enroll an organization or folder, you can choose a Cloud Storage bucket from + * any project in the organization or folder. If you run an audit at the project level using the + * service agent at the organization or folder level, all the buckets that are associated with the + * service agent are available. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List destinations; + + static { + // hack to force ProGuard to consider EligibleDestination used, since otherwise it would be stripped out + // see https://github.com/google/google-api-java-client/issues/543 + com.google.api.client.util.Data.nullOf(EligibleDestination.class); + } + + /** + * Required. Cloud Storage buckets that you can upload your audit reports to during the audit + * process. When you enroll an organization or folder, you can choose a Cloud Storage bucket from + * any project in the organization or folder. If you run an audit at the project level using the + * service agent at the organization or folder level, all the buckets that are associated with the + * service agent are available. + * @return value or {@code null} for none + */ + public java.util.List getDestinations() { + return destinations; + } + + /** + * Required. Cloud Storage buckets that you can upload your audit reports to during the audit + * process. When you enroll an organization or folder, you can choose a Cloud Storage bucket from + * any project in the organization or folder. If you run an audit at the project level using the + * service agent at the organization or folder level, all the buckets that are associated with the + * service agent are available. + * @param destinations destinations or {@code null} for none + */ + public EnrollResourceRequest setDestinations(java.util.List destinations) { + this.destinations = destinations; + return this; + } + + @Override + public EnrollResourceRequest set(String fieldName, Object value) { + return (EnrollResourceRequest) super.set(fieldName, value); + } + + @Override + public EnrollResourceRequest clone() { + return (EnrollResourceRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Enrollment.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Enrollment.java new file mode 100644 index 00000000000..828e090cbf1 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Enrollment.java @@ -0,0 +1,105 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Organization, folder, or project to enroll for audit reports. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Enrollment extends com.google.api.client.json.GenericJson { + + /** + * Output only. Cloud Storage buckets where you want to upload the audit reports. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List destinationDetails; + + static { + // hack to force ProGuard to consider DestinationDetails used, since otherwise it would be stripped out + // see https://github.com/google/google-api-java-client/issues/543 + com.google.api.client.util.Data.nullOf(DestinationDetails.class); + } + + /** + * Identifier. Name of the enrollment, in one of the following formats: * + * `projects/{project}/locations/{location}/enrollments/{enrollment}` * + * `folders/{folder}/locations/{location}/enrollments/{enrollment}` * + * `organizations/{organization}/locations/{location}/enrollments/{enrollment}` + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * Output only. Cloud Storage buckets where you want to upload the audit reports. + * @return value or {@code null} for none + */ + public java.util.List getDestinationDetails() { + return destinationDetails; + } + + /** + * Output only. Cloud Storage buckets where you want to upload the audit reports. + * @param destinationDetails destinationDetails or {@code null} for none + */ + public Enrollment setDestinationDetails(java.util.List destinationDetails) { + this.destinationDetails = destinationDetails; + return this; + } + + /** + * Identifier. Name of the enrollment, in one of the following formats: * + * `projects/{project}/locations/{location}/enrollments/{enrollment}` * + * `folders/{folder}/locations/{location}/enrollments/{enrollment}` * + * `organizations/{organization}/locations/{location}/enrollments/{enrollment}` + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * Identifier. Name of the enrollment, in one of the following formats: * + * `projects/{project}/locations/{location}/enrollments/{enrollment}` * + * `folders/{folder}/locations/{location}/enrollments/{enrollment}` * + * `organizations/{organization}/locations/{location}/enrollments/{enrollment}` + * @param name name or {@code null} for none + */ + public Enrollment setName(java.lang.String name) { + this.name = name; + return this; + } + + @Override + public Enrollment set(String fieldName, Object value) { + return (Enrollment) super.set(fieldName, value); + } + + @Override + public Enrollment clone() { + return (Enrollment) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/GenerateAuditReportRequest.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/GenerateAuditReportRequest.java new file mode 100644 index 00000000000..00b4be5608d --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/GenerateAuditReportRequest.java @@ -0,0 +1,189 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Request message for GenerateAuditReport. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GenerateAuditReportRequest extends com.google.api.client.json.GenericJson { + + /** + * Required. The framework that's used for the audit report. For example, `NIST_800_53`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceFramework; + + /** + * Optional. Deprecated. Compliance standard for the audit report. Use the `compliance_framework` + * field instead. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceStandard; + + /** + * URL for the Cloud Storage bucket where the report and evidence is uploaded. You must select a + * bucket that was provided during the enrollment process. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String gcsUri; + + /** + * Required. Format for the audit report. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String reportFormat; + + /** + * Optional. If `true`, only validates the request and does not generate the audit report. This + * executes standard request validation (such as schema, framework existence, scope, and IAM + * checks) and skips the apply phase. Use this field for the following purposes: * + * **Infrastructure as Code (IaC)**: Allow tools like Terraform to run dry-run mutations (e.g., + * `terraform plan`) without creating real resources or incurring costs. * **User Interface + * Validation**: Enable real-time form and permission validation in custom UIs before submitting + * requests. * **CI/CD & Automation**: Test your scripts, permissions, and parameters safely + * without triggering expensive Long-Running Operations (LROs) or consuming resource quotas. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Boolean validateOnly; + + /** + * Required. The framework that's used for the audit report. For example, `NIST_800_53`. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceFramework() { + return complianceFramework; + } + + /** + * Required. The framework that's used for the audit report. For example, `NIST_800_53`. + * @param complianceFramework complianceFramework or {@code null} for none + */ + public GenerateAuditReportRequest setComplianceFramework(java.lang.String complianceFramework) { + this.complianceFramework = complianceFramework; + return this; + } + + /** + * Optional. Deprecated. Compliance standard for the audit report. Use the `compliance_framework` + * field instead. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceStandard() { + return complianceStandard; + } + + /** + * Optional. Deprecated. Compliance standard for the audit report. Use the `compliance_framework` + * field instead. + * @param complianceStandard complianceStandard or {@code null} for none + */ + public GenerateAuditReportRequest setComplianceStandard(java.lang.String complianceStandard) { + this.complianceStandard = complianceStandard; + return this; + } + + /** + * URL for the Cloud Storage bucket where the report and evidence is uploaded. You must select a + * bucket that was provided during the enrollment process. + * @return value or {@code null} for none + */ + public java.lang.String getGcsUri() { + return gcsUri; + } + + /** + * URL for the Cloud Storage bucket where the report and evidence is uploaded. You must select a + * bucket that was provided during the enrollment process. + * @param gcsUri gcsUri or {@code null} for none + */ + public GenerateAuditReportRequest setGcsUri(java.lang.String gcsUri) { + this.gcsUri = gcsUri; + return this; + } + + /** + * Required. Format for the audit report. + * @return value or {@code null} for none + */ + public java.lang.String getReportFormat() { + return reportFormat; + } + + /** + * Required. Format for the audit report. + * @param reportFormat reportFormat or {@code null} for none + */ + public GenerateAuditReportRequest setReportFormat(java.lang.String reportFormat) { + this.reportFormat = reportFormat; + return this; + } + + /** + * Optional. If `true`, only validates the request and does not generate the audit report. This + * executes standard request validation (such as schema, framework existence, scope, and IAM + * checks) and skips the apply phase. Use this field for the following purposes: * + * **Infrastructure as Code (IaC)**: Allow tools like Terraform to run dry-run mutations (e.g., + * `terraform plan`) without creating real resources or incurring costs. * **User Interface + * Validation**: Enable real-time form and permission validation in custom UIs before submitting + * requests. * **CI/CD & Automation**: Test your scripts, permissions, and parameters safely + * without triggering expensive Long-Running Operations (LROs) or consuming resource quotas. + * @return value or {@code null} for none + */ + public java.lang.Boolean getValidateOnly() { + return validateOnly; + } + + /** + * Optional. If `true`, only validates the request and does not generate the audit report. This + * executes standard request validation (such as schema, framework existence, scope, and IAM + * checks) and skips the apply phase. Use this field for the following purposes: * + * **Infrastructure as Code (IaC)**: Allow tools like Terraform to run dry-run mutations (e.g., + * `terraform plan`) without creating real resources or incurring costs. * **User Interface + * Validation**: Enable real-time form and permission validation in custom UIs before submitting + * requests. * **CI/CD & Automation**: Test your scripts, permissions, and parameters safely + * without triggering expensive Long-Running Operations (LROs) or consuming resource quotas. + * @param validateOnly validateOnly or {@code null} for none + */ + public GenerateAuditReportRequest setValidateOnly(java.lang.Boolean validateOnly) { + this.validateOnly = validateOnly; + return this; + } + + @Override + public GenerateAuditReportRequest set(String fieldName, Object value) { + return (GenerateAuditReportRequest) super.set(fieldName, value); + } + + @Override + public GenerateAuditReportRequest clone() { + return (GenerateAuditReportRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/GenerateAuditScopeReportRequest.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/GenerateAuditScopeReportRequest.java new file mode 100644 index 00000000000..c2ac9e0df0b --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/GenerateAuditScopeReportRequest.java @@ -0,0 +1,165 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Request message for GenerateAuditScopeReport. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GenerateAuditScopeReportRequest extends com.google.api.client.json.GenericJson { + + /** + * Required. Framework (set of controls) that the audit scope report is generated against. For + * example, `NIST_800_53`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceFramework; + + /** + * Optional. Deprecated. The standard (industry or regulatory requirements) that the audit scope + * report is run against. Use the `compliance_framework` field instead. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String complianceStandard; + + /** + * Required. Format for the audit scope report. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String reportFormat; + + /** + * Optional. If `true`, only validates the request and does not generate the audit scope report. + * This executes standard request validation (such as schema, framework existence, scope, and IAM + * checks) and skips the apply phase. Use this field for the following purposes: * + * **Infrastructure as Code (IaC)**: Allow tools like Terraform to run dry-run mutations (e.g., + * `terraform plan`) without creating real resources or incurring costs. * **User Interface + * Validation**: Enable real-time form and permission validation in custom UIs before submitting + * requests. * **CI/CD & Automation**: Test your scripts, permissions, and parameters safely + * without consuming resource quotas. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Boolean validateOnly; + + /** + * Required. Framework (set of controls) that the audit scope report is generated against. For + * example, `NIST_800_53`. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceFramework() { + return complianceFramework; + } + + /** + * Required. Framework (set of controls) that the audit scope report is generated against. For + * example, `NIST_800_53`. + * @param complianceFramework complianceFramework or {@code null} for none + */ + public GenerateAuditScopeReportRequest setComplianceFramework(java.lang.String complianceFramework) { + this.complianceFramework = complianceFramework; + return this; + } + + /** + * Optional. Deprecated. The standard (industry or regulatory requirements) that the audit scope + * report is run against. Use the `compliance_framework` field instead. + * @return value or {@code null} for none + */ + public java.lang.String getComplianceStandard() { + return complianceStandard; + } + + /** + * Optional. Deprecated. The standard (industry or regulatory requirements) that the audit scope + * report is run against. Use the `compliance_framework` field instead. + * @param complianceStandard complianceStandard or {@code null} for none + */ + public GenerateAuditScopeReportRequest setComplianceStandard(java.lang.String complianceStandard) { + this.complianceStandard = complianceStandard; + return this; + } + + /** + * Required. Format for the audit scope report. + * @return value or {@code null} for none + */ + public java.lang.String getReportFormat() { + return reportFormat; + } + + /** + * Required. Format for the audit scope report. + * @param reportFormat reportFormat or {@code null} for none + */ + public GenerateAuditScopeReportRequest setReportFormat(java.lang.String reportFormat) { + this.reportFormat = reportFormat; + return this; + } + + /** + * Optional. If `true`, only validates the request and does not generate the audit scope report. + * This executes standard request validation (such as schema, framework existence, scope, and IAM + * checks) and skips the apply phase. Use this field for the following purposes: * + * **Infrastructure as Code (IaC)**: Allow tools like Terraform to run dry-run mutations (e.g., + * `terraform plan`) without creating real resources or incurring costs. * **User Interface + * Validation**: Enable real-time form and permission validation in custom UIs before submitting + * requests. * **CI/CD & Automation**: Test your scripts, permissions, and parameters safely + * without consuming resource quotas. + * @return value or {@code null} for none + */ + public java.lang.Boolean getValidateOnly() { + return validateOnly; + } + + /** + * Optional. If `true`, only validates the request and does not generate the audit scope report. + * This executes standard request validation (such as schema, framework existence, scope, and IAM + * checks) and skips the apply phase. Use this field for the following purposes: * + * **Infrastructure as Code (IaC)**: Allow tools like Terraform to run dry-run mutations (e.g., + * `terraform plan`) without creating real resources or incurring costs. * **User Interface + * Validation**: Enable real-time form and permission validation in custom UIs before submitting + * requests. * **CI/CD & Automation**: Test your scripts, permissions, and parameters safely + * without consuming resource quotas. + * @param validateOnly validateOnly or {@code null} for none + */ + public GenerateAuditScopeReportRequest setValidateOnly(java.lang.Boolean validateOnly) { + this.validateOnly = validateOnly; + return this; + } + + @Override + public GenerateAuditScopeReportRequest set(String fieldName, Object value) { + return (GenerateAuditScopeReportRequest) super.set(fieldName, value); + } + + @Override + public GenerateAuditScopeReportRequest clone() { + return (GenerateAuditScopeReportRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListAuditReportsResponse.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListAuditReportsResponse.java new file mode 100644 index 00000000000..5de4aef90c6 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListAuditReportsResponse.java @@ -0,0 +1,99 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Response message for ListAuditReports. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListAuditReportsResponse extends com.google.api.client.json.GenericJson { + + /** + * Output only. Audit reports. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List auditReports; + + static { + // hack to force ProGuard to consider AuditReport used, since otherwise it would be stripped out + // see https://github.com/google/google-api-java-client/issues/543 + com.google.api.client.util.Data.nullOf(AuditReport.class); + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * Output only. Audit reports. + * @return value or {@code null} for none + */ + public java.util.List getAuditReports() { + return auditReports; + } + + /** + * Output only. Audit reports. + * @param auditReports auditReports or {@code null} for none + */ + public ListAuditReportsResponse setAuditReports(java.util.List auditReports) { + this.auditReports = auditReports; + return this; + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListAuditReportsResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + @Override + public ListAuditReportsResponse set(String fieldName, Object value) { + return (ListAuditReportsResponse) super.set(fieldName, value); + } + + @Override + public ListAuditReportsResponse clone() { + return (ListAuditReportsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListControlsResponse.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListControlsResponse.java new file mode 100644 index 00000000000..acf9551c5a8 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListControlsResponse.java @@ -0,0 +1,99 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Response message for ListControls. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListControlsResponse extends com.google.api.client.json.GenericJson { + + /** + * Output only. Controls for a given regulatory standard. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List controls; + + static { + // hack to force ProGuard to consider Control used, since otherwise it would be stripped out + // see https://github.com/google/google-api-java-client/issues/543 + com.google.api.client.util.Data.nullOf(Control.class); + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * Output only. Controls for a given regulatory standard. + * @return value or {@code null} for none + */ + public java.util.List getControls() { + return controls; + } + + /** + * Output only. Controls for a given regulatory standard. + * @param controls controls or {@code null} for none + */ + public ListControlsResponse setControls(java.util.List controls) { + this.controls = controls; + return this; + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListControlsResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + @Override + public ListControlsResponse set(String fieldName, Object value) { + return (ListControlsResponse) super.set(fieldName, value); + } + + @Override + public ListControlsResponse clone() { + return (ListControlsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListLocationsResponse.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListLocationsResponse.java new file mode 100644 index 00000000000..ecfd9c12cbe --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListLocationsResponse.java @@ -0,0 +1,90 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * The response message for Locations.ListLocations. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListLocationsResponse extends com.google.api.client.json.GenericJson { + + /** + * A list of locations that matches the specified filter in the request. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List locations; + + /** + * The standard List next-page token. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * A list of locations that matches the specified filter in the request. + * @return value or {@code null} for none + */ + public java.util.List getLocations() { + return locations; + } + + /** + * A list of locations that matches the specified filter in the request. + * @param locations locations or {@code null} for none + */ + public ListLocationsResponse setLocations(java.util.List locations) { + this.locations = locations; + return this; + } + + /** + * The standard List next-page token. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * The standard List next-page token. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListLocationsResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + @Override + public ListLocationsResponse set(String fieldName, Object value) { + return (ListLocationsResponse) super.set(fieldName, value); + } + + @Override + public ListLocationsResponse clone() { + return (ListLocationsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListOperationsResponse.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListOperationsResponse.java new file mode 100644 index 00000000000..f6223deee48 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListOperationsResponse.java @@ -0,0 +1,120 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * The response message for Operations.ListOperations. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListOperationsResponse extends com.google.api.client.json.GenericJson { + + /** + * The standard List next-page token. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * A list of operations that matches the specified filter in the request. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List operations; + + /** + * Unordered list. Unreachable resources. Populated when the request sets + * `ListOperationsRequest.return_partial_success` and reads across collections. For example, when + * attempting to list all resources across all supported locations. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List unreachable; + + /** + * The standard List next-page token. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * The standard List next-page token. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListOperationsResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + /** + * A list of operations that matches the specified filter in the request. + * @return value or {@code null} for none + */ + public java.util.List getOperations() { + return operations; + } + + /** + * A list of operations that matches the specified filter in the request. + * @param operations operations or {@code null} for none + */ + public ListOperationsResponse setOperations(java.util.List operations) { + this.operations = operations; + return this; + } + + /** + * Unordered list. Unreachable resources. Populated when the request sets + * `ListOperationsRequest.return_partial_success` and reads across collections. For example, when + * attempting to list all resources across all supported locations. + * @return value or {@code null} for none + */ + public java.util.List getUnreachable() { + return unreachable; + } + + /** + * Unordered list. Unreachable resources. Populated when the request sets + * `ListOperationsRequest.return_partial_success` and reads across collections. For example, when + * attempting to list all resources across all supported locations. + * @param unreachable unreachable or {@code null} for none + */ + public ListOperationsResponse setUnreachable(java.util.List unreachable) { + this.unreachable = unreachable; + return this; + } + + @Override + public ListOperationsResponse set(String fieldName, Object value) { + return (ListOperationsResponse) super.set(fieldName, value); + } + + @Override + public ListOperationsResponse clone() { + return (ListOperationsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListResourceEnrollmentStatusesResponse.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListResourceEnrollmentStatusesResponse.java new file mode 100644 index 00000000000..fb1c9ccd5b1 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ListResourceEnrollmentStatusesResponse.java @@ -0,0 +1,93 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Response message for ListResourceEnrollmentStatuses. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListResourceEnrollmentStatusesResponse extends com.google.api.client.json.GenericJson { + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * Resources with their enrollment status. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List resourceEnrollmentStatuses; + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * Output only. A token that you can send as the `page_token` in a subsequent request to retrieve + * the next page of results. If this field is empty, there are no subsequent pages. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListResourceEnrollmentStatusesResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + /** + * Resources with their enrollment status. + * @return value or {@code null} for none + */ + public java.util.List getResourceEnrollmentStatuses() { + return resourceEnrollmentStatuses; + } + + /** + * Resources with their enrollment status. + * @param resourceEnrollmentStatuses resourceEnrollmentStatuses or {@code null} for none + */ + public ListResourceEnrollmentStatusesResponse setResourceEnrollmentStatuses(java.util.List resourceEnrollmentStatuses) { + this.resourceEnrollmentStatuses = resourceEnrollmentStatuses; + return this; + } + + @Override + public ListResourceEnrollmentStatusesResponse set(String fieldName, Object value) { + return (ListResourceEnrollmentStatusesResponse) super.set(fieldName, value); + } + + @Override + public ListResourceEnrollmentStatusesResponse clone() { + return (ListResourceEnrollmentStatusesResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Location.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Location.java new file mode 100644 index 00000000000..60551136168 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Location.java @@ -0,0 +1,168 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * A resource that represents a Google Cloud location. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Location extends com.google.api.client.json.GenericJson { + + /** + * The friendly name for this location, typically a nearby city name. For example, "Tokyo". + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String displayName; + + /** + * Cross-service attributes for the location. For example {"cloud.googleapis.com/region": "us- + * east1"} + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map labels; + + /** + * The canonical id for this location. For example: `"us-east1"`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String locationId; + + /** + * Service-specific metadata. For example the available capacity at the given location. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map metadata; + + /** + * Resource name for the location, which may vary between implementations. For example: + * `"projects/example-project/locations/us-east1"` + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * The friendly name for this location, typically a nearby city name. For example, "Tokyo". + * @return value or {@code null} for none + */ + public java.lang.String getDisplayName() { + return displayName; + } + + /** + * The friendly name for this location, typically a nearby city name. For example, "Tokyo". + * @param displayName displayName or {@code null} for none + */ + public Location setDisplayName(java.lang.String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Cross-service attributes for the location. For example {"cloud.googleapis.com/region": "us- + * east1"} + * @return value or {@code null} for none + */ + public java.util.Map getLabels() { + return labels; + } + + /** + * Cross-service attributes for the location. For example {"cloud.googleapis.com/region": "us- + * east1"} + * @param labels labels or {@code null} for none + */ + public Location setLabels(java.util.Map labels) { + this.labels = labels; + return this; + } + + /** + * The canonical id for this location. For example: `"us-east1"`. + * @return value or {@code null} for none + */ + public java.lang.String getLocationId() { + return locationId; + } + + /** + * The canonical id for this location. For example: `"us-east1"`. + * @param locationId locationId or {@code null} for none + */ + public Location setLocationId(java.lang.String locationId) { + this.locationId = locationId; + return this; + } + + /** + * Service-specific metadata. For example the available capacity at the given location. + * @return value or {@code null} for none + */ + public java.util.Map getMetadata() { + return metadata; + } + + /** + * Service-specific metadata. For example the available capacity at the given location. + * @param metadata metadata or {@code null} for none + */ + public Location setMetadata(java.util.Map metadata) { + this.metadata = metadata; + return this; + } + + /** + * Resource name for the location, which may vary between implementations. For example: + * `"projects/example-project/locations/us-east1"` + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * Resource name for the location, which may vary between implementations. For example: + * `"projects/example-project/locations/us-east1"` + * @param name name or {@code null} for none + */ + public Location setName(java.lang.String name) { + this.name = name; + return this; + } + + @Override + public Location set(String fieldName, Object value) { + return (Location) super.set(fieldName, value); + } + + @Override + public Location clone() { + return (Location) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Operation.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Operation.java new file mode 100644 index 00000000000..1f2e64fa3fe --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Operation.java @@ -0,0 +1,195 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * This resource represents a long-running operation that is the result of a network API call. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Operation extends com.google.api.client.json.GenericJson { + + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation + * is completed, and either `error` or `response` is available. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Boolean done; + + /** + * The error result of the operation in case of failure or cancellation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private Status error; + + /** + * Service-specific metadata associated with the operation. It typically contains progress + * information and common metadata such as create time. Some services might not provide such + * metadata. Any method that returns a long-running operation should document the metadata type, + * if any. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map metadata; + + /** + * The server-assigned name, which is only unique within the same service that originally returns + * it. If you use the default HTTP mapping, the `name` should be a resource name ending with + * `operations/{unique_id}`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * The normal, successful response of the operation. If the original method returns no data on + * success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is + * standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the + * response should have the type `XxxResponse`, where `Xxx` is the original method name. For + * example, if the original method name is `TakeSnapshot()`, the inferred response type is + * `TakeSnapshotResponse`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map response; + + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation + * is completed, and either `error` or `response` is available. + * @return value or {@code null} for none + */ + public java.lang.Boolean getDone() { + return done; + } + + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation + * is completed, and either `error` or `response` is available. + * @param done done or {@code null} for none + */ + public Operation setDone(java.lang.Boolean done) { + this.done = done; + return this; + } + + /** + * The error result of the operation in case of failure or cancellation. + * @return value or {@code null} for none + */ + public Status getError() { + return error; + } + + /** + * The error result of the operation in case of failure or cancellation. + * @param error error or {@code null} for none + */ + public Operation setError(Status error) { + this.error = error; + return this; + } + + /** + * Service-specific metadata associated with the operation. It typically contains progress + * information and common metadata such as create time. Some services might not provide such + * metadata. Any method that returns a long-running operation should document the metadata type, + * if any. + * @return value or {@code null} for none + */ + public java.util.Map getMetadata() { + return metadata; + } + + /** + * Service-specific metadata associated with the operation. It typically contains progress + * information and common metadata such as create time. Some services might not provide such + * metadata. Any method that returns a long-running operation should document the metadata type, + * if any. + * @param metadata metadata or {@code null} for none + */ + public Operation setMetadata(java.util.Map metadata) { + this.metadata = metadata; + return this; + } + + /** + * The server-assigned name, which is only unique within the same service that originally returns + * it. If you use the default HTTP mapping, the `name` should be a resource name ending with + * `operations/{unique_id}`. + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * The server-assigned name, which is only unique within the same service that originally returns + * it. If you use the default HTTP mapping, the `name` should be a resource name ending with + * `operations/{unique_id}`. + * @param name name or {@code null} for none + */ + public Operation setName(java.lang.String name) { + this.name = name; + return this; + } + + /** + * The normal, successful response of the operation. If the original method returns no data on + * success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is + * standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the + * response should have the type `XxxResponse`, where `Xxx` is the original method name. For + * example, if the original method name is `TakeSnapshot()`, the inferred response type is + * `TakeSnapshotResponse`. + * @return value or {@code null} for none + */ + public java.util.Map getResponse() { + return response; + } + + /** + * The normal, successful response of the operation. If the original method returns no data on + * success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is + * standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the + * response should have the type `XxxResponse`, where `Xxx` is the original method name. For + * example, if the original method name is `TakeSnapshot()`, the inferred response type is + * `TakeSnapshotResponse`. + * @param response response or {@code null} for none + */ + public Operation setResponse(java.util.Map response) { + this.response = response; + return this; + } + + @Override + public Operation set(String fieldName, Object value) { + return (Operation) super.set(fieldName, value); + } + + @Override + public Operation clone() { + return (Operation) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/OperationMetadata.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/OperationMetadata.java new file mode 100644 index 00000000000..74deb222fd4 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/OperationMetadata.java @@ -0,0 +1,213 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Metadata for the long-running operation. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class OperationMetadata extends com.google.api.client.json.GenericJson { + + /** + * Output only. The API version used to start the operation. For example, `v1`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String apiVersion; + + /** + * Output only. Time that the operation was created. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String createTime; + + /** + * Output only. Time that the operation finished running. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String endTime; + + /** + * Output only. Whether you requested that the operation be cancelled. Operations that were + * cancelled successfully have an Operation.error value with a status code Code.CANCELLED. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Boolean requestedCancellation; + + /** + * Output only. A human-readable status of the operation, if any. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String statusMessage; + + /** + * Output only. A server-defined resource path for the target of the operation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String target; + + /** + * Output only. The name of the verb that was executed by the operation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String verb; + + /** + * Output only. The API version used to start the operation. For example, `v1`. + * @return value or {@code null} for none + */ + public java.lang.String getApiVersion() { + return apiVersion; + } + + /** + * Output only. The API version used to start the operation. For example, `v1`. + * @param apiVersion apiVersion or {@code null} for none + */ + public OperationMetadata setApiVersion(java.lang.String apiVersion) { + this.apiVersion = apiVersion; + return this; + } + + /** + * Output only. Time that the operation was created. + * @return value or {@code null} for none + */ + public String getCreateTime() { + return createTime; + } + + /** + * Output only. Time that the operation was created. + * @param createTime createTime or {@code null} for none + */ + public OperationMetadata setCreateTime(String createTime) { + this.createTime = createTime; + return this; + } + + /** + * Output only. Time that the operation finished running. + * @return value or {@code null} for none + */ + public String getEndTime() { + return endTime; + } + + /** + * Output only. Time that the operation finished running. + * @param endTime endTime or {@code null} for none + */ + public OperationMetadata setEndTime(String endTime) { + this.endTime = endTime; + return this; + } + + /** + * Output only. Whether you requested that the operation be cancelled. Operations that were + * cancelled successfully have an Operation.error value with a status code Code.CANCELLED. + * @return value or {@code null} for none + */ + public java.lang.Boolean getRequestedCancellation() { + return requestedCancellation; + } + + /** + * Output only. Whether you requested that the operation be cancelled. Operations that were + * cancelled successfully have an Operation.error value with a status code Code.CANCELLED. + * @param requestedCancellation requestedCancellation or {@code null} for none + */ + public OperationMetadata setRequestedCancellation(java.lang.Boolean requestedCancellation) { + this.requestedCancellation = requestedCancellation; + return this; + } + + /** + * Output only. A human-readable status of the operation, if any. + * @return value or {@code null} for none + */ + public java.lang.String getStatusMessage() { + return statusMessage; + } + + /** + * Output only. A human-readable status of the operation, if any. + * @param statusMessage statusMessage or {@code null} for none + */ + public OperationMetadata setStatusMessage(java.lang.String statusMessage) { + this.statusMessage = statusMessage; + return this; + } + + /** + * Output only. A server-defined resource path for the target of the operation. + * @return value or {@code null} for none + */ + public java.lang.String getTarget() { + return target; + } + + /** + * Output only. A server-defined resource path for the target of the operation. + * @param target target or {@code null} for none + */ + public OperationMetadata setTarget(java.lang.String target) { + this.target = target; + return this; + } + + /** + * Output only. The name of the verb that was executed by the operation. + * @return value or {@code null} for none + */ + public java.lang.String getVerb() { + return verb; + } + + /** + * Output only. The name of the verb that was executed by the operation. + * @param verb verb or {@code null} for none + */ + public OperationMetadata setVerb(java.lang.String verb) { + this.verb = verb; + return this; + } + + @Override + public OperationMetadata set(String fieldName, Object value) { + return (OperationMetadata) super.set(fieldName, value); + } + + @Override + public OperationMetadata clone() { + return (OperationMetadata) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ReportGenerationProgress.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ReportGenerationProgress.java new file mode 100644 index 00000000000..fd80845c61d --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ReportGenerationProgress.java @@ -0,0 +1,222 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Details about the current status of the report-generation process. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ReportGenerationProgress extends com.google.api.client.json.GenericJson { + + /** + * Output only. Name of the audit report. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String auditReport; + + /** + * Output only. Cloud Storage bucket where the audit report is uploaded to after the evaluation + * process is completed. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String destinationGcsBucket; + + /** + * Progress of the evaluation process. The progress is defined in terms of percentage complete. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Double evaluationPercentComplete; + + /** + * Output only. Reason for failure during the audit report generation process. This field is set + * only if the `OperationState` attribute is `OPERATION_STATE_FAILED`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String failureReason; + + /** + * Report generation progress, defined in terms of percentage complete. Until evaluation is + * complete, this value is always `0`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Double reportGenerationPercentComplete; + + /** + * Report uploading progress, defined in terms of percentage complete. Until evaluation and report + * generation are complete, this value is always `0`. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Double reportUploadingPercentComplete; + + /** + * Output only. Current state of execution for report generation. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String state; + + /** + * Output only. Name of the audit report. + * @return value or {@code null} for none + */ + public java.lang.String getAuditReport() { + return auditReport; + } + + /** + * Output only. Name of the audit report. + * @param auditReport auditReport or {@code null} for none + */ + public ReportGenerationProgress setAuditReport(java.lang.String auditReport) { + this.auditReport = auditReport; + return this; + } + + /** + * Output only. Cloud Storage bucket where the audit report is uploaded to after the evaluation + * process is completed. + * @return value or {@code null} for none + */ + public java.lang.String getDestinationGcsBucket() { + return destinationGcsBucket; + } + + /** + * Output only. Cloud Storage bucket where the audit report is uploaded to after the evaluation + * process is completed. + * @param destinationGcsBucket destinationGcsBucket or {@code null} for none + */ + public ReportGenerationProgress setDestinationGcsBucket(java.lang.String destinationGcsBucket) { + this.destinationGcsBucket = destinationGcsBucket; + return this; + } + + /** + * Progress of the evaluation process. The progress is defined in terms of percentage complete. + * @return value or {@code null} for none + */ + public java.lang.Double getEvaluationPercentComplete() { + return evaluationPercentComplete; + } + + /** + * Progress of the evaluation process. The progress is defined in terms of percentage complete. + * @param evaluationPercentComplete evaluationPercentComplete or {@code null} for none + */ + public ReportGenerationProgress setEvaluationPercentComplete(java.lang.Double evaluationPercentComplete) { + this.evaluationPercentComplete = evaluationPercentComplete; + return this; + } + + /** + * Output only. Reason for failure during the audit report generation process. This field is set + * only if the `OperationState` attribute is `OPERATION_STATE_FAILED`. + * @return value or {@code null} for none + */ + public java.lang.String getFailureReason() { + return failureReason; + } + + /** + * Output only. Reason for failure during the audit report generation process. This field is set + * only if the `OperationState` attribute is `OPERATION_STATE_FAILED`. + * @param failureReason failureReason or {@code null} for none + */ + public ReportGenerationProgress setFailureReason(java.lang.String failureReason) { + this.failureReason = failureReason; + return this; + } + + /** + * Report generation progress, defined in terms of percentage complete. Until evaluation is + * complete, this value is always `0`. + * @return value or {@code null} for none + */ + public java.lang.Double getReportGenerationPercentComplete() { + return reportGenerationPercentComplete; + } + + /** + * Report generation progress, defined in terms of percentage complete. Until evaluation is + * complete, this value is always `0`. + * @param reportGenerationPercentComplete reportGenerationPercentComplete or {@code null} for none + */ + public ReportGenerationProgress setReportGenerationPercentComplete(java.lang.Double reportGenerationPercentComplete) { + this.reportGenerationPercentComplete = reportGenerationPercentComplete; + return this; + } + + /** + * Report uploading progress, defined in terms of percentage complete. Until evaluation and report + * generation are complete, this value is always `0`. + * @return value or {@code null} for none + */ + public java.lang.Double getReportUploadingPercentComplete() { + return reportUploadingPercentComplete; + } + + /** + * Report uploading progress, defined in terms of percentage complete. Until evaluation and report + * generation are complete, this value is always `0`. + * @param reportUploadingPercentComplete reportUploadingPercentComplete or {@code null} for none + */ + public ReportGenerationProgress setReportUploadingPercentComplete(java.lang.Double reportUploadingPercentComplete) { + this.reportUploadingPercentComplete = reportUploadingPercentComplete; + return this; + } + + /** + * Output only. Current state of execution for report generation. + * @return value or {@code null} for none + */ + public java.lang.String getState() { + return state; + } + + /** + * Output only. Current state of execution for report generation. + * @param state state or {@code null} for none + */ + public ReportGenerationProgress setState(java.lang.String state) { + this.state = state; + return this; + } + + @Override + public ReportGenerationProgress set(String fieldName, Object value) { + return (ReportGenerationProgress) super.set(fieldName, value); + } + + @Override + public ReportGenerationProgress clone() { + return (ReportGenerationProgress) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ReportSummary.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ReportSummary.java new file mode 100644 index 00000000000..335210ecd8b --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ReportSummary.java @@ -0,0 +1,162 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * Additional information about the number of checks that were made during an audit operation. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ReportSummary extends com.google.api.client.json.GenericJson { + + /** + * Number of compliant checks. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Integer compliantCount; + + /** + * Number of checks that can't be performed due to errors. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Integer errorCount; + + /** + * Number of checks that require a manual review. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Integer manualReviewNeededCount; + + /** + * Total number of evaluated checks. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Integer totalCount; + + /** + * Number of checks with violations. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Integer violationCount; + + /** + * Number of compliant checks. + * @return value or {@code null} for none + */ + public java.lang.Integer getCompliantCount() { + return compliantCount; + } + + /** + * Number of compliant checks. + * @param compliantCount compliantCount or {@code null} for none + */ + public ReportSummary setCompliantCount(java.lang.Integer compliantCount) { + this.compliantCount = compliantCount; + return this; + } + + /** + * Number of checks that can't be performed due to errors. + * @return value or {@code null} for none + */ + public java.lang.Integer getErrorCount() { + return errorCount; + } + + /** + * Number of checks that can't be performed due to errors. + * @param errorCount errorCount or {@code null} for none + */ + public ReportSummary setErrorCount(java.lang.Integer errorCount) { + this.errorCount = errorCount; + return this; + } + + /** + * Number of checks that require a manual review. + * @return value or {@code null} for none + */ + public java.lang.Integer getManualReviewNeededCount() { + return manualReviewNeededCount; + } + + /** + * Number of checks that require a manual review. + * @param manualReviewNeededCount manualReviewNeededCount or {@code null} for none + */ + public ReportSummary setManualReviewNeededCount(java.lang.Integer manualReviewNeededCount) { + this.manualReviewNeededCount = manualReviewNeededCount; + return this; + } + + /** + * Total number of evaluated checks. + * @return value or {@code null} for none + */ + public java.lang.Integer getTotalCount() { + return totalCount; + } + + /** + * Total number of evaluated checks. + * @param totalCount totalCount or {@code null} for none + */ + public ReportSummary setTotalCount(java.lang.Integer totalCount) { + this.totalCount = totalCount; + return this; + } + + /** + * Number of checks with violations. + * @return value or {@code null} for none + */ + public java.lang.Integer getViolationCount() { + return violationCount; + } + + /** + * Number of checks with violations. + * @param violationCount violationCount or {@code null} for none + */ + public ReportSummary setViolationCount(java.lang.Integer violationCount) { + this.violationCount = violationCount; + return this; + } + + @Override + public ReportSummary set(String fieldName, Object value) { + return (ReportSummary) super.set(fieldName, value); + } + + @Override + public ReportSummary clone() { + return (ReportSummary) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ResourceEnrollmentStatus.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ResourceEnrollmentStatus.java new file mode 100644 index 00000000000..d5716c34d18 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/ResourceEnrollmentStatus.java @@ -0,0 +1,177 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * An organization, folder, or project with its enrollment status. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ResourceEnrollmentStatus extends com.google.api.client.json.GenericJson { + + /** + * Output only. Display name for the organization, folder, or project. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String displayName; + + /** + * Output only. Deprecated. Whether the organization, folder, or project is enrolled. Use + * `enrollment_state` instead. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Boolean enrolled; + + /** + * Output only. Enrolled destination details for the organization, folder, or project. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private Enrollment enrollment; + + /** + * Output only. Enrollment state of the organization, folder, or project. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String enrollmentState; + + /** + * Identifier. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` + * * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_stat + * us}` * `organizations/{organization}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * Output only. Display name for the organization, folder, or project. + * @return value or {@code null} for none + */ + public java.lang.String getDisplayName() { + return displayName; + } + + /** + * Output only. Display name for the organization, folder, or project. + * @param displayName displayName or {@code null} for none + */ + public ResourceEnrollmentStatus setDisplayName(java.lang.String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Output only. Deprecated. Whether the organization, folder, or project is enrolled. Use + * `enrollment_state` instead. + * @return value or {@code null} for none + */ + public java.lang.Boolean getEnrolled() { + return enrolled; + } + + /** + * Output only. Deprecated. Whether the organization, folder, or project is enrolled. Use + * `enrollment_state` instead. + * @param enrolled enrolled or {@code null} for none + */ + public ResourceEnrollmentStatus setEnrolled(java.lang.Boolean enrolled) { + this.enrolled = enrolled; + return this; + } + + /** + * Output only. Enrolled destination details for the organization, folder, or project. + * @return value or {@code null} for none + */ + public Enrollment getEnrollment() { + return enrollment; + } + + /** + * Output only. Enrolled destination details for the organization, folder, or project. + * @param enrollment enrollment or {@code null} for none + */ + public ResourceEnrollmentStatus setEnrollment(Enrollment enrollment) { + this.enrollment = enrollment; + return this; + } + + /** + * Output only. Enrollment state of the organization, folder, or project. + * @return value or {@code null} for none + */ + public java.lang.String getEnrollmentState() { + return enrollmentState; + } + + /** + * Output only. Enrollment state of the organization, folder, or project. + * @param enrollmentState enrollmentState or {@code null} for none + */ + public ResourceEnrollmentStatus setEnrollmentState(java.lang.String enrollmentState) { + this.enrollmentState = enrollmentState; + return this; + } + + /** + * Identifier. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` + * * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_stat + * us}` * `organizations/{organization}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * Identifier. Name of the resource enrollment status, in one of the following formats: * + * `folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_status}` + * * `projects/{project}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_stat + * us}` * `organizations/{organization}/locations/{location}/resourceEnrollmentStatuses/{resource_ + * enrollment_status}` + * @param name name or {@code null} for none + */ + public ResourceEnrollmentStatus setName(java.lang.String name) { + this.name = name; + return this; + } + + @Override + public ResourceEnrollmentStatus set(String fieldName, Object value) { + return (ResourceEnrollmentStatus) super.set(fieldName, value); + } + + @Override + public ResourceEnrollmentStatus clone() { + return (ResourceEnrollmentStatus) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Status.java b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Status.java new file mode 100644 index 00000000000..b7097dd1c49 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/com/google/api/services/auditmanager/v1/model/Status.java @@ -0,0 +1,127 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.auditmanager.v1.model; + +/** + * The `Status` type defines a logical error model that is suitable for different programming + * environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). + * Each `Status` message contains three pieces of data: error code, error message, and error + * details. You can find out more about this error model and how to work with it in the [API Design + * Guide](https://cloud.google.com/apis/design/errors). + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Audit Manager API. For a detailed explanation see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Status extends com.google.api.client.json.GenericJson { + + /** + * The status code, which should be an enum value of google.rpc.Code. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.Integer code; + + /** + * A list of messages that carry the error details. There is a common set of message types for + * APIs to use. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List> details; + + /** + * A developer-facing error message, which should be in English. Any user-facing error message + * should be localized and sent in the google.rpc.Status.details field, or localized by the + * client. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String message; + + /** + * The status code, which should be an enum value of google.rpc.Code. + * @return value or {@code null} for none + */ + public java.lang.Integer getCode() { + return code; + } + + /** + * The status code, which should be an enum value of google.rpc.Code. + * @param code code or {@code null} for none + */ + public Status setCode(java.lang.Integer code) { + this.code = code; + return this; + } + + /** + * A list of messages that carry the error details. There is a common set of message types for + * APIs to use. + * @return value or {@code null} for none + */ + public java.util.List> getDetails() { + return details; + } + + /** + * A list of messages that carry the error details. There is a common set of message types for + * APIs to use. + * @param details details or {@code null} for none + */ + public Status setDetails(java.util.List> details) { + this.details = details; + return this; + } + + /** + * A developer-facing error message, which should be in English. Any user-facing error message + * should be localized and sent in the google.rpc.Status.details field, or localized by the + * client. + * @return value or {@code null} for none + */ + public java.lang.String getMessage() { + return message; + } + + /** + * A developer-facing error message, which should be in English. Any user-facing error message + * should be localized and sent in the google.rpc.Status.details field, or localized by the + * client. + * @param message message or {@code null} for none + */ + public Status setMessage(java.lang.String message) { + this.message = message; + return this; + } + + @Override + public Status set(String fieldName, Object value) { + return (Status) super.set(fieldName, value); + } + + @Override + public Status clone() { + return (Status) super.clone(); + } + +} diff --git a/clients/google-api-services-auditmanager/v1/2.0.0/pom.xml b/clients/google-api-services-auditmanager/v1/2.0.0/pom.xml new file mode 100644 index 00000000000..a1e131c0445 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/2.0.0/pom.xml @@ -0,0 +1,219 @@ + + 4.0.0 + + org.sonatype.oss + oss-parent + 7 + + + com.google.apis + google-api-services-auditmanager + v1-rev20260826-2.0.0 + Audit Manager API v1-rev20260826-2.0.0 + jar + + 2011 + + + + GoogleAPIs + GoogleAPIs + googleapis@googlegroups.com + Google + https://www.google.com + + + + + Google + http://www.google.com/ + + + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + + + ossrh + https://google.oss.sonatype.org/content/repositories/snapshots + + + + + + + maven-compiler-plugin + 3.9.0 + + 1.7 + 1.7 + + + + org.apache.maven.plugins + maven-source-plugin + 2.4 + + + org.apache.maven.plugins + maven-jar-plugin + 3.1.2 + + + + com.google.api.services.auditmanager + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 3.1.0 + + + attach-javadocs + + jar + + + + + none + Audit Manager API ${project.version} + Audit Manager API ${project.version} + + http://docs.oracle.com/javase/7/docs/api + https://googleapis.dev/java/google-http-client/${httpClientLibrary}/ + https://googleapis.dev/java/google-oauth-client/${oauthClientLibrary}/ + https://googleapis.dev/java/google-api-client/2.7.2/ + + + + + org.codehaus.mojo + clirr-maven-plugin + 2.8 + + clirr-ignored-differences.xml + true + + + + + check + + + + + + . + + + ./resources + + + + + + + com.google.api-client + google-api-client + 2.7.2 + + + + + UTF-8 + + + + + + release-sonatype + + + + !artifact-registry-url + + + + + + org.sonatype.plugins + nexus-staging-maven-plugin + 1.6.13 + true + + sonatype-nexus-staging + https://google.oss.sonatype.org/ + false + + + + + + + + release-gcp-artifact-registry + + artifactregistry://please-define-artifact-registry-url-property + + + + gcp-artifact-registry-repository + ${artifact-registry-url} + + + gcp-artifact-registry-repository + ${artifact-registry-url} + + + + + release-sign-artifacts + + + performRelease + true + + + + + + org.apache.maven.plugins + maven-gpg-plugin + 3.2.7 + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + + + + \ No newline at end of file diff --git a/clients/google-api-services-auditmanager/v1/README.md b/clients/google-api-services-auditmanager/v1/README.md new file mode 100644 index 00000000000..e0ac2231cb1 --- /dev/null +++ b/clients/google-api-services-auditmanager/v1/README.md @@ -0,0 +1,44 @@ +# Audit Manager API Client Library for Java + +The Audit Manager API allows customers to manage compliance audits. + +This page contains information about getting started with the Audit Manager API +using the Google API Client Library for Java. In addition, you may be interested +in the following documentation: + +* Browse the [Javadoc reference for the Audit Manager API][javadoc] +* Read the [Developer's Guide for the Google API Client Library for Java][google-api-client]. +* Interact with this API in your browser using the [APIs Explorer for the Audit Manager API][api-explorer] + +## Installation + +### Maven + +Add the following lines to your `pom.xml` file: + +```xml + + + + com.google.apis + google-api-services-auditmanager + v1-rev20260826-2.0.0 + + + +``` + +### Gradle + +```gradle +repositories { + mavenCentral() +} +dependencies { + implementation 'com.google.apis:google-api-services-auditmanager:v1-rev20260826-2.0.0' +} +``` + +[javadoc]: https://googleapis.dev/java/google-api-services-auditmanager/latest/index.html +[google-api-client]: https://github.com/googleapis/google-api-java-client/ +[api-explorer]: https://developers.google.com/apis-explorer/#p/auditmanager/v1/