All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.google.api.services.eventarc.v1.Eventarc Maven / Gradle / Ivy

There is a newer version: v1-rev20250103-2.0.0
Show newest version
/*
 * 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.eventarc.v1;

/**
 * Service definition for Eventarc (v1).
 *
 * 

* Build event-driven applications on Google Cloud Platform. *

* *

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

* *

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

* * @since 1.3 * @author Google, Inc. */ @SuppressWarnings("javadoc") public class Eventarc 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 Eventarc 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://eventarc.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://eventarc.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: *
    *
  • 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: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()} *
  • *
* @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 Eventarc(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 */ Eventarc(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 Projects collection. * *

The typical use is:

*
   *   {@code Eventarc eventarc = new Eventarc(...);}
   *   {@code Eventarc.Projects.List request = eventarc.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 Eventarc eventarc = new Eventarc(...);}
     *   {@code Eventarc.Locations.List request = eventarc.locations().list(parameters ...)}
     * 
* * @return the resource collection */ public Locations locations() { return new Locations(); } /** * The "locations" collection of methods. */ public class Locations { /** * Gets information about a location. * * Create a request for the method "locations.get". * * This request holds the parameters needed by the eventarc 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 EventarcRequest { 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 eventarc 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(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.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); } } /** * Get a GoogleChannelConfig * * Create a request for the method "locations.getGoogleChannelConfig". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetGoogleChannelConfig#execute()} method to invoke the remote * operation. * * @param name Required. The name of the config to get. * @return the request */ public GetGoogleChannelConfig getGoogleChannelConfig(java.lang.String name) throws java.io.IOException { GetGoogleChannelConfig result = new GetGoogleChannelConfig(name); initialize(result); return result; } public class GetGoogleChannelConfig extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleChannelConfig$"); /** * Get a GoogleChannelConfig * * Create a request for the method "locations.getGoogleChannelConfig". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetGoogleChannelConfig#execute()} method to invoke the * remote operation.

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

* * @param name Required. The name of the config to get. * @since 1.13 */ protected GetGoogleChannelConfig(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleChannelConfig.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/[^/]+/googleChannelConfig$"); } } @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 GetGoogleChannelConfig set$Xgafv(java.lang.String $Xgafv) { return (GetGoogleChannelConfig) super.set$Xgafv($Xgafv); } @Override public GetGoogleChannelConfig setAccessToken(java.lang.String accessToken) { return (GetGoogleChannelConfig) super.setAccessToken(accessToken); } @Override public GetGoogleChannelConfig setAlt(java.lang.String alt) { return (GetGoogleChannelConfig) super.setAlt(alt); } @Override public GetGoogleChannelConfig setCallback(java.lang.String callback) { return (GetGoogleChannelConfig) super.setCallback(callback); } @Override public GetGoogleChannelConfig setFields(java.lang.String fields) { return (GetGoogleChannelConfig) super.setFields(fields); } @Override public GetGoogleChannelConfig setKey(java.lang.String key) { return (GetGoogleChannelConfig) super.setKey(key); } @Override public GetGoogleChannelConfig setOauthToken(java.lang.String oauthToken) { return (GetGoogleChannelConfig) super.setOauthToken(oauthToken); } @Override public GetGoogleChannelConfig setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetGoogleChannelConfig) super.setPrettyPrint(prettyPrint); } @Override public GetGoogleChannelConfig setQuotaUser(java.lang.String quotaUser) { return (GetGoogleChannelConfig) super.setQuotaUser(quotaUser); } @Override public GetGoogleChannelConfig setUploadType(java.lang.String uploadType) { return (GetGoogleChannelConfig) super.setUploadType(uploadType); } @Override public GetGoogleChannelConfig setUploadProtocol(java.lang.String uploadProtocol) { return (GetGoogleChannelConfig) super.setUploadProtocol(uploadProtocol); } /** Required. The name of the config to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the config to get. */ public java.lang.String getName() { return name; } /** Required. The name of the config to get. */ public GetGoogleChannelConfig 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/[^/]+/googleChannelConfig$"); } this.name = name; return this; } @Override public GetGoogleChannelConfig set(String parameterName, Object value) { return (GetGoogleChannelConfig) super.set(parameterName, value); } } /** * Lists information about the supported locations for this service. * * Create a request for the method "locations.list". * * This request holds the parameters needed by the eventarc 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 EventarcRequest { 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. * * Create a request for the method "locations.list". * * This request holds the parameters needed by the the eventarc 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(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.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; } /** * 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); } } /** * Update a single GoogleChannelConfig * * Create a request for the method "locations.updateGoogleChannelConfig". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link UpdateGoogleChannelConfig#execute()} method to invoke the remote * operation. * * @param name Required. The resource name of the config. Must be in the format of, * `projects/{project}/locations/{location}/googleChannelConfig`. * @param content the {@link com.google.api.services.eventarc.v1.model.GoogleChannelConfig} * @return the request */ public UpdateGoogleChannelConfig updateGoogleChannelConfig(java.lang.String name, com.google.api.services.eventarc.v1.model.GoogleChannelConfig content) throws java.io.IOException { UpdateGoogleChannelConfig result = new UpdateGoogleChannelConfig(name, content); initialize(result); return result; } public class UpdateGoogleChannelConfig extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleChannelConfig$"); /** * Update a single GoogleChannelConfig * * Create a request for the method "locations.updateGoogleChannelConfig". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link UpdateGoogleChannelConfig#execute()} method to invoke the * remote operation.

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

* * @param name Required. The resource name of the config. Must be in the format of, * `projects/{project}/locations/{location}/googleChannelConfig`. * @param content the {@link com.google.api.services.eventarc.v1.model.GoogleChannelConfig} * @since 1.13 */ protected UpdateGoogleChannelConfig(java.lang.String name, com.google.api.services.eventarc.v1.model.GoogleChannelConfig content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleChannelConfig.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/[^/]+/googleChannelConfig$"); } } @Override public UpdateGoogleChannelConfig set$Xgafv(java.lang.String $Xgafv) { return (UpdateGoogleChannelConfig) super.set$Xgafv($Xgafv); } @Override public UpdateGoogleChannelConfig setAccessToken(java.lang.String accessToken) { return (UpdateGoogleChannelConfig) super.setAccessToken(accessToken); } @Override public UpdateGoogleChannelConfig setAlt(java.lang.String alt) { return (UpdateGoogleChannelConfig) super.setAlt(alt); } @Override public UpdateGoogleChannelConfig setCallback(java.lang.String callback) { return (UpdateGoogleChannelConfig) super.setCallback(callback); } @Override public UpdateGoogleChannelConfig setFields(java.lang.String fields) { return (UpdateGoogleChannelConfig) super.setFields(fields); } @Override public UpdateGoogleChannelConfig setKey(java.lang.String key) { return (UpdateGoogleChannelConfig) super.setKey(key); } @Override public UpdateGoogleChannelConfig setOauthToken(java.lang.String oauthToken) { return (UpdateGoogleChannelConfig) super.setOauthToken(oauthToken); } @Override public UpdateGoogleChannelConfig setPrettyPrint(java.lang.Boolean prettyPrint) { return (UpdateGoogleChannelConfig) super.setPrettyPrint(prettyPrint); } @Override public UpdateGoogleChannelConfig setQuotaUser(java.lang.String quotaUser) { return (UpdateGoogleChannelConfig) super.setQuotaUser(quotaUser); } @Override public UpdateGoogleChannelConfig setUploadType(java.lang.String uploadType) { return (UpdateGoogleChannelConfig) super.setUploadType(uploadType); } @Override public UpdateGoogleChannelConfig setUploadProtocol(java.lang.String uploadProtocol) { return (UpdateGoogleChannelConfig) super.setUploadProtocol(uploadProtocol); } /** * Required. The resource name of the config. Must be in the format of, * `projects/{project}/locations/{location}/googleChannelConfig`. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The resource name of the config. Must be in the format of, `projects/{project}/locations/{location}/googleChannelConfig`. */ public java.lang.String getName() { return name; } /** * Required. The resource name of the config. Must be in the format of, * `projects/{project}/locations/{location}/googleChannelConfig`. */ public UpdateGoogleChannelConfig 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/[^/]+/googleChannelConfig$"); } this.name = name; return this; } /** * The fields to be updated; only fields explicitly provided are updated. If no field mask * is provided, all provided fields in the request are updated. To update all fields, * provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * The fields to be updated; only fields explicitly provided are updated. If no field mask * is provided, all provided fields in the request are updated. To update all fields, * provide a field mask of "*". */ public UpdateGoogleChannelConfig setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } @Override public UpdateGoogleChannelConfig set(String parameterName, Object value) { return (UpdateGoogleChannelConfig) super.set(parameterName, value); } } /** * An accessor for creating requests from the ChannelConnections collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.ChannelConnections.List request = eventarc.channelConnections().list(parameters ...)}
       * 
* * @return the resource collection */ public ChannelConnections channelConnections() { return new ChannelConnections(); } /** * The "channelConnections" collection of methods. */ public class ChannelConnections { /** * Create a new ChannelConnection in a particular project and location. * * Create a request for the method "channelConnections.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this channel connection. * @param content the {@link com.google.api.services.eventarc.v1.model.ChannelConnection} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.ChannelConnection content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/channelConnections"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new ChannelConnection in a particular project and location. * * Create a request for the method "channelConnections.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this channel connection. * @param content the {@link com.google.api.services.eventarc.v1.model.ChannelConnection} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.ChannelConnection content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this channel connection. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this channel connection. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this channel connection. */ public Create 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; } /** Required. The user-provided ID to be assigned to the channel connection. */ @com.google.api.client.util.Key private java.lang.String channelConnectionId; /** Required. The user-provided ID to be assigned to the channel connection. */ public java.lang.String getChannelConnectionId() { return channelConnectionId; } /** Required. The user-provided ID to be assigned to the channel connection. */ public Create setChannelConnectionId(java.lang.String channelConnectionId) { this.channelConnectionId = channelConnectionId; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single ChannelConnection. * * Create a request for the method "channelConnections.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the channel connection to delete. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); /** * Delete a single ChannelConnection. * * Create a request for the method "channelConnections.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the channel connection to delete. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/channelConnections/[^/]+$"); } } @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); } /** Required. The name of the channel connection to delete. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the channel connection to delete. */ public java.lang.String getName() { return name; } /** Required. The name of the channel connection to delete. */ 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/[^/]+/channelConnections/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single ChannelConnection. * * Create a request for the method "channelConnections.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the channel connection to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); /** * Get a single ChannelConnection. * * Create a request for the method "channelConnections.get". * * This request holds the parameters needed by the the eventarc 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. The name of the channel connection to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ChannelConnection.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/[^/]+/channelConnections/[^/]+$"); } } @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. The name of the channel connection to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the channel connection to get. */ public java.lang.String getName() { return name; } /** Required. The name of the channel connection to get. */ 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/[^/]+/channelConnections/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "channelConnections.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "channelConnections.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List channel connections. * * Create a request for the method "channelConnections.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection from which to list channel connections. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/channelConnections"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List channel connections. * * Create a request for the method "channelConnections.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection from which to list channel connections. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListChannelConnectionsResponse.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. The parent collection from which to list channel connections. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection from which to list channel connections. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection from which to list channel connections. */ 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; } /** * The maximum number of channel connections to return on each page. Note: The service may * send fewer responses. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The maximum number of channel connections to return on each page. Note: The service may send fewer responses. */ public java.lang.Integer getPageSize() { return pageSize; } /** * The maximum number of channel connections to return on each page. Note: The service may * send fewer responses. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListChannelConnections` call to retrieve the subsequent page. When paginating, all * other parameters provided to `ListChannelConnetions` match the call that provided the * page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The page token; provide the value from the `next_page_token` field in a previous `ListChannelConnections` call to retrieve the subsequent page. When paginating, all other parameters provided to `ListChannelConnetions` match the call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListChannelConnections` call to retrieve the subsequent page. When paginating, all * other parameters provided to `ListChannelConnetions` match the call that provided the * page token. */ 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); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "channelConnections.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "channelConnections.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "channelConnections.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "channelConnections.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channelConnections/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } /** * An accessor for creating requests from the Channels collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.Channels.List request = eventarc.channels().list(parameters ...)}
       * 
* * @return the resource collection */ public Channels channels() { return new Channels(); } /** * The "channels" collection of methods. */ public class Channels { /** * Create a new channel in a particular project and location. * * Create a request for the method "channels.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this channel. * @param content the {@link com.google.api.services.eventarc.v1.model.Channel} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Channel content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/channels"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new channel in a particular project and location. * * Create a request for the method "channels.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this channel. * @param content the {@link com.google.api.services.eventarc.v1.model.Channel} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Channel content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this channel. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this channel. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this channel. */ public Create 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; } /** Required. The user-provided ID to be assigned to the channel. */ @com.google.api.client.util.Key private java.lang.String channelId; /** Required. The user-provided ID to be assigned to the channel. */ public java.lang.String getChannelId() { return channelId; } /** Required. The user-provided ID to be assigned to the channel. */ public Create setChannelId(java.lang.String channelId) { this.channelId = channelId; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Create setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single channel. * * Create a request for the method "channels.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the channel 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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); /** * Delete a single channel. * * Create a request for the method "channels.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the channel to be deleted. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/channels/[^/]+$"); } } @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); } /** Required. The name of the channel to be deleted. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the channel to be deleted. */ public java.lang.String getName() { return name; } /** Required. The name of the channel 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/[^/]+/channels/[^/]+$"); } this.name = name; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Delete setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single Channel. * * Create a request for the method "channels.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the channel to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); /** * Get a single Channel. * * Create a request for the method "channels.get". * * This request holds the parameters needed by the the eventarc 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. The name of the channel to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Channel.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/[^/]+/channels/[^/]+$"); } } @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. The name of the channel to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the channel to get. */ public java.lang.String getName() { return name; } /** Required. The name of the channel to get. */ 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/[^/]+/channels/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "channels.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "channels.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List channels. * * Create a request for the method "channels.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection to list channels on. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/channels"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List channels. * * Create a request for the method "channels.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection to list channels on. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListChannelsResponse.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. The parent collection to list channels on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection to list channels on. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection to list channels on. */ 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; } /** * The sorting order of the resources returned. Value should be a comma-separated list of * fields. The default sorting order is ascending. To specify descending order for a * field, append a `desc` suffix; for example: `name desc, channel_id`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting order is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, channel_id`. */ public java.lang.String getOrderBy() { return orderBy; } /** * The sorting order of the resources returned. Value should be a comma-separated list of * fields. The default sorting order is ascending. To specify descending order for a * field, append a `desc` suffix; for example: `name desc, channel_id`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * The maximum number of channels to return on each page. Note: The service may send * fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The maximum number of channels to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * The maximum number of channels to return on each page. Note: The service may send * fewer. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListChannels` call to retrieve the subsequent page. When paginating, all other * parameters provided to `ListChannels` must match the call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The page token; provide the value from the `next_page_token` field in a previous `ListChannels` call to retrieve the subsequent page. When paginating, all other parameters provided to `ListChannels` must match the call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListChannels` call to retrieve the subsequent page. When paginating, all other * parameters provided to `ListChannels` must match the call that provided the page token. */ 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); } } /** * Update a single channel. * * Create a request for the method "channels.patch". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Required. The resource name of the channel. Must be unique within the location on the project and * must be in `projects/{project}/locations/{location}/channels/{channel_id}` format. * @param content the {@link com.google.api.services.eventarc.v1.model.Channel} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Channel content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); /** * Update a single channel. * * Create a request for the method "channels.patch". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. *

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

* * @param name Required. The resource name of the channel. Must be unique within the location on the project and * must be in `projects/{project}/locations/{location}/channels/{channel_id}` format. * @param content the {@link com.google.api.services.eventarc.v1.model.Channel} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Channel content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/channels/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Required. The resource name of the channel. Must be unique within the location on the * project and must be in `projects/{project}/locations/{location}/channels/{channel_id}` * format. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The resource name of the channel. Must be unique within the location on the project and must be in `projects/{project}/locations/{location}/channels/{channel_id}` format. */ public java.lang.String getName() { return name; } /** * Required. The resource name of the channel. Must be unique within the location on the * project and must be in `projects/{project}/locations/{location}/channels/{channel_id}` * format. */ public Patch 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/[^/]+/channels/[^/]+$"); } this.name = name; return this; } /** * The fields to be updated; only fields explicitly provided are updated. If no field mask * is provided, all provided fields in the request are updated. To update all fields, * provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * The fields to be updated; only fields explicitly provided are updated. If no field mask * is provided, all provided fields in the request are updated. To update all fields, * provide a field mask of "*". */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Patch setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "channels.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "channels.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "channels.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "channels.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/channels/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } /** * An accessor for creating requests from the Enrollments collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.Enrollments.List request = eventarc.enrollments().list(parameters ...)}
       * 
* * @return the resource collection */ public Enrollments enrollments() { return new Enrollments(); } /** * The "enrollments" collection of methods. */ public class Enrollments { /** * Create a new Enrollment in a particular project and location. * * Create a request for the method "enrollments.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this enrollment. * @param content the {@link com.google.api.services.eventarc.v1.model.Enrollment} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Enrollment content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/enrollments"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new Enrollment in a particular project and location. * * Create a request for the method "enrollments.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this enrollment. * @param content the {@link com.google.api.services.eventarc.v1.model.Enrollment} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Enrollment content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this enrollment. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this enrollment. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this enrollment. */ public Create 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; } /** * Required. The user-provided ID to be assigned to the Enrollment. It should match the * format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ @com.google.api.client.util.Key private java.lang.String enrollmentId; /** Required. The user-provided ID to be assigned to the Enrollment. It should match the format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public java.lang.String getEnrollmentId() { return enrollmentId; } /** * Required. The user-provided ID to be assigned to the Enrollment. It should match the * format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public Create setEnrollmentId(java.lang.String enrollmentId) { this.enrollmentId = enrollmentId; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Create setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single Enrollment. * * Create a request for the method "enrollments.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the Enrollment 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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); /** * Delete a single Enrollment. * * Create a request for the method "enrollments.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the Enrollment to be deleted. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/enrollments/[^/]+$"); } } @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); } /** Required. The name of the Enrollment to be deleted. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the Enrollment to be deleted. */ public java.lang.String getName() { return name; } /** Required. The name of the Enrollment 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/[^/]+/enrollments/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the Enrollment is not found, the request will succeed but * no action will be taken on the server. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the Enrollment is not found, the request will succeed but no action will be taken on the server. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the Enrollment is not found, the request will succeed but * no action will be taken on the server. */ public Delete setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. If provided, the Enrollment will only be deleted if the etag matches the * current etag on the resource. */ @com.google.api.client.util.Key private java.lang.String etag; /** Optional. If provided, the Enrollment will only be deleted if the etag matches the current etag on the resource. */ public java.lang.String getEtag() { return etag; } /** * Optional. If provided, the Enrollment will only be deleted if the etag matches the * current etag on the resource. */ public Delete setEtag(java.lang.String etag) { this.etag = etag; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Delete setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single Enrollment. * * Create a request for the method "enrollments.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the Enrollment to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); /** * Get a single Enrollment. * * Create a request for the method "enrollments.get". * * This request holds the parameters needed by the the eventarc 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. The name of the Enrollment to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Enrollment.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/[^/]+/enrollments/[^/]+$"); } } @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. The name of the Enrollment to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the Enrollment to get. */ public java.lang.String getName() { return name; } /** Required. The name of the Enrollment to get. */ 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/[^/]+/enrollments/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "enrollments.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "enrollments.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List Enrollments. * * Create a request for the method "enrollments.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection to list triggers on. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/enrollments"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List Enrollments. * * Create a request for the method "enrollments.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection to list triggers on. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListEnrollmentsResponse.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. The parent collection to list triggers on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection to list triggers on. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection to list triggers on. */ 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. The filter field that the list request will filter on. Possible filtersare * described in https://google.aip.dev/160. */ @com.google.api.client.util.Key private java.lang.String filter; /** Optional. The filter field that the list request will filter on. Possible filtersare described in https://google.aip.dev/160. */ public java.lang.String getFilter() { return filter; } /** * Optional. The filter field that the list request will filter on. Possible filtersare * described in https://google.aip.dev/160. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** Optional. The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting order is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public java.lang.String getOrderBy() { return orderBy; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Optional. The maximum number of results to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** Optional. The page token; provide the value from the `next_page_token` field in a previous call to retrieve the subsequent page. When paginating, all other parameters provided must match the previous call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ 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); } } /** * Update a single Enrollment. * * Create a request for the method "enrollments.patch". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Identifier. Resource name of the form * projects/{project}/locations/{location}/enrollments/{enrollment} * @param content the {@link com.google.api.services.eventarc.v1.model.Enrollment} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Enrollment content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); /** * Update a single Enrollment. * * Create a request for the method "enrollments.patch". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. *

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

* * @param name Identifier. Resource name of the form * projects/{project}/locations/{location}/enrollments/{enrollment} * @param content the {@link com.google.api.services.eventarc.v1.model.Enrollment} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Enrollment content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/enrollments/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Identifier. Resource name of the form * projects/{project}/locations/{location}/enrollments/{enrollment} */ @com.google.api.client.util.Key private java.lang.String name; /** Identifier. Resource name of the form projects/{project}/locations/{location}/enrollments/{enrollment} */ public java.lang.String getName() { return name; } /** * Identifier. Resource name of the form * projects/{project}/locations/{location}/enrollments/{enrollment} */ public Patch 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/[^/]+/enrollments/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the Enrollment is not found, a new Enrollment will be * created. In this situation, `update_mask` is ignored. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the Enrollment is not found, a new Enrollment will be created. In this situation, `update_mask` is ignored. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the Enrollment is not found, a new Enrollment will be * created. In this situation, `update_mask` is ignored. */ public Patch setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** Optional. The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Patch setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "enrollments.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "enrollments.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "enrollments.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "enrollments.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/enrollments/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } /** * An accessor for creating requests from the GoogleApiSources collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.GoogleApiSources.List request = eventarc.googleApiSources().list(parameters ...)}
       * 
* * @return the resource collection */ public GoogleApiSources googleApiSources() { return new GoogleApiSources(); } /** * The "googleApiSources" collection of methods. */ public class GoogleApiSources { /** * Create a new GoogleApiSource in a particular project and location. * * Create a request for the method "googleApiSources.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this google api source. * @param content the {@link com.google.api.services.eventarc.v1.model.GoogleApiSource} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.GoogleApiSource content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/googleApiSources"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new GoogleApiSource in a particular project and location. * * Create a request for the method "googleApiSources.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this google api source. * @param content the {@link com.google.api.services.eventarc.v1.model.GoogleApiSource} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.GoogleApiSource content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this google api source. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this google api source. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this google api source. */ public Create 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; } /** * Required. The user-provided ID to be assigned to the GoogleApiSource. It should match * the format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ @com.google.api.client.util.Key private java.lang.String googleApiSourceId; /** Required. The user-provided ID to be assigned to the GoogleApiSource. It should match the format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public java.lang.String getGoogleApiSourceId() { return googleApiSourceId; } /** * Required. The user-provided ID to be assigned to the GoogleApiSource. It should match * the format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public Create setGoogleApiSourceId(java.lang.String googleApiSourceId) { this.googleApiSourceId = googleApiSourceId; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Create setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single GoogleApiSource. * * Create a request for the method "googleApiSources.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the GoogleApiSource 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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); /** * Delete a single GoogleApiSource. * * Create a request for the method "googleApiSources.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the GoogleApiSource to be deleted. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/googleApiSources/[^/]+$"); } } @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); } /** Required. The name of the GoogleApiSource to be deleted. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the GoogleApiSource to be deleted. */ public java.lang.String getName() { return name; } /** Required. The name of the GoogleApiSource 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/[^/]+/googleApiSources/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the MessageBus is not found, the request will succeed but * no action will be taken on the server. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the MessageBus is not found, the request will succeed but no action will be taken on the server. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the MessageBus is not found, the request will succeed but * no action will be taken on the server. */ public Delete setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. If provided, the MessageBus will only be deleted if the etag matches the * current etag on the resource. */ @com.google.api.client.util.Key private java.lang.String etag; /** Optional. If provided, the MessageBus will only be deleted if the etag matches the current etag on the resource. */ public java.lang.String getEtag() { return etag; } /** * Optional. If provided, the MessageBus will only be deleted if the etag matches the * current etag on the resource. */ public Delete setEtag(java.lang.String etag) { this.etag = etag; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Delete setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single GoogleApiSource. * * Create a request for the method "googleApiSources.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the google api source to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); /** * Get a single GoogleApiSource. * * Create a request for the method "googleApiSources.get". * * This request holds the parameters needed by the the eventarc 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. The name of the google api source to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleApiSource.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/[^/]+/googleApiSources/[^/]+$"); } } @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. The name of the google api source to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the google api source to get. */ public java.lang.String getName() { return name; } /** Required. The name of the google api source to get. */ 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/[^/]+/googleApiSources/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "googleApiSources.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "googleApiSources.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List GoogleApiSources. * * Create a request for the method "googleApiSources.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection to list GoogleApiSources on. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/googleApiSources"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List GoogleApiSources. * * Create a request for the method "googleApiSources.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection to list GoogleApiSources on. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListGoogleApiSourcesResponse.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. The parent collection to list GoogleApiSources on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection to list GoogleApiSources on. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection to list GoogleApiSources on. */ 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. The filter field that the list request will filter on. Possible filtersare * described in https://google.aip.dev/160. */ @com.google.api.client.util.Key private java.lang.String filter; /** Optional. The filter field that the list request will filter on. Possible filtersare described in https://google.aip.dev/160. */ public java.lang.String getFilter() { return filter; } /** * Optional. The filter field that the list request will filter on. Possible filtersare * described in https://google.aip.dev/160. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** Optional. The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting order is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public java.lang.String getOrderBy() { return orderBy; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Optional. The maximum number of results to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** Optional. The page token; provide the value from the `next_page_token` field in a previous call to retrieve the subsequent page. When paginating, all other parameters provided must match the previous call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ 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); } } /** * Update a single GoogleApiSource. * * Create a request for the method "googleApiSources.patch". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Identifier. Resource name of the form * projects/{project}/locations/{location}/googleApiSources/{google_api_source} * @param content the {@link com.google.api.services.eventarc.v1.model.GoogleApiSource} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.eventarc.v1.model.GoogleApiSource content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); /** * Update a single GoogleApiSource. * * Create a request for the method "googleApiSources.patch". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. *

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

* * @param name Identifier. Resource name of the form * projects/{project}/locations/{location}/googleApiSources/{google_api_source} * @param content the {@link com.google.api.services.eventarc.v1.model.GoogleApiSource} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.eventarc.v1.model.GoogleApiSource content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/googleApiSources/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Identifier. Resource name of the form * projects/{project}/locations/{location}/googleApiSources/{google_api_source} */ @com.google.api.client.util.Key private java.lang.String name; /** Identifier. Resource name of the form projects/{project}/locations/{location}/googleApiSources/{google_api_source} */ public java.lang.String getName() { return name; } /** * Identifier. Resource name of the form * projects/{project}/locations/{location}/googleApiSources/{google_api_source} */ public Patch 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/[^/]+/googleApiSources/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the GoogleApiSource is not found, a new GoogleApiSource * will be created. In this situation, `update_mask` is ignored. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the GoogleApiSource is not found, a new GoogleApiSource will be created. In this situation, `update_mask` is ignored. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the GoogleApiSource is not found, a new GoogleApiSource * will be created. In this situation, `update_mask` is ignored. */ public Patch setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** Optional. The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Patch setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "googleApiSources.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "googleApiSources.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "googleApiSources.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "googleApiSources.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/googleApiSources/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } /** * An accessor for creating requests from the MessageBuses collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.MessageBuses.List request = eventarc.messageBuses().list(parameters ...)}
       * 
* * @return the resource collection */ public MessageBuses messageBuses() { return new MessageBuses(); } /** * The "messageBuses" collection of methods. */ public class MessageBuses { /** * Create a new MessageBus in a particular project and location. * * Create a request for the method "messageBuses.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this message bus. * @param content the {@link com.google.api.services.eventarc.v1.model.MessageBus} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.MessageBus content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/messageBuses"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new MessageBus in a particular project and location. * * Create a request for the method "messageBuses.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this message bus. * @param content the {@link com.google.api.services.eventarc.v1.model.MessageBus} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.MessageBus content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this message bus. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this message bus. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this message bus. */ public Create 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; } /** * Required. The user-provided ID to be assigned to the MessageBus. It should match the * format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ @com.google.api.client.util.Key private java.lang.String messageBusId; /** Required. The user-provided ID to be assigned to the MessageBus. It should match the format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public java.lang.String getMessageBusId() { return messageBusId; } /** * Required. The user-provided ID to be assigned to the MessageBus. It should match the * format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public Create setMessageBusId(java.lang.String messageBusId) { this.messageBusId = messageBusId; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Create setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single message bus. * * Create a request for the method "messageBuses.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the MessageBus 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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * Delete a single message bus. * * Create a request for the method "messageBuses.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the MessageBus to be deleted. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/messageBuses/[^/]+$"); } } @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); } /** Required. The name of the MessageBus to be deleted. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the MessageBus to be deleted. */ public java.lang.String getName() { return name; } /** Required. The name of the MessageBus 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/[^/]+/messageBuses/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the MessageBus is not found, the request will succeed but * no action will be taken on the server. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the MessageBus is not found, the request will succeed but no action will be taken on the server. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the MessageBus is not found, the request will succeed but * no action will be taken on the server. */ public Delete setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. If provided, the MessageBus will only be deleted if the etag matches the * current etag on the resource. */ @com.google.api.client.util.Key private java.lang.String etag; /** Optional. If provided, the MessageBus will only be deleted if the etag matches the current etag on the resource. */ public java.lang.String getEtag() { return etag; } /** * Optional. If provided, the MessageBus will only be deleted if the etag matches the * current etag on the resource. */ public Delete setEtag(java.lang.String etag) { this.etag = etag; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Delete setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single MessageBus. * * Create a request for the method "messageBuses.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the message bus to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * Get a single MessageBus. * * Create a request for the method "messageBuses.get". * * This request holds the parameters needed by the the eventarc 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. The name of the message bus to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.MessageBus.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/[^/]+/messageBuses/[^/]+$"); } } @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. The name of the message bus to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the message bus to get. */ public java.lang.String getName() { return name; } /** Required. The name of the message bus to get. */ 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/[^/]+/messageBuses/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "messageBuses.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "messageBuses.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List message buses. * * Create a request for the method "messageBuses.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection to list message buses on. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/messageBuses"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List message buses. * * Create a request for the method "messageBuses.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection to list message buses on. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListMessageBusesResponse.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. The parent collection to list message buses on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection to list message buses on. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection to list message buses on. */ 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. The filter field that the list request will filter on. Possible filtersare * described in https://google.aip.dev/160. */ @com.google.api.client.util.Key private java.lang.String filter; /** Optional. The filter field that the list request will filter on. Possible filtersare described in https://google.aip.dev/160. */ public java.lang.String getFilter() { return filter; } /** * Optional. The filter field that the list request will filter on. Possible filtersare * described in https://google.aip.dev/160. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** Optional. The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting order is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public java.lang.String getOrderBy() { return orderBy; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Optional. The maximum number of results to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** Optional. The page token; provide the value from the `next_page_token` field in a previous call to retrieve the subsequent page. When paginating, all other parameters provided must match the previous call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ 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); } } /** * List message bus enrollments. * * Create a request for the method "messageBuses.listEnrollments". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link ListEnrollments#execute()} method to invoke the remote operation. * * @param parent Required. The parent message bus to list enrollments on. * @return the request */ public ListEnrollments listEnrollments(java.lang.String parent) throws java.io.IOException { ListEnrollments result = new ListEnrollments(parent); initialize(result); return result; } public class ListEnrollments extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}:listEnrollments"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * List message bus enrollments. * * Create a request for the method "messageBuses.listEnrollments". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link ListEnrollments#execute()} method to invoke the remote * operation.

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

* * @param parent Required. The parent message bus to list enrollments on. * @since 1.13 */ protected ListEnrollments(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListMessageBusEnrollmentsResponse.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/[^/]+/messageBuses/[^/]+$"); } } @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 ListEnrollments set$Xgafv(java.lang.String $Xgafv) { return (ListEnrollments) super.set$Xgafv($Xgafv); } @Override public ListEnrollments setAccessToken(java.lang.String accessToken) { return (ListEnrollments) super.setAccessToken(accessToken); } @Override public ListEnrollments setAlt(java.lang.String alt) { return (ListEnrollments) super.setAlt(alt); } @Override public ListEnrollments setCallback(java.lang.String callback) { return (ListEnrollments) super.setCallback(callback); } @Override public ListEnrollments setFields(java.lang.String fields) { return (ListEnrollments) super.setFields(fields); } @Override public ListEnrollments setKey(java.lang.String key) { return (ListEnrollments) super.setKey(key); } @Override public ListEnrollments setOauthToken(java.lang.String oauthToken) { return (ListEnrollments) super.setOauthToken(oauthToken); } @Override public ListEnrollments setPrettyPrint(java.lang.Boolean prettyPrint) { return (ListEnrollments) super.setPrettyPrint(prettyPrint); } @Override public ListEnrollments setQuotaUser(java.lang.String quotaUser) { return (ListEnrollments) super.setQuotaUser(quotaUser); } @Override public ListEnrollments setUploadType(java.lang.String uploadType) { return (ListEnrollments) super.setUploadType(uploadType); } @Override public ListEnrollments setUploadProtocol(java.lang.String uploadProtocol) { return (ListEnrollments) super.setUploadProtocol(uploadProtocol); } /** Required. The parent message bus to list enrollments on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent message bus to list enrollments on. */ public java.lang.String getParent() { return parent; } /** Required. The parent message bus to list enrollments on. */ public ListEnrollments 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/[^/]+/messageBuses/[^/]+$"); } this.parent = parent; return this; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Optional. The maximum number of results to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ public ListEnrollments setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** Optional. The page token; provide the value from the `next_page_token` field in a previous call to retrieve the subsequent page. When paginating, all other parameters provided must match the previous call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ public ListEnrollments setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public ListEnrollments set(String parameterName, Object value) { return (ListEnrollments) super.set(parameterName, value); } } /** * Update a single message bus. * * Create a request for the method "messageBuses.patch". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Identifier. Resource name of the form * projects/{project}/locations/{location}/messageBuses/{message_bus} * @param content the {@link com.google.api.services.eventarc.v1.model.MessageBus} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.eventarc.v1.model.MessageBus content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * Update a single message bus. * * Create a request for the method "messageBuses.patch". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. *

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

* * @param name Identifier. Resource name of the form * projects/{project}/locations/{location}/messageBuses/{message_bus} * @param content the {@link com.google.api.services.eventarc.v1.model.MessageBus} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.eventarc.v1.model.MessageBus content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/messageBuses/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Identifier. Resource name of the form * projects/{project}/locations/{location}/messageBuses/{message_bus} */ @com.google.api.client.util.Key private java.lang.String name; /** Identifier. Resource name of the form projects/{project}/locations/{location}/messageBuses/{message_bus} */ public java.lang.String getName() { return name; } /** * Identifier. Resource name of the form * projects/{project}/locations/{location}/messageBuses/{message_bus} */ public Patch 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/[^/]+/messageBuses/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the MessageBus is not found, a new MessageBus will be * created. In this situation, `update_mask` is ignored. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the MessageBus is not found, a new MessageBus will be created. In this situation, `update_mask` is ignored. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the MessageBus is not found, a new MessageBus will be * created. In this situation, `update_mask` is ignored. */ public Patch setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** Optional. The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Patch setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "messageBuses.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "messageBuses.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "messageBuses.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "messageBuses.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/messageBuses/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } /** * An accessor for creating requests from the Operations collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.Operations.List request = eventarc.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 eventarc 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.eventarc.v1.model.GoogleLongrunningCancelOperationRequest} * @return the request */ public Cancel cancel(java.lang.String name, com.google.api.services.eventarc.v1.model.GoogleLongrunningCancelOperationRequest content) throws java.io.IOException { Cancel result = new Cancel(name, content); initialize(result); return result; } public class Cancel extends EventarcRequest { 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 eventarc 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.eventarc.v1.model.GoogleLongrunningCancelOperationRequest} * @since 1.13 */ protected Cancel(java.lang.String name, com.google.api.services.eventarc.v1.model.GoogleLongrunningCancelOperationRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.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 eventarc 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 EventarcRequest { 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 eventarc 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(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.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 eventarc 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 EventarcRequest { 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 eventarc 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(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 eventarc 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 EventarcRequest { 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 eventarc 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(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningListOperationsResponse.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; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } } /** * An accessor for creating requests from the Pipelines collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.Pipelines.List request = eventarc.pipelines().list(parameters ...)}
       * 
* * @return the resource collection */ public Pipelines pipelines() { return new Pipelines(); } /** * The "pipelines" collection of methods. */ public class Pipelines { /** * Create a new Pipeline in a particular project and location. * * Create a request for the method "pipelines.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this pipeline. * @param content the {@link com.google.api.services.eventarc.v1.model.Pipeline} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Pipeline content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/pipelines"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new Pipeline in a particular project and location. * * Create a request for the method "pipelines.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this pipeline. * @param content the {@link com.google.api.services.eventarc.v1.model.Pipeline} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Pipeline content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this pipeline. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this pipeline. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this pipeline. */ public Create 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; } /** * Required. The user-provided ID to be assigned to the Pipeline. It should match the * format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ @com.google.api.client.util.Key private java.lang.String pipelineId; /** Required. The user-provided ID to be assigned to the Pipeline. It should match the format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public java.lang.String getPipelineId() { return pipelineId; } /** * Required. The user-provided ID to be assigned to the Pipeline. It should match the * format `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ public Create setPipelineId(java.lang.String pipelineId) { this.pipelineId = pipelineId; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Create setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single pipeline. * * Create a request for the method "pipelines.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the Pipeline 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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); /** * Delete a single pipeline. * * Create a request for the method "pipelines.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the Pipeline to be deleted. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/pipelines/[^/]+$"); } } @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); } /** Required. The name of the Pipeline to be deleted. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the Pipeline to be deleted. */ public java.lang.String getName() { return name; } /** Required. The name of the Pipeline 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/[^/]+/pipelines/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the Pipeline is not found, the request will succeed but * no action will be taken on the server. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the Pipeline is not found, the request will succeed but no action will be taken on the server. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the Pipeline is not found, the request will succeed but * no action will be taken on the server. */ public Delete setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. If provided, the Pipeline will only be deleted if the etag matches the * current etag on the resource. */ @com.google.api.client.util.Key private java.lang.String etag; /** Optional. If provided, the Pipeline will only be deleted if the etag matches the current etag on the resource. */ public java.lang.String getEtag() { return etag; } /** * Optional. If provided, the Pipeline will only be deleted if the etag matches the * current etag on the resource. */ public Delete setEtag(java.lang.String etag) { this.etag = etag; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Delete setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single Pipeline. * * Create a request for the method "pipelines.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the pipeline to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); /** * Get a single Pipeline. * * Create a request for the method "pipelines.get". * * This request holds the parameters needed by the the eventarc 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. The name of the pipeline to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Pipeline.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/[^/]+/pipelines/[^/]+$"); } } @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. The name of the pipeline to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the pipeline to get. */ public java.lang.String getName() { return name; } /** Required. The name of the pipeline to get. */ 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/[^/]+/pipelines/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "pipelines.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "pipelines.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List pipelines. * * Create a request for the method "pipelines.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection to list pipelines on. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/pipelines"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List pipelines. * * Create a request for the method "pipelines.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection to list pipelines on. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListPipelinesResponse.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. The parent collection to list pipelines on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection to list pipelines on. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection to list pipelines on. */ 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. The filter field that the list request will filter on. Possible filters are * described in https://google.aip.dev/160. */ @com.google.api.client.util.Key private java.lang.String filter; /** Optional. The filter field that the list request will filter on. Possible filters are described in https://google.aip.dev/160. */ public java.lang.String getFilter() { return filter; } /** * Optional. The filter field that the list request will filter on. Possible filters are * described in https://google.aip.dev/160. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** Optional. The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting order is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public java.lang.String getOrderBy() { return orderBy; } /** * Optional. The sorting order of the resources returned. Value should be a comma- * separated list of fields. The default sorting order is ascending. To specify descending * order for a field, append a `desc` suffix; for example: `name desc, update_time`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Optional. The maximum number of results to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Optional. The maximum number of results to return on each page. Note: The service may * send fewer. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** Optional. The page token; provide the value from the `next_page_token` field in a previous call to retrieve the subsequent page. When paginating, all other parameters provided must match the previous call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * Optional. The page token; provide the value from the `next_page_token` field in a * previous call to retrieve the subsequent page. When paginating, all other parameters * provided must match the previous call that provided the page token. */ 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); } } /** * Update a single pipeline. * * Create a request for the method "pipelines.patch". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Identifier. The resource name of the Pipeline. Must be unique within the location of the project and * must be in `projects/{project}/locations/{location}/pipelines/{pipeline}` format. * @param content the {@link com.google.api.services.eventarc.v1.model.Pipeline} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Pipeline content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); /** * Update a single pipeline. * * Create a request for the method "pipelines.patch". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. *

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

* * @param name Identifier. The resource name of the Pipeline. Must be unique within the location of the project and * must be in `projects/{project}/locations/{location}/pipelines/{pipeline}` format. * @param content the {@link com.google.api.services.eventarc.v1.model.Pipeline} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Pipeline content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/pipelines/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Identifier. The resource name of the Pipeline. Must be unique within the location of * the project and must be in * `projects/{project}/locations/{location}/pipelines/{pipeline}` format. */ @com.google.api.client.util.Key private java.lang.String name; /** Identifier. The resource name of the Pipeline. Must be unique within the location of the project and must be in `projects/{project}/locations/{location}/pipelines/{pipeline}` format. */ public java.lang.String getName() { return name; } /** * Identifier. The resource name of the Pipeline. Must be unique within the location of * the project and must be in * `projects/{project}/locations/{location}/pipelines/{pipeline}` format. */ public Patch 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/[^/]+/pipelines/[^/]+$"); } this.name = name; return this; } /** * Optional. If set to true, and the Pipeline is not found, a new Pipeline will be * created. In this situation, `update_mask` is ignored. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** Optional. If set to true, and the Pipeline is not found, a new Pipeline will be created. In this situation, `update_mask` is ignored. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * Optional. If set to true, and the Pipeline is not found, a new Pipeline will be * created. In this situation, `update_mask` is ignored. */ public Patch setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** Optional. The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * Optional. The fields to be updated; only fields explicitly provided are updated. If no * field mask is provided, all provided fields in the request are updated. To update all * fields, provide a field mask of "*". */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Patch setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "pipelines.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "pipelines.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "pipelines.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "pipelines.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/pipelines/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } /** * An accessor for creating requests from the Providers collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.Providers.List request = eventarc.providers().list(parameters ...)}
       * 
* * @return the resource collection */ public Providers providers() { return new Providers(); } /** * The "providers" collection of methods. */ public class Providers { /** * Get a single Provider. * * Create a request for the method "providers.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the provider to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/providers/[^/]+$"); /** * Get a single Provider. * * Create a request for the method "providers.get". * * This request holds the parameters needed by the the eventarc 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. The name of the provider to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Provider.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/[^/]+/providers/[^/]+$"); } } @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. The name of the provider to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the provider to get. */ public java.lang.String getName() { return name; } /** Required. The name of the provider to get. */ 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/[^/]+/providers/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * List providers. * * Create a request for the method "providers.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent of the provider to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/providers"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List providers. * * Create a request for the method "providers.list". * * This request holds the parameters needed by the the eventarc 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. The parent of the provider to get. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListProvidersResponse.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. The parent of the provider to get. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent of the provider to get. */ public java.lang.String getParent() { return parent; } /** Required. The parent of the provider to get. */ 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; } /** The filter field that the list request will filter on. */ @com.google.api.client.util.Key private java.lang.String filter; /** The filter field that the list request will filter on. */ public java.lang.String getFilter() { return filter; } /** The filter field that the list request will filter on. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * The sorting order of the resources returned. Value should be a comma-separated list of * fields. The default sorting oder is ascending. To specify descending order for a field, * append a `desc` suffix; for example: `name desc, _id`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting oder is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, _id`. */ public java.lang.String getOrderBy() { return orderBy; } /** * The sorting order of the resources returned. Value should be a comma-separated list of * fields. The default sorting oder is ascending. To specify descending order for a field, * append a `desc` suffix; for example: `name desc, _id`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** The maximum number of providers to return on each page. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The maximum number of providers to return on each page. */ public java.lang.Integer getPageSize() { return pageSize; } /** The maximum number of providers to return on each page. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListProviders` call to retrieve the subsequent page. When paginating, all other * parameters provided to `ListProviders` must match the call that provided the page * token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The page token; provide the value from the `next_page_token` field in a previous `ListProviders` call to retrieve the subsequent page. When paginating, all other parameters provided to `ListProviders` must match the call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListProviders` call to retrieve the subsequent page. When paginating, all other * parameters provided to `ListProviders` must match the call that provided the page * token. */ 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 Triggers collection. * *

The typical use is:

*
       *   {@code Eventarc eventarc = new Eventarc(...);}
       *   {@code Eventarc.Triggers.List request = eventarc.triggers().list(parameters ...)}
       * 
* * @return the resource collection */ public Triggers triggers() { return new Triggers(); } /** * The "triggers" collection of methods. */ public class Triggers { /** * Create a new trigger in a particular project and location. * * Create a request for the method "triggers.create". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection in which to add this trigger. * @param content the {@link com.google.api.services.eventarc.v1.model.Trigger} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Trigger content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends EventarcRequest { private static final String REST_PATH = "v1/{+parent}/triggers"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Create a new trigger in a particular project and location. * * Create a request for the method "triggers.create". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. *

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

* * @param parent Required. The parent collection in which to add this trigger. * @param content the {@link com.google.api.services.eventarc.v1.model.Trigger} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.eventarc.v1.model.Trigger content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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 Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** Required. The parent collection in which to add this trigger. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection in which to add this trigger. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection in which to add this trigger. */ public Create 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; } /** Required. The user-provided ID to be assigned to the trigger. */ @com.google.api.client.util.Key private java.lang.String triggerId; /** Required. The user-provided ID to be assigned to the trigger. */ public java.lang.String getTriggerId() { return triggerId; } /** Required. The user-provided ID to be assigned to the trigger. */ public Create setTriggerId(java.lang.String triggerId) { this.triggerId = triggerId; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Create setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Delete a single trigger. * * Create a request for the method "triggers.delete". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name Required. The name of the trigger 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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); /** * Delete a single trigger. * * Create a request for the method "triggers.delete". * * This request holds the parameters needed by the the eventarc 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 Required. The name of the trigger to be deleted. * @since 1.13 */ protected Delete(java.lang.String name) { super(Eventarc.this, "DELETE", REST_PATH, null, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/triggers/[^/]+$"); } } @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); } /** Required. The name of the trigger to be deleted. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the trigger to be deleted. */ public java.lang.String getName() { return name; } /** Required. The name of the trigger 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/[^/]+/triggers/[^/]+$"); } this.name = name; return this; } /** * If set to true, and the trigger is not found, the request will succeed but no action * will be taken on the server. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** If set to true, and the trigger is not found, the request will succeed but no action will be taken on the server. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * If set to true, and the trigger is not found, the request will succeed but no action * will be taken on the server. */ public Delete setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * If provided, the trigger will only be deleted if the etag matches the current etag on * the resource. */ @com.google.api.client.util.Key private java.lang.String etag; /** If provided, the trigger will only be deleted if the etag matches the current etag on the resource. */ public java.lang.String getEtag() { return etag; } /** * If provided, the trigger will only be deleted if the etag matches the current etag on * the resource. */ public Delete setEtag(java.lang.String etag) { this.etag = etag; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Delete setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Get a single trigger. * * Create a request for the method "triggers.get". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Required. The name of the trigger to get. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); /** * Get a single trigger. * * Create a request for the method "triggers.get". * * This request holds the parameters needed by the the eventarc 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. The name of the trigger to get. * @since 1.13 */ protected Get(java.lang.String name) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Trigger.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/[^/]+/triggers/[^/]+$"); } } @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. The name of the trigger to get. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The name of the trigger to get. */ public java.lang.String getName() { return name; } /** Required. The name of the trigger to get. */ 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/[^/]+/triggers/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "triggers.getIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "triggers.getIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); } } @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 GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The maximum policy version that will be used to format the policy. Valid * values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests * for policies with any conditional role bindings must specify version 3. Policies with * no conditional role bindings may specify any valid value or leave the field unset. The * policy in the response might use the policy version that you specified, or it might use * a lower policy version. For example, if you specify version 3, but the policy has no * conditional role bindings, the response uses version 1. To learn which resources * support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * List triggers. * * Create a request for the method "triggers.list". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Required. The parent collection to list triggers on. * @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 EventarcRequest { private static final String REST_PATH = "v1/{+parent}/triggers"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * List triggers. * * Create a request for the method "triggers.list". * * This request holds the parameters needed by the the eventarc 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. The parent collection to list triggers on. * @since 1.13 */ protected List(java.lang.String parent) { super(Eventarc.this, "GET", REST_PATH, null, com.google.api.services.eventarc.v1.model.ListTriggersResponse.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. The parent collection to list triggers on. */ @com.google.api.client.util.Key private java.lang.String parent; /** Required. The parent collection to list triggers on. */ public java.lang.String getParent() { return parent; } /** Required. The parent collection to list triggers on. */ 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; } /** * Filter field. Used to filter the Triggers to be listed. Possible filters are described * in https://google.aip.dev/160. For example, using "?filter=destination:gke" would list * only Triggers with a gke destination. */ @com.google.api.client.util.Key private java.lang.String filter; /** Filter field. Used to filter the Triggers to be listed. Possible filters are described in https://google.aip.dev/160. For example, using "?filter=destination:gke" would list only Triggers with a gke destination. */ public java.lang.String getFilter() { return filter; } /** * Filter field. Used to filter the Triggers to be listed. Possible filters are described * in https://google.aip.dev/160. For example, using "?filter=destination:gke" would list * only Triggers with a gke destination. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * The sorting order of the resources returned. Value should be a comma-separated list of * fields. The default sorting order is ascending. To specify descending order for a * field, append a `desc` suffix; for example: `name desc, trigger_id`. */ @com.google.api.client.util.Key private java.lang.String orderBy; /** The sorting order of the resources returned. Value should be a comma-separated list of fields. The default sorting order is ascending. To specify descending order for a field, append a `desc` suffix; for example: `name desc, trigger_id`. */ public java.lang.String getOrderBy() { return orderBy; } /** * The sorting order of the resources returned. Value should be a comma-separated list of * fields. The default sorting order is ascending. To specify descending order for a * field, append a `desc` suffix; for example: `name desc, trigger_id`. */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * The maximum number of triggers to return on each page. Note: The service may send * fewer. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The maximum number of triggers to return on each page. Note: The service may send fewer. */ public java.lang.Integer getPageSize() { return pageSize; } /** * The maximum number of triggers to return on each page. Note: The service may send * fewer. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListTriggers` call to retrieve the subsequent page. When paginating, all other * parameters provided to `ListTriggers` must match the call that provided the page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The page token; provide the value from the `next_page_token` field in a previous `ListTriggers` call to retrieve the subsequent page. When paginating, all other parameters provided to `ListTriggers` must match the call that provided the page token. */ public java.lang.String getPageToken() { return pageToken; } /** * The page token; provide the value from the `next_page_token` field in a previous * `ListTriggers` call to retrieve the subsequent page. When paginating, all other * parameters provided to `ListTriggers` must match the call that provided the page token. */ 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); } } /** * Update a single trigger. * * Create a request for the method "triggers.patch". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Required. The resource name of the trigger. Must be unique within the location of the project and * must be in `projects/{project}/locations/{location}/triggers/{trigger}` format. * @param content the {@link com.google.api.services.eventarc.v1.model.Trigger} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Trigger content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends EventarcRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); /** * Update a single trigger. * * Create a request for the method "triggers.patch". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. *

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

* * @param name Required. The resource name of the trigger. Must be unique within the location of the project and * must be in `projects/{project}/locations/{location}/triggers/{trigger}` format. * @param content the {@link com.google.api.services.eventarc.v1.model.Trigger} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.eventarc.v1.model.Trigger content) { super(Eventarc.this, "PATCH", REST_PATH, content, com.google.api.services.eventarc.v1.model.GoogleLongrunningOperation.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/[^/]+/triggers/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Required. The resource name of the trigger. Must be unique within the location of the * project and must be in `projects/{project}/locations/{location}/triggers/{trigger}` * format. */ @com.google.api.client.util.Key private java.lang.String name; /** Required. The resource name of the trigger. Must be unique within the location of the project and must be in `projects/{project}/locations/{location}/triggers/{trigger}` format. */ public java.lang.String getName() { return name; } /** * Required. The resource name of the trigger. Must be unique within the location of the * project and must be in `projects/{project}/locations/{location}/triggers/{trigger}` * format. */ public Patch 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/[^/]+/triggers/[^/]+$"); } this.name = name; return this; } /** * If set to true, and the trigger is not found, a new trigger will be created. In this * situation, `update_mask` is ignored. */ @com.google.api.client.util.Key private java.lang.Boolean allowMissing; /** If set to true, and the trigger is not found, a new trigger will be created. In this situation, `update_mask` is ignored. */ public java.lang.Boolean getAllowMissing() { return allowMissing; } /** * If set to true, and the trigger is not found, a new trigger will be created. In this * situation, `update_mask` is ignored. */ public Patch setAllowMissing(java.lang.Boolean allowMissing) { this.allowMissing = allowMissing; return this; } /** * The fields to be updated; only fields explicitly provided are updated. If no field mask * is provided, all provided fields in the request are updated. To update all fields, * provide a field mask of "*". */ @com.google.api.client.util.Key private String updateMask; /** The fields to be updated; only fields explicitly provided are updated. If no field mask is provided, all provided fields in the request are updated. To update all fields, provide a field mask of "*". */ public String getUpdateMask() { return updateMask; } /** * The fields to be updated; only fields explicitly provided are updated. If no field mask * is provided, all provided fields in the request are updated. To update all fields, * provide a field mask of "*". */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } /** Optional. If set, validate the request and preview the review, but do not post it. */ @com.google.api.client.util.Key private java.lang.Boolean validateOnly; /** Optional. If set, validate the request and preview the review, but do not post it. */ public java.lang.Boolean getValidateOnly() { return validateOnly; } /** Optional. If set, validate the request and preview the review, but do not post it. */ public Patch setValidateOnly(java.lang.Boolean validateOnly) { this.validateOnly = validateOnly; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "triggers.setIamPolicy". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. Can * return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. * * Create a request for the method "triggers.setIamPolicy". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.eventarc.v1.model.SetIamPolicyRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is * designed to be used for building permission-aware UIs and command-line tools, not for * authorization checking. This operation may "fail open" without warning. * * Create a request for the method "triggers.testIamPermissions". * * This request holds the parameters needed by the eventarc server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends EventarcRequest { private static final String REST_PATH = "v1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This * operation is designed to be used for building permission-aware UIs and command-line tools, not * for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "triggers.testIamPermissions". * * This request holds the parameters needed by the the eventarc server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation.

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

* * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for * this field. * @param content the {@link com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.eventarc.v1.model.TestIamPermissionsRequest content) { super(Eventarc.this, "POST", REST_PATH, content, com.google.api.services.eventarc.v1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See [Resource * names](https://cloud.google.com/apis/design/resource_names) for the appropriate value * for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/triggers/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } } } } /** * Builder for {@link Eventarc}. * *

* 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: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()} *
  • *
* @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 Eventarc}. */ @Override public Eventarc build() { return new Eventarc(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 EventarcRequestInitializer}. * * @since 1.12 */ public Builder setEventarcRequestInitializer( EventarcRequestInitializer eventarcRequestInitializer) { return (Builder) super.setGoogleClientRequestInitializer(eventarcRequestInitializer); } @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); } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy